Go Back   Pligg CMS Forum > Pligg Development > Pligg Templates > Template Support > Old Templates > "Digital Nature"

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-23-2007, 07:12 PM
New Pligger
 
Join Date: Jan 2007
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Help with Menu.

I've just installed pligg a few days ago and I have read lots of posts, but no where do I see a straight question on how to add additional buttons at the top(header). Like a FAQ or an ABOUT button.

Can someone please help me with what I presume to be an easy task that I am overlooking.

What needs to be done to acclomplish this?

I know it has to do with the header.tpl but have had no luck with modifying it.
Reply With Quote
  #2 (permalink)  
Old 01-23-2007, 07:40 PM
Yankidank's Avatar
Coder/Designer
Pligg Version: SVN
Pligg Template: Wistie
 
Join Date: Dec 2005
Location: Ocala, FL
Posts: 1,832
Thanks: 110
Thanked 183 Times in 129 Posts
Send a message via AIM to Yankidank Send a message via Skype™ to Yankidank
EDIT: This has been updated. Part I (immediately below) teaches you how to add a button to the sidebar. Part II (my second post) teaches you how to modify the header navigational menu as requested by the original post.

Sidebar Menu: If you are using the default digitalnature template you do this:

1. Open /templates/digitalnature/sidebar_modules/misc_links_1.tpl
The contents of this file will look like this:
Code:
<li>
  <div class="box" id="sidenavbox">
    <h1><span class="expand"><a id="expnav" class="expand-up"></a></span><a class="htitle">{#PLIGG_Visual_Name#}</a></h1>
    <ul id="sidenav">
      <li><a href="{$my_pligg_base}/shakeit.php?part=upcoming&order=1">{#PLIGG_Visual_Pligg_For_Stories#}</a></li>
      <li><a href="{$URL_submit}">{#PLIGG_Visual_Submit_A_New_Story#}</a></li>
      {if $Enable_Sneak eq 'true'}
      <li><a href='{$URL_sneak}'>{#PLIGG_Visual_Sneak#}</a></li>
      {/if}
      
      {if $Enable_Tags eq 'true'}
      <li><a href='{$URL_tagcloud}'>{#PLIGG_Visual_Tags#}</a></li>
      {/if}
      <li><a href='{$URL_topstories}'>{#PLIGG_Visual_Top_Stories#}</a></li>
      <li><a href='{$URL_topusers}'>{#PLIGG_Visual_Top_Users#}</a></li>
    </ul>
  </div>
</li>
2. Find where you wish to place your new button. I don't suggest adding more than 2 buttons to the header navbar because it will make it too wide for lower resolution computers. In this example I want to post a link after the "Live" (otherwise known as Sneak) button. As you can see the Live/Sneak button looks like this:
Code:
<li><a href='{$URL_sneak}'>{#PLIGG_Visual_Sneak#}</a></li>
However, you must not forget that sneak has "if" tags around it, so it actually should look something like this:
Code:
{if $Enable_Sneak eq 'true'}
      <li><a href='{$URL_sneak}'>{#PLIGG_Visual_Sneak#}</a></li>
      {/if}
These "if" tags check to see if your Pligg settings allow this button to be displayed. To make sure that the new button you are about to add is displayed, make sure that it's not found between these "if" tags.
Now that I have found where I need to place the new button, lets give you an example of what a new button would look like:
Code:
<li><a href='./faq-en.php'>About</a></li>
This example creates a new sidebar button the the left named "About" that points to your faq-en.php file.

From here you shuold know enough basic html to get you through it. Here's the end result with an "About" button placed after the Live/Sneak button.
Code:
<li>
  <div class="box" id="sidenavbox">
    <h1><span class="expand"><a id="expnav" class="expand-up"></a></span><a class="htitle">{#PLIGG_Visual_Name#}</a></h1>
    <ul id="sidenav">
      <li><a href="{$my_pligg_base}/shakeit.php?part=upcoming&order=1">{#PLIGG_Visual_Pligg_For_Stories#}</a></li>
      <li><a href="{$URL_submit}">{#PLIGG_Visual_Submit_A_New_Story#}</a></li>
      {if $Enable_Sneak eq 'true'}
      <li><a href='{$URL_sneak}'>{#PLIGG_Visual_Sneak#}</a></li>
      {/if}
      <li><a href='./faq-en.php'>About</a></li>
      
      {if $Enable_Tags eq 'true'}
      <li><a href='{$URL_tagcloud}'>{#PLIGG_Visual_Tags#}</a></li>
      {/if}
      <li><a href='{$URL_topstories}'>{#PLIGG_Visual_Top_Stories#}</a></li>
      <li><a href='{$URL_topusers}'>{#PLIGG_Visual_Top_Users#}</a></li>
    </ul>
  </div>
</li>
__________________
Need a Pligg Host?
Get 3 free months
when you buy a year of hosting.
Use the coupon PLIGG at either...
MidPhase hosting starting at $7.95/month.
ANhosting hosting starting as low as $4.95/month.

Last edited by Yankidank; 01-23-2007 at 08:28 PM..
Reply With Quote
  #3 (permalink)  
Old 01-23-2007, 08:10 PM
New Pligger
 
Join Date: Jan 2007
Posts: 24
Thanks: 0
Thanked 0 Times in 0 Posts
Hey Yankidank this was excellent. Very clear and more than helpful. Thanks!

However, I modified the misc_links1.tpl and that allowed me to have an "About" button on the left side. Not exactly what I wanted but now I know how to modify that part, which I can see happening in the future.

But what I am trying to actually do is add a button at the top of the page, after "Login" and "Register".

Thanks for the friendly directions though.
Reply With Quote
  #4 (permalink)  
Old 01-23-2007, 08:25 PM
Yankidank's Avatar
Coder/Designer
Pligg Version: SVN
Pligg Template: Wistie
 
Join Date: Dec 2005
Location: Ocala, FL
Posts: 1,832
Thanks: 110
Thanked 183 Times in 129 Posts
Send a message via AIM to Yankidank Send a message via Skype™ to Yankidank
Whoops, my bad. I'll edit the above post to make it say "sidebar".
Part II, the header menu:

This method is similar to the first guide.

1. Open up /templates/digitalnature/header.tpl
2. Find:
Code:
<li id="navlogout"><a href="{$URL_logout}" class="main"><span>{#PLIGG_Visual_Logout#}</span></a></li>
{else}
<li id="navlogin"><a href="{$URL_login}" class="main"><span>{#PLIGG_Visual_Login#}</span></a></li>
<li id="navregister"><a href="{$URL_register}" class="main"><span>{#PLIGG_Visual_Register#}</span></a></li>
{/if} 
</ul>
Add a new line after any of the </li> or before <li>. It should look like this:
Code:
<li id="about"><a href="./faq-en.php" class="main"><span>About</span></a></li>
__________________
Need a Pligg Host?
Get 3 free months
when you buy a year of hosting.
Use the coupon PLIGG at either...
MidPhase hosting starting at $7.95/month.
ANhosting hosting starting as low as $4.95/month.
Reply With Quote
Reply

Thread Tools
Display Modes
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Similar Threads
Thread Thread Starter Forum Replies Last Post
Dropdown menu for categories (digg style) skroeger General Help 8 05-11-2008 05:43 PM
template menu little crooked, any suggestions???? m1gu3 Template Support 0 05-05-2008 10:49 AM
How to get a dropdown menu for subcategories ? jedimaster General Help 3 04-04-2008 04:28 PM
Multiple Categories Menu Needed mobilpress "yget" 0 03-23-2007 08:24 AM
problem/reporting drop menu appears black Pentarix Template Support 3 01-08-2006 04:33 AM


Search Engine Friendly URLs by vBSEO 3.2.0