Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to get a server side image path on client side

Status
Not open for further replies.

lhoudusse

Programmer
Jun 21, 2002
4
FR
Hi!

I want to know how to get the image path of an image which is on server side.
but my code is executed on client side.


see my code:

<SCRIPT LANGUAGE=&quot;VBScript&quot;>
ImageList1.ListImages.Add 1,&quot;Site&quot;,loadpicture(&quot;D:\temp\site.gif&quot;)
set TreeView1.ImageList = ImageList1
</SCRIPT>

so the image site.gif is on client side

see:

<SCRIPT LANGUAGE=&quot;VBScript&quot;>
ImageList1.ListImages.Add 1,&quot;Site&quot;,loadpicture(&quot;<% response.write server.mapppath(&quot;images\site\silver_10x10.gif&quot;) %>&quot;)
set TreeView1.ImageList = ImageList1
</SCRIPT>

so i have an error &quot;invalid path&quot; because the prog research the image on the client side with a path which is only valid on the server side
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top