Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Dynamic images
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Dynamic images

 Post Reply Post Reply
Author
rosejr View Drop Down
Groupie
Groupie
Avatar

Joined: 07 November 2001
Location: United States
Status: Offline
Points: 46
Post Options Post Options   Thanks (0) Thanks(0)   Quote rosejr Quote  Post ReplyReply Direct Link To This Post Topic: Dynamic images
    Posted: 30 January 2004 at 5:24pm

I'm developing a site where I am going to put the entire page header into a include file.  But the problem is that in that each page has its own header image.  Is there a script or any way to dynamically change the image based on what page is selected?

Thanks

 

 

Back to Top
MorningZ View Drop Down
Senior Member
Senior Member
Avatar

Joined: 06 May 2002
Location: United States
Status: Offline
Points: 1793
Post Options Post Options   Thanks (0) Thanks(0)   Quote MorningZ Quote  Post ReplyReply Direct Link To This Post Posted: 31 January 2004 at 8:36am

Case Select Which Page
     Case ThisPage
          SomeValue = "ThisGraphic.jpg"
     Case ThatPage
          SomeValue = "ThatGraphic.jpg"
Case Else

later on.....

<img src="<%= SomeValue %>"/>

 

Contribute to the working anarchy we fondly call the Internet
Back to Top
Semikolon View Drop Down
Senior Member
Senior Member


Joined: 09 September 2003
Location: Norway
Status: Offline
Points: 1718
Post Options Post Options   Thanks (0) Thanks(0)   Quote Semikolon Quote  Post ReplyReply Direct Link To This Post Posted: 31 January 2004 at 9:16am

or you can add

     Const strImage = "image.gif"

above the included header file and then

     <img src="<% = strImage %>" />

to the header include file

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.