• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hi, question on c:import...

 
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I was wondering why the .gifs aren't displaying correctly on this site when I do:
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<HTML>
<HEAD><TITLE> JSTL Practice </TITLE></HEAD>
<BODY>
Is this a site?
<c:import url="www.1010wins.com"/>
</BODY></HTML>

Thanks so much,
Carmen
 
Ranch Hand
Posts: 951
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

<c:import url="www.1010wins.com"/>



It will not redirect the URL to web site www.1010wins.com. The <c:import> action treate it as reletive URL and not absolute URL. so it search /approot/www.1010wins.com in your servlet Context assumming that Your JSP file is placed at approot.

try using absolute URL as http://www.1010wins.com.

I think the <c:import> is not good for these tasks, as it try to import the full default page of the site. Instead it better to use <c:redirect> to display the full site.


Thanks
[ March 07, 2006: Message edited by: Narendra Dhande ]
 
Carmen Brianick
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Narendra, thanks for your response, I will try the absolute path to see what happens.

Thanks again,
Carmen
 
reply
    Bookmark Topic Watch Topic
  • New Topic