Groups | Blog | Home
all groups > inetserver asp general > april 2005 >

inetserver asp general : long URLs


David Shorthouse
4/28/2005 1:24:29 PM
Hey folks,

Is anyone aware of any sort of asp coding to deal with long URLs? I have a
few asp that pull URLs from fields within a MS db, which then display on a
width-limited table. Is there any way to wrap these long URLs such that my
table doesn't get widened? e.g. wrapping at "/" or something similar?

Thanks for any advice,

Dave
______________________________
Remove "_SPAM" to reply directly.

David Shorthouse
4/28/2005 2:17:09 PM
Thanks for the idea. Well, yes, that would work but would mean someone
couldn't print the pages from their browser and be able to visit those URLs
unless I specified this differently in a print css.

Dave

--
______________________________
Remove "_SPAM" to reply directly.

[quoted text, click to view]

David Shorthouse
4/28/2005 2:18:08 PM
That's not a bad idea. Thanks.

Dave

--
______________________________
Remove "_SPAM" to reply directly.

[quoted text, click to view]

Drew
4/28/2005 3:45:01 PM
Maybe instead of showing the url, you can do this,

<a href=<%=rsURL("URL")%>>Click Here</a>

Would that work?

HTH,
Drew


[quoted text, click to view]

Drew
4/28/2005 3:49:08 PM
Sorry, my code is off... here is a correction,

<a href="<%=(rsURL.Fields.Item("URL").Value)%>">Click Here</a>

There you go,
Drew


[quoted text, click to view]

Kyle Peterson
4/28/2005 4:11:00 PM
You could do somethinguse the Left function to only show the 1st 25 or so
characters of the url.
But always put the full url in the href code for the link

<a href="<% =CmdListInfo("URL") %>"><% = Left(CmdListInfo("URL").Value),25)
%></a>

http://www.powerasp.com/content/new/function-reference-46.htm



[quoted text, click to view]

McKirahan
4/28/2005 9:17:23 PM
[quoted text, click to view]

Perhaps (but doubtfully):

http://tinyurl.com/

"Are you sick of posting URLs in emails only to have it break when sent
causing the recipient to have to cut and paste it back together? Then you've
come to the right place. By entering in a URL in the text field below, we
will create a tiny URL that will not break in email postings and never
expires."

Thomas
4/29/2005 12:00:00 AM
well, if the url is very long anyway, who would type it of a printed
document? ;-)

a solution might be do use some sort of redirecting on your site, ie
when the user types in http://mysite.com/show.asp?id=123 he is being
forwarded (request.redirect) to
http://mysite.com/somethingverylong/andhereisthepage.asp?withsome=options...

- thomas



[quoted text, click to view]

AddThis Social Bookmark Button