aspose file tools*
The moose likes Servlets and the fly likes Hosting Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Hosting" Watch "Hosting" New topic
Author

Hosting

colin shuker
Ranch Hand

Joined: Apr 11, 2005
Posts: 744
I'm using netbeans 3.5 which has the Tomcat server included.
Apparently it's possible to connect to this server from another pc,
using my pc's IP address, but I don't have a clue how to do this.
Does anyone know how to do this, so that my servlets can be loaded
from different PCs???

Thanks
Annie Smith
Ranch Hand

Joined: Mar 05, 2005
Posts: 172
Your problem statement doesn't seem very clear to me. Would you care to explain a bit more?


Cheers!<br /><b>Annie</b>
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
Just type-in your ip instead of localhost/127.0.0.1
Where is the problem?
colin shuker
Ranch Hand

Joined: Apr 11, 2005
Posts: 744
Thanks, I knew I had to do something like that. Basically I'm using Netbeans 3.5 which has its own tomcat server. So can I still just type in my IP address?
Usually to invoke a servlet or jsp for example, I would write in the browser:
http://localhost:8081/SomeJspFile.jsp
I forgot how to find my PC's IP address, do you know how to find it?
And if so, what exactly would I type in browser to replace the address above, if I wanted to invoke the SomeJspFile from some other PC?

OK, I've just found my IP address... it's 86.128.199.162
Does anyone know what address I need to write.
I've tried http://86.128.199.162/SomeJspFile.jsp
But that doesn't work.
Any ideas.

Thanks.
[ September 26, 2005: Message edited by: colin shuker ]
Dave Salter
Ranch Hand

Joined: Jul 20, 2005
Posts: 293

If you acess it locally as http://localhost:8081/SomeJsp.jsp and you ip address is 86.128.199.162, you should be able to access it remotely at

http://86.128.199.162:8081/SomeJsp.jsp

You need to specify the port number (8081) when you are running locally or remotely.
Vladas Razas
Ranch Hand

Joined: Dec 02, 2003
Posts: 385
Add port

http://86.128.199.162:8081/SomeJspFile.jsp
colin shuker
Ranch Hand

Joined: Apr 11, 2005
Posts: 744
Thanks, but I tried that and I just get that annoying
page that comes up "The Page Cannot Be Displayed--blah,blah,blah"

So I dont know what to do.
Shall I give up?
Could it be anything to do with the router that I'm using.
This connects 3 pcs together to the modem, but not in a network.

Any ideas???
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
Originally posted by colin shuker:
Thanks, but I tried that and I just get that annoying
page that comes up "The Page Cannot Be Displayed--blah,blah,blah"

So I dont know what to do.
Shall I give up?
Could it be anything to do with the router that I'm using.
This connects 3 pcs together to the modem, but not in a network.


Excuse me! Are all the PCs inter-connected via LAN or something?
colin shuker
Ranch Hand

Joined: Apr 11, 2005
Posts: 744
Nope, theres no connection between them, they just share the same router.
So I donno, just one of those annoying things about computers I suppose. If they dont wanna work, they don't work.
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
Originally posted by colin shuker:
Nope, theres no connection between them, they just share the same router.
So I donno, just one of those annoying things about computers I suppose. If they dont wanna work, they don't work.


I think you need a live IP for the server. Just a thought.
Bosun Bello
Ranch Hand

Joined: Nov 06, 2000
Posts: 1510
The PCs will need to be interconnected. Since you have a router, you already have what it takes to do it.


Bosun (SCJP, SCWCD)
So much trouble in the world -- Bob Marley
 
Don't get me started about those stupid light bulbs.
 
subject: Hosting