Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / First Aid / August 2006

Tip: Looking for answers? Try searching our database.

references

Thread view: 
aotemp@hotmail.com - 30 Aug 2006 05:35 GMT
Hi!

I am working with a JSP page that resides in folder "X" in the root,
and includes a .HTML page from the root folder itself.

The my problem is that when it references the HTML file from the root
folder, all of the image links are broken.

Is there any way to correct this problem, that doesn't require a
rewrite of the HTML file from the root folder?

The HTML file is the menu system for the entire website, the JSP page
in the "X" directory is of course just one of many pages that reference
the HTML file....

Thanks for the help!
Andrew Thompson - 30 Aug 2006 06:17 GMT
> Hi!
>
[quoted text clipped - 6 lines]
> Is there any way to correct this problem, that doesn't require a
> rewrite of the HTML file from the root folder?

What have you got against editing that one file?

In any case, if you should change your mind, the images
can be referenced form the single HTML by giving either
an absolute image path (full URL), which would break if the
domain is moved, or alternately a 'path from the root'.

E.G. for loading http://www.yourdomain.com/images/logo.png
you can reference it as..
   <img  src='/images/logo.png'>
..and no matter what HTML/JSP loads that HTML, the images
will be found.  Note the first '/', which indicates the root of the
domain.

HTH

Andrew T.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.