Jump to content

Seeing links in site while site is not online


Samurai Fox
 Share

Recommended Posts

Than what's wrong here?

 

<ul>
<li class="page_item page-item-1">
<a href="http://scrapelight.com/">Home</a></li>
<li class="page_item page-item-2 page_item_has_children current_page_ancestor current_page_parent">
<a href="http://scrapelight.com/game/">Game</a></li>
<li class="page_item page-item-3">
<a href="http://scrapelight.com/shape/">Shape</a></li>
<li class="page_item page-item-4">
<a href="http://scrapelight.com/journey/">Journey</a></li>
</ul>
Edited by Samurai Fox
Link to comment
Share on other sites

Those are absolute links. You need to use relative links.

<a href="./">Home</a><a href="game/">Game</a><a href="shape/">Shape</a><a href="journey/">Journey</a>

The second problem that will occur after this change is that you're linking to folders rather than files. Normally, a web server will be configured to select a file but if you're running this in your local filesystem that won't happen. You can download server software to test your pages on your home computer. I recommend looking up WAMP Server and installing it.

Link to comment
Share on other sites

So this:
<ul><li class="page_item page-item-1"> <a href="./">Home</a>
<li class="page_item page-item-2 page_item_has_children current_page_ancestor current_page_parent"> <a href="game/">Game</a>
<li class="page_item page-item-3"> <a href="shape/">Shape</a>
<li class="page_item page-item-4"> <a href="journey/">Journey</a>

</ul>

 

or this only:

<a href="./">Home</a><a href="game/">Game</a><a href="shape/">Shape</a><a href="journey/">Journey</a>
Edited by Samurai Fox
Link to comment
Share on other sites

It doesn't matter. I only showed the links because they're the relevant part. Here's an explanation about absolute and relative links: http://kb.iu.edu/data/abwp.html

 

When you want to link to your website files regardless of where on the internet your website is you need to use relative links.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...