DEV Community

Discussion on: Help.

Collapse
 
deciduously profile image
Ben Lovy

There's two strategies. You can either use a backend server to create the other pages, and then put links in your webpage to request them directly. Alternatively, you can use JavaScript to dynamically update the page that's already loaded. This is usually easier with a framework, the larger frameworks tend to have a solution for this built-in. The specifics will depend on the tool you use, and I think the simpler solution is to build a backend that can build each page you need.

Collapse
 
ireti03 profile image
Iretii

Thank you. It's an assignment to test my css skills so I'm going to push it to github. Also, I don't know javascript

Collapse
 
deciduously profile image
Ben Lovy • Edited

If the purpose is to exercise your CSS, and you dont want to branch out into a whole other tool, unfortunately I think you'd have an easier time if you can restrict your design to one page. While there are some relatively smooth ways to get started writing a backend, it is still going to involve learning some very non-CSS-related topics.

Thread Thread
 
ireti03 profile image
Iretii

Oh my teacher said it had to be more than one page while using just html and CSS

Thread Thread
 
deciduously profile image
Ben Lovy • Edited

Well, you can create multiple web pages each in isolation. Then, you can use the <a> tag to create links. Without a server, I think what your teacher wants is to use relative paths. So, if you have an index.html and a history.html, or whatever your other page will be, you can create an HTML element Like <a href="history.html">History Page</a> on your main page. When you open it locally in your browser, that link should work as long as your HTML files are stored in the same folder.

EDIT: looks like you got this answer several times!

Thread Thread
 
ireti03 profile image
Iretii

Alright this looks simple enough. I'll get to work on it. Thanks a lot!