Welcome to the E-Blah Community!
We would like to welcome you to our community and invite you to register an account or login.
Being a registered member is important, as it gives you several advantages over the normal Guest status. After registering you will be able to download files and images, post messages, and access member-only portions of the forum - just to name a few. Registration is quick and simple, and only takes about a minute of your time.

E-Blah Community    Technical Support    Question and Answer  ›  How do I add a button to my menu bar?
Users Browsing Forum
MSN Bot, Yahoo! Bot and 1 Guests

How do I add a button to my menu bar?  This thread currently has 898 views. Print
1 Pages 1 Recommend Thread
classixuk
August 19, 2006, 1:57pm Report to Moderator Report to Moderator
E-Blah Member
Posts: 64
Posts Per Day: 0.07
Time Online: 16 hours 57 minutes
Hi all,

I was wondering how I go about adding a button to my menu bar?

I'd like to add a "recent posts" button.

I know how to make the image and hyperlink it etc, but I don't know where the "menubar" string is defined.

Thanks.

P.S. Justin and mods. I've asked each question that I need to be answered in a seperate thread. This isn't to increase my post count  , but simply for the reason that users with the same question in the future will be able to find the answer quickly. Hope that's OK with you.
Logged Offline
Private Message Private message
Justin
August 19, 2006, 3:47pm Report to Moderator Report to Moderator

The E-Blah Developer
E-Blah Programmer
Posts: 15,080
Gender: Male
Posts Per Day: 6.42
Reputation: 93.42%
Reputation Score: +298 / -21
Time Online: 37 days 1 hours 13 minutes
Location: Tallassee, AL
Age: 22
You can add the buttons after <blah v="$menu">


I do installs for $25 and upgrades for $20.
Technical support is always free.

  Donate to E-Blah!  

My Websites: Revolution Reality (My Blog)  |  MinistryTalk.com  |  Portfolio

"But you, O Lord, are a compassionate and gracious God, slow to anger, abounding in love and faithfulness." — Psalm 86:15 NIV

Logged Offline
Site Site Private Message Private message Reply: 1 - 14
classixuk
August 19, 2006, 4:44pm Report to Moderator Report to Moderator
E-Blah Member
Posts: 64
Posts Per Day: 0.07
Time Online: 16 hours 57 minutes
I was going to do that Justin, but me being a perfectionist, I wanted my last button to remain as Log in/out and my first to be home.  

I need to insert the recent posts button into the $menu code.
Logged Offline
Private Message Private message Reply: 2 - 14
Ryan
August 19, 2006, 7:19pm Report to Moderator Report to Moderator

Inactive Support Team
Posts: 1,799
Gender: Male
Posts Per Day: 1.11
Reputation: 85.00%
Reputation Score: +85 / -15
Time Online: 11 days 8 hours 2 minutes
Location: Ontario
Age: 29
In Routines.pl find the parts in black and add the parts in red:

$latestposts  = qq~<a href="$surl"><img src="/adasdf.gif"></a>~;
     $homemenu = qq~<a href="$surl">$img{'home'}</a>~;
     $calmenu = qq~<a href="$surl\lv-cal/">$img{'cal'}</a>~;
     $searchmenu = qq~<a href="$surl\lv-search/~; $searchmenu .= "b-$URL{'b'}/" if($URL{'b'}); $searchmenu .= qq~">$img{'search'}</a>~;
     $menubar = "$homemenu $latestposts$sep$help$msp2$calmenu$msp2$searchmenu$msp2";
Logged Offline
Site Site Private Message Private message YIM YIM Reply: 3 - 14
classixuk
August 20, 2006, 4:00am Report to Moderator Report to Moderator
E-Blah Member
Posts: 64
Posts Per Day: 0.07
Time Online: 16 hours 57 minutes
Wow Ryan, thanks for that.

You're really good at this aren't you!

That's another increase on your rep.

Logged Offline
Private Message Private message Reply: 4 - 14
classixuk
August 20, 2006, 9:11pm Report to Moderator Report to Moderator
E-Blah Member
Posts: 64
Posts Per Day: 0.07
Time Online: 16 hours 57 minutes
Quoted from Ryan
In Routines.pl find the parts in black and add the parts in red:

$latestposts  = qq~<a href="$surl"><img src="/adasdf.gif"></a>~;
     $homemenu = qq~<a href="$surl">$img{'home'}</a>~;
     $calmenu = qq~<a href="$surl\lv-cal/">$img{'cal'}</a>~;
     $searchmenu = qq~<a href="$surl\lv-search/~; $searchmenu .= "b-$URL{'b'}/" if($URL{'b'}); $searchmenu .= qq~">$img{'search'}</a>~;
     $menubar = "$homemenu $latestposts$sep$help$msp2$calmenu$msp2$searchmenu$msp2";


Just a quick update for anybody else who wants to do this. Ryan's code is almost correct, but the link from the button will take you to the front page of your forums instaed of the recent posts page.

If you'd like to have a button inserted into your menubar for recent posts (in this example I will place it after the "home" button) then follow Ryan's guide but use the code below:

Quoted Text
$homemenu = qq~<a href="$surl">$img{'home'}  

</a>~;
      $latestposts  = qq~<a

href="$surl\v-search/p-topten/">  <img

src="/blahdocs/template/ mac_revisited/buttons/recentpost

.gif
" alt="Recent Posts" border="0"></a>~;

     $calmenu = qq~<a

href="$surl\lv-cal/">$img{'cal'}</a>~;
     $searchmenu = qq~<a href="$surl\lv-search/~;

