Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - If you are in this page then....
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

If you are in this page then....

 Post Reply Post Reply Page  12>
Author
Pegaso View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 13 February 2003
Location: Switzerland
Status: Offline
Points: 138
Post Options Post Options   Thanks (0) Thanks(0)   Quote Pegaso Quote  Post ReplyReply Direct Link To This Post Topic: If you are in this page then....
    Posted: 08 April 2003 at 8:18am

It's possible to make a Navigation Bar (include file) that will change depending of the page?

An Example:

If the navigation bar is opened in the site index1.asp then show image1

or

if the navigation bar is opened in the site index2.asp then show image2

I hope you understand my English.



Edited by Pegaso
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: 08 April 2003 at 2:46pm
if Request.ServerVariables("SCRIPT_NAME") = "/thispath/index1.asp" then
   show image one
elseif Request.ServerVariables("SCRIPT_NAME") = "/thispath/index2.asp" then
   show image one
end if

etc etc

Edited by MorningZ
Contribute to the working anarchy we fondly call the Internet
Back to Top
Pegaso View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 13 February 2003
Location: Switzerland
Status: Offline
Points: 138
Post Options Post Options   Thanks (0) Thanks(0)   Quote Pegaso Quote  Post ReplyReply Direct Link To This Post Posted: 08 April 2003 at 4:49pm

Thaks, tomorrow i will try.

Good night to all.

Back to Top
Pegaso View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 13 February 2003
Location: Switzerland
Status: Offline
Points: 138
Post Options Post Options   Thanks (0) Thanks(0)   Quote Pegaso Quote  Post ReplyReply Direct Link To This Post Posted: 09 April 2003 at 5:56am

OK your script works fine.

Now i'm testing a new solution:

include.asp

<%
if PageArt = 1 then
   Response.write "image1"
Else
   Response.write "image2"
End If
%>

And in each page i will add the definition and the value of Pageart.

Why i need this script?? I'm trying to utilize my forum navigation bar for the entire site, but in the forum i need some buttons, in the rest of the site i need some others buttons.

Someone have another good idea??

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: 09 April 2003 at 6:20am
so you look at the script name variable, and decide to trun on or off certain buttons

i am not sure where you see complexity in that, its a simple "if.... end if"
Contribute to the working anarchy we fondly call the Internet
Back to Top
Pegaso View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 13 February 2003
Location: Switzerland
Status: Offline
Points: 138
Post Options Post Options   Thanks (0) Thanks(0)   Quote Pegaso Quote  Post ReplyReply Direct Link To This Post Posted: 09 April 2003 at 6:41am

Now it work fine .

Now i must only define how many conditions i need in the entire site and decide if i will use a "if....end if" code or a Select Case code.

No it's not complex..... but i'm a new ASP "user" and i work with a good book and many many tests .

I have ever worked with Dreamweaver Ultradev and never looked the ASP code, now i have a new server and the Dreamweaver sites didn't work on it.....so i must remake each page.

It's a long work, but ASP is a great thing and it's really nice work with this language.

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: 09 April 2003 at 6:46am
not sure how far into "Classic ASP" you are.. but if its still really early, you may want to switch gears and learn ASP.NET instead

it's capable of so much more than last version of ASP
Contribute to the working anarchy we fondly call the Internet
Back to Top
Pegaso View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 13 February 2003
Location: Switzerland
Status: Offline
Points: 138
Post Options Post Options   Thanks (0) Thanks(0)   Quote Pegaso Quote  Post ReplyReply Direct Link To This Post Posted: 09 April 2003 at 6:56am

What are the difference?

An ASP server support ASP.NET?

Back to Top
 Post Reply Post Reply Page  12>

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.