Re: T5: How to create an external URL to a Tapestry page?

2008-02-12 Thread SergeEby

Hey,

Just return a URL object

http://tapestry.apache.org/tapestry5/tapestry-core/guide/pagenav.html

/Serge


Travis McLeskey wrote:
 
 For example, if one wanted to generate a complete URL (including  
 protocol, server name, and port) and send it in an email.
 
 I tried ComponentResources.createActionLink() and  
 Component.createPageLink(), but the Link objects returned by those  
 methods do not include the server name, etc.
 
 In Tap4 there was the ExternalService. I'm sure there is a Tap5  
 equivalent...I just can't find it.
 
 Thanks,
 Travis
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/T5%3A-How-to-create-an-external-URL-to-a-Tapestry-page--tp15436877p15446980.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: How to create an external URL to a Tapestry page?

2008-02-12 Thread Howard Lewis Ship
The URLs are very predictable.  The biggest issue is with the
hostname, it is often easier for your application to provide the
correct URL than Tapestry, as the information about server name that
it gets from the Servlet API is often wrong, referring instead to the
internal server forwarded to by the firewall (aka the reverse proxy)
which may not be a server visible to the end user.

If you have a Link instance, you can invoke toAbsoluteURI() to get the
full URI path (that is, everything after the host name portion of the
URL).

As pointed out, there are methods on ComponentResources for obtaining
such Link objects.


On Feb 12, 2008 4:54 PM, SergeEby [EMAIL PROTECTED] wrote:

 Hey,

 Just return a URL object

 http://tapestry.apache.org/tapestry5/tapestry-core/guide/pagenav.html

 /Serge



 Travis McLeskey wrote:
 
  For example, if one wanted to generate a complete URL (including
  protocol, server name, and port) and send it in an email.
 
  I tried ComponentResources.createActionLink() and
  Component.createPageLink(), but the Link objects returned by those
  methods do not include the server name, etc.
 
  In Tap4 there was the ExternalService. I'm sure there is a Tap5
  equivalent...I just can't find it.
 
  Thanks,
  Travis
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

 --
 View this message in context: 
 http://www.nabble.com/T5%3A-How-to-create-an-external-URL-to-a-Tapestry-page--tp15436877p15446980.html
 Sent from the Tapestry - User mailing list archive at Nabble.com.



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]





-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]