$searchmenu .= "b-$URL{'b'}/" if($URL{'b'}); $searchmenu

.= qq~">$img{'search'}</a>~;
     $menubar =

"$homemenu $latestposts$sep$help$msp2$calmenu$msp2$search

menu$msp2";


The red parts of the code are what you need to copy and paste.

Where the red code turns green you will need to type the name of your templates folder (e.g. sub_silver, winter or mac_revisited etc.)

Where the red code turns blue you will need to type the name of your button for recent posts (e.g. recentposts.gif, recent.gif, rec_post.gif etc.)


Hope that helps, and thanks to Ryan for giving me the code.

P.S. Remember, if you ever change themes you will need to go back and delete these lines from your routine.pl unless you are using the same style of buttons, otherwise you will have one odd button in your menubar!

  

Revision History (1 edits)
classixuk  -  August 20, 2006, 10:59pm
Logged Offline
Private Message Private message Reply: 5 - 14
turbomad1
September 2, 2006, 7:14am Report to Moderator Report to Moderator

im am the mad1
Posts: 355
Gender: Male
Posts Per Day: 0.40
Time Online: 6 days 1 hours 2 minutes
Location: coventry (uk)
Age: 32
i have done this and its taking it to the recent post and that is great but how would i alter it for the unread post?
Logged Offline
Site Site Private Message Private message Windows Live Messenger WLM Reply: 6 - 14
Martin
September 2, 2006, 7:25am Report to Moderator Report to Moderator

I love E-Blah
10 Series Support Team
Posts: 4,573
Gender: Male
Posts Per Day: 3.07
Reputation: 98.60%
Reputation Score: +212 / -3
Time Online: 35 days 21 hours 17 minutes
Location: UK
Age: 50
Try Changing:

Code
<a href="$surl\v-search/p-topten/">


to:

Code
<a href="$surl\lv-search/p-newposts/">



Martin's Reputation: Increase
Logged Offline
Site Site Private Message Private message Reply: 7 - 14
turbomad1
September 2, 2006, 7:25am Report to Moderator Report to Moderator

im am the mad1
Posts: 355
Gender: Male
Posts Per Day: 0.40
Time Online: 6 days 1 hours 2 minutes
Location: coventry (uk)
Age: 32
thank you matey
Logged Offline
Site Site Private Message Private message Windows Live Messenger WLM Reply: 8 - 14
Martin
September 2, 2006, 7:27am Report to Moderator Report to Moderator

I love E-Blah
10 Series Support Team
Posts: 4,573
Gender: Male
Posts Per Day: 3.07
Reputation: 98.60%
Reputation Score: +212 / -3
Time Online: 35 days 21 hours 17 minutes
Location: UK
Age: 50
If you wait a few days I plan to make mods to add buttons for both Latest Posts and Unread Posts



Martin's Reputation: Increase
Logged Offline
Site Site Private Message Private message Reply: 9 - 14
turbomad1
September 2, 2006, 7:45am Report to Moderator Report to Moderator

im am the mad1
Posts: 355
Gender: Male
Posts Per Day: 0.40
Time Online: 6 days 1 hours 2 minutes
Location: coventry (uk)
Age: 32
all sorted now thank you
Logged Offline
Site Site Private Message Private message Windows Live Messenger WLM Reply: 10 - 14
turbomad1
September 2, 2006, 8:05am Report to Moderator Report to Moderator

im am the mad1
Posts: 355
Gender: Male
Posts Per Day: 0.40
Time Online: 6 days 1 hours 2 minutes
Location: coventry (uk)
Age: 32
Quoted from Martin
If you wait a few days I plan to make mods to add buttons for both Latest Posts and Unread Posts


ok thank you i have done that one now matey i just need to sort a button image out now thank you
Logged Offline
Site Site Private Message Private message Windows Live Messenger WLM Reply: 11 - 14
Martin
September 2, 2006, 8:09am Report to Moderator Report to Moderator

I love E-Blah
10 Series Support Team
Posts: 4,573
Gender: Male
Posts Per Day: 3.07
Reputation: 98.60%
Reputation Score: +212 / -3
Time Online: 35 days 21 hours 17 minutes
Location: UK
Age: 50
Here's a button for you.




This post contains attachments; to download them you must login.




Martin's Reputation: Increase
Logged Offline
Site Site Private Message Private message Reply: 12 - 14
turbomad1
September 2, 2006, 8:25am Report to Moderator Report to Moderator

im am the mad1
Posts: 355
Gender: Male
Posts Per Day: 0.40
Time Online: 6 days 1 hours 2 minutes
Location: coventry (uk)
Age: 32
thank you matey
Logged Offline
Site Site Private Message Private message Windows Live Messenger WLM Reply: 13 - 14
turbomad1
September 2, 2006, 10:05am Report to Moderator Report to Moderator

im am the mad1
Posts: 355
Gender: Male
Posts Per Day: 0.40
Time Online: 6 days 1 hours 2 minutes
Location: coventry (uk)
Age: 32
i have just noticed the new posts doesnt show all the new posts on my forum would there be a reason for this?

its not showing anything up from the projects section on there at least i havnt gone through and checked all categories/forums on there as yet to find out which ones do and dont

Revision History (1 edits)
turbomad1  -  September 2, 2006, 10:32am
Logged Offline
Site Site Private Message Private message Windows Live Messenger WLM Reply: 14 - 14
1 Pages 1 Recommend Thread
Print

E-Blah Community    Technical Support    Question and Answer  ›  How do I add a button to my menu bar?