Wrox Programmer Forums
|
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 23rd, 2004, 05:24 AM
Authorized User
 
Join Date: Apr 2004
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Default Space in URL

Hi there! I have a text box whose value will be appended to a URL. If there are spaces in the text box, how do they get encoded in the URL? Will the white space be changed to "%27" or to "+"?

I've researched that the max length of URL is 2,048 characters. Will a white space consume more than one character?

 
Old June 23rd, 2004, 05:27 AM
Authorized User
 
Join Date: Apr 2004
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Oops..I meant "%20", not "%27"

I hope someone can help me on this..Thanks!

 
Old June 23rd, 2004, 05:27 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

It gets encoded as %20

So it should be 3 characters, if at all you store the encoded value.

_________________________
-Vijay G
Strive for Perfection
 
Old June 23rd, 2004, 05:36 AM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 331
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to qazi_nomi
Default

Dear you can simply trencate spaces by using methode of
trim()

Love 4 all
 
Old June 23rd, 2004, 05:39 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

Hi qazi_nomi,

But one cannot use trim function to remove the space that is within a string value like "my name" cannot be trimmed as "myname" using trim()

Cheers!

_________________________
-Vijay G
Strive for Perfection
 
Old June 23rd, 2004, 11:29 PM
Authorized User
 
Join Date: Apr 2004
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Ok..thanks happygv!!!






Similar Threads
Thread Thread Starter Forum Replies Last Post
URL Redirect based on given URL somnath.kartic VS.NET 2002/2003 1 August 2nd, 2012 08:21 AM
URL rewriting with URL forwarding mtabyana BOOK: Professional Search Engine Optimization with PHP: A Dev's Guide to SEO ISBN: 978-0-470-10092-9 0 October 22nd, 2007 08:22 AM
Looks like a space but it isn't. rstelma SQL Server 2000 3 September 7th, 2005 07:17 PM
space crmpicco Javascript How-To 1 February 7th, 2005 01:26 PM
extract URL from Favorites (.URL Files) PhilHawks VB.NET 2002/2003 Basics 2 November 2nd, 2004 04:35 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.