HighTechTalks DotNet Forums  

Re: single space parsing problem?

Visual Studio.net (General) microsoft.public.vsnet.general


Discuss Re: single space parsing problem? in the Visual Studio.net (General) forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Ben
 
Posts: n/a

Default Re: single space parsing problem? - 08-27-2004 , 03:20 PM






Chris, perhaps you should urlencode the src attribute?


"Chris" <Chris (AT) discussions (DOT) microsoft.com> wrote

Quote:
Hi,

I have written an ASP.NET application.

I have a table in sql server 2000 that contains the filenames(images) for
files in a virtual directory. It appears that if the filename has spaces
in
it I can't show the image on the wepage.

the code in my aspx.vb page is this:

Response.Write("<img src=/maps/" & dsMaps.Tables(0).Rows(count).Item(0) &
"
width=642 height=496 border=1 onCLICK=hide('")

it works fine if the filename for example is : 11111_SHEARD&MIDLONG.gif
if however in the database the field is 11111_SHEARD & MIDLONG.gif and the
file in the directory is 11111_SHEARD & MIDLONG.gif , it will not show the
picture.

the view source of the rendered html page shows this for the page:

'<img src=/maps/11111_SHEARD & MIDLONG.gif width=642 height=496 border=1
onCLICK=hide('M0');show('M0')></div

how do i get it to show the image?

thanks

Chris








Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.