PDA

View Full Version : Internet/Intranet


TigaSefi
30-07-2003, 16:06
Right I got a mind bender here. Most ppl outside the router of my linux box would access my website using my domain name which is www.notreal.co.uk (NOT REAL ADDRESS) however my and my gf use loopback on my linux box and my LAN IP on her windows box. Now I am creating a website that gonna cause problem with the links. If i do a link to www.notreal.co.uk/forums and gf clicks it, it ain't gonna go there for her so how do I fix it so it goes there for everyone outside and inside ? Would an Intranet solve it ?

Mr_love_monkey
30-07-2003, 16:30
Originally posted by TigaSefi
If i do a link to www.notreal.co.uk/forums and gf clicks it, it ain't gonna go there for her so how do I fix it so it goes there for everyone outside and inside ? Would an Intranet solve it ?

Surely if you set your links to be relative it won't matter - i.e. your link should be /forums not www..../forums - so it should resolve

TigaSefi
30-07-2003, 16:54
yeah I hadn't thought of that.... so what would be the proper formatting ?

Mr_love_monkey
30-07-2003, 16:57
Originally posted by TigaSefi
yeah I hadn't thought of that.... so what would be the proper formatting ?

well, if I understand your question correctly all you'd need to do is something like :

<a href="forums.htm">forums<a> (or whatever your address is for your page)

you'd also want to include the directory structure as well, if you had one i.e. :

<a href="/forums/forums.html">forums</a> with all of your links being relative from your starting point/index page

if that makes sense?

TigaSefi
30-07-2003, 16:58
hmmm I'll try that when I get home, thanks. Now I need a pro web designer that'll do it for nowt lol.....

Stuart W
30-07-2003, 17:00
You may run into problems like this....

The forum need to know its complete URL, so when people click on things like "New Post" it will be "http://www.notreal.com/forum/index.php?somecodefornewpost"

I'd sugest editing the HOST file in your windows folder ;)

something like 192.168.1.1 www.notreal.com

Mr_love_monkey
30-07-2003, 17:00
Originally posted by TigaSefi
hmmm I'll try that when I get home, thanks. Now I need a pro web designer that'll do it for nowt lol.....

feel free to give me a shout/PM if you have any more questions, hopefully I should be able to answer them.

TigaSefi
30-07-2003, 17:02
Yeah the forums works brillantly as it is now as u can see at www.nonbeanbaggers.co.uk/forums and it does work internally too. I ain't too sure how I did it though but surely just for the index.html the "formatting" as suggested will be fine ?

Stuart W
30-07-2003, 17:08
When at your forum, hover over any link (topic new post etc.) and look at the botom of your browser.... you will see the complete url all the way back to http://

If you edit the HOST file in the Windows folder (Windows\System32 in XP) you can tell your PC to use the local IP address. Your HOST file should already have one entry like:

127.0.0.1 Localhost

Just add yours underneath. Asuming your local IP is 192.168.0.1 you would have:

127.0.0.1 Localhost
192.168.0.1 www.nonbeanbaggers.co.uk

birchyboy
30-07-2003, 20:14
If you don't know much about the HOSTS file, you can find out how to make or edit one in Win 98 here (a link to the Other Place)

http://www.nthellworld.com/forum/showthread.php?s=&threadid=37741

TigaSefi
30-07-2003, 20:15
I fixed the hosts file thanks. It works perfectly. I was just thinking how to do it on linux so i can use the domain address rather than the 127 loopback address ?

wunderlust
30-07-2003, 22:21
Not sure if you've already done it but exact same for linux machine only difference of course is the file, which is

/etc/hosts

if it's the actual machine that's hosting the website just add www.mysite.com to what's already there, ending up something like that

127.0.0.1 www.mywebsite.com localhost.localdomain localhost