Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: General / Classic ASP versions(v3.4.XX)
 Menu Buttons
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

NetMan96SS
Starting Member

15 Posts

Posted - 09 June 2009 :  17:16:16  Show Profile
I did a search of Menu Buttons and didn't find what I'm looking for.
Simply put ... I'd like to replace the Home | Profile | Register | ... menu links with a button type menu. I'm not a big asp programmer, but I can edit code without issue. I looked at the inc_header.asp file and found the menu ... but cannot seem to inject or replace the text with a simple .gif image. I know this is an easy thing to do ... but please bear with me.
Simple is best.
Any suggestions?

Thanks,
- Tony

- Tony

Etymon
Advanced Member

United States
2391 Posts

Posted - 09 June 2009 :  21:19:00  Show Profile  Visit Etymon's Homepage
You can use either double quotes or no quotes when writing out actual values, but for you to read what I am typing to you in this reply, double quotes are better because they organize your thoughts better to understand me more fully.


Double Quotes:

If your images are stored in your images folder, then write it like this:

Response.Write "<img src=""" & strImageURL & "home.gif"">"

The value for the variable strImageURL is stored in the FORUM_CONFIG_NEW table of your database.


Single Quotes:

Again, if your images are stored in the images folder, then you could also write it like the following. However, without the visual ques of the double quotes (for knowing where something begins and ends) it is more confusing to read and understand in a tutorial:

Response.Write "<img src=" & strImageURL & "home.gif>"


Making an Icon:

If you want to make your navigational images into icons, then create the .gif file, put it in the images folder (or where ever your images are stored) and then open inc_iconfiles.asp and create a new constant. Write the text value of the image along with its numeric width value and numeric height value. For example, if you call the new constant strNavHome, then what you put there may look like this (Note: In the example below the width is 50 and the height is 15):

const strNavHome = "home.gif|50|15"


Using an Icon:

Next, below is how you use the getCurrentIcon function when you want to display your image in your header. The function will know how to handle the constant you added to inc_iconfiles.asp.

In this case you could display the image in the header like this:

Response.Write getCurrentIcon(strNavHome,strAltText,"")


Using the Icon with other Elements:

If you were to added something like a TD tag in front and behind that it would look like this:

Response.Write "<td>" & getCurrentIcon(strNavHome,strAltText,"") & "</td>"


Other Values within the Icon:

For strAltText, you need to write it like this:

Response.Write "<td>" & getCurrentIcon(strNavHome,"This is the home button","") & "</td>"

The additional ,"" is for your image's attributes which can contain more than one attribute like this:

Response.Write "<td>" & getCurrentIcon(strNavHome,strAltText,"hspace=""0"" align=""absmiddle""") & "</td>"



If you have any other questions, just holler!


Cheers,

Etymon

Edited by - Etymon on 09 June 2009 21:24:54
Go to Top of Page

NetMan96SS
Starting Member

15 Posts

Posted - 10 June 2009 :  10:03:07  Show Profile
Ahhhh ... I was missing the src after img. Sheesh!
Thanks for the insight!
- Tony

- Tony
Go to Top of Page

Etymon
Advanced Member

United States
2391 Posts

Posted - 10 June 2009 :  12:15:49  Show Profile  Visit Etymon's Homepage
Sure thing! Glad you got it working!
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.88 seconds. Powered By: Snitz Forums 2000 Version 3.4.07