Server.URLEncode in ASP

admin

Administrator
Staff member
Hi, I'm experiencing problems when using the Server.URLEncode method in an ASP script.

The application I'm developing requires a URL to be emailed to the user, so that the user can click on the link in their email and load the page.

But if the ASP filename has spaces in it, MS Outlook treats the space as the end of the link (only the continuous text part of the URL is underlined and treated as a link).

I thought URL encoding the link (or at least the ASP filename part of the link) would sort this out, but it just converts the URL into a string of text that is no longer valid as a URL.

Tried everything I can think of - is there a way round this?? Any help you can give would be very much appreciated!spaces in the filename .......
instead of the file name.asp
use theFileName.asp
or the_file_name.asp

these are the common naming conventions, and you shouldnt be using spaces in there anyway, as it can cause problems in a lot more places like databases.
 
Top