Go Back   Pligg Forum > Pligg Help > General Help
Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 09-19-2007, 06:31 AM
dragan dragan is offline
Casual Pligger
 
Join Date: Aug 2007
Posts: 74
Downloads: 13
Uploads: 0
Thanks: 2
Thanked 1 Time in 1 Post
Question Howto Ad additional navigation to nav bar?

Pligg 9.8
Server: cPanel, Apache2.2
PHP 5
Website: Kiefit.com

Hello,

How can I ad additional links- navigation to the navigation bar?

==================================================
Home Login Register Live Top users Tag cloud ????? ????? ==================================================

How is the exact procedure to customize the script?

Thanks.
Reply With Quote
Sponsored Links
Check out the New Templates at the Pligg Pro Shop.
  #2 (permalink)  
Old 09-19-2007, 07:41 AM
Andtony Andtony is offline
Constant Pligger
 
Join Date: Feb 2007
Posts: 181
Downloads: 8
Uploads: 0
Thanks: 13
Thanked 22 Times in 19 Posts
You can edit your navigation bar by opening your template's header.tpl file. The adding procedure vary's a bit depending on what kind of links you want to add. Like links that are only visible to users who are logged in or logged out etc.
Reply With Quote
  #3 (permalink)  
Old 09-20-2007, 08:27 AM
dragan dragan is offline
Casual Pligger
 
Join Date: Aug 2007
Posts: 74
Downloads: 13
Uploads: 0
Thanks: 2
Thanked 1 Time in 1 Post
Hello Andtony,

I would like to ad links that are visible to users who are logged in or logged out as well.
How can I do that?

Thanks.
Reply With Quote
  #4 (permalink)  
Old 09-20-2007, 06:09 PM
not2serious's Avatar
not2serious not2serious is offline
Pligg Donor
Pligg Version: v0.96 w/modifications
Pligg Template: Yget w/modifications
 
Join Date: Apr 2007
Location: East Coast, USA
Posts: 226
Downloads: 29
Uploads: 0
Thanks: 16
Thanked 16 Times in 15 Posts
Code:
{if $pagename eq "upcoming"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut3"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut4"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li> <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>

{elseif $pagename eq "published"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut4"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut3"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li> <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>

{elseif $pagename eq "submit"}
This is how I did linked tabs to additional pages. Edit the header.tbl file. The red and green code was added to each {if} and they provide a direct link to the appropriate page. I am still working on this, but it does appear to work for me.
__________________
My Pligg Site: Critique My Art
My Arts Directory: Links 2 Arts
Reply With Quote
  #5 (permalink)  
Old 09-21-2007, 07:30 AM
dragan dragan is offline
Casual Pligger
 
Join Date: Aug 2007
Posts: 74
Downloads: 13
Uploads: 0
Thanks: 2
Thanked 1 Time in 1 Post
[Solved] Howto Ad additional navigation to nav bar?

Quote:
Originally Posted by not2serious View Post
Code:
{if $pagename eq "upcoming"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut3"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut4"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li> <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>

{elseif $pagename eq "published"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut4"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut3"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li> <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>

{elseif $pagename eq "submit"}
This is how I did linked tabs to additional pages. Edit the header.tbl file. The red and green code was added to each {if} and they provide a direct link to the appropriate page. I am still working on this, but it does appear to work for me.
Hi and thank you. It works fine. :-)
Reply With Quote
  #6 (permalink)  
Old 09-21-2007, 08:49 PM
not2serious's Avatar
not2serious not2serious is offline
Pligg Donor
Pligg Version: v0.96 w/modifications
Pligg Template: Yget w/modifications
 
Join Date: Apr 2007
Location: East Coast, USA
Posts: 226
Downloads: 29
Uploads: 0
Thanks: 16
Thanked 16 Times in 15 Posts
Hi dragan,

I took a look at your site. The additional table look great.

One thing you will need to do is add the code for the additional tabs to every "if/else". For example, if you select "Submit A Story" or "Contact," you will see that only the standard tabs are on those pages. Additionally, you will need to create statements for each new tab.

Code:
{if $pagename eq "upcoming"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut3"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut4"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li>   
                    <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>
So you will need to to change
Quote:
class="navbut3"
to
Quote:
class="navbut4"
For the tab that your are writing the "if/esle" rule for. This means that if the tab you have added is "Contact," then that line must have class="navbut4" and all the others must have class="navbut3". If you look at my sample, you will see this difference.

More questions ??? Post to this thread. Feel free to click that "Thanks" Button if I helped you :-).
__________________
My Pligg Site: Critique My Art
My Arts Directory: Links 2 Arts

Last edited by not2serious : 09-21-2007 at 08:53 PM.
Reply With Quote
The Following User Says Thank You to not2serious For This Useful Post:
  #7 (permalink)  
Old 10-28-2007, 12:46 AM
proppd proppd is offline
New Pligger
 
Join Date: Oct 2007
Posts: 8
Downloads: 1
Uploads: 0
Thanks: 0
Thanked 1 Time in 1 Post
My question is - can we do some kind of loop in PHP to get all the category names and automatically create navigation buttons for all categories?

Doing it manually works - for example to link to the videos category
HTML Code:
<li><a href="{$URL_category}Videos" class="navbut3"><span>Videos</span></a></li> 
However I would think it would be possible to have PHP extract the categories for both the link and the link text. I'm not familar enough with php or pligg to attempt this myself though.
Reply With Quote
  #8 (permalink)  
Old 05-05-2008, 03:17 PM
zuperman zuperman is offline
New Pligger
 
Join Date: May 2008
Posts: 14
Downloads: 11
Uploads: 0
Thanks: 1
Thanked 1 Time in 1 Post
Quote:
Code:
{if $pagename eq "upcoming"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut3"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut4"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li> <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>

{elseif $pagename eq "published"}
		    <li><a href="{$my_base_url}{$my_pligg_base}" class="navbut4"><span>{#PLIGG_Visual_Published_News#}</span></a></li>
		    <li><a href="{$URL_upcoming}" class="navbut3"><span>{#PLIGG_Visual_Pligg_Queued#} ({$queued})</span></a></li>
		    <li><a href="{$URL_submit}" class="navbut3"><span>{#PLIGG_Visual_Submit_A_New_Story#}</span></a></li>
		    <li><a href="http://www.critiquemyart.com/How_To.php" class="navbut3"><span>FAQs & How To's</span></a></li> <li><a href="http://www.critiquemyart.com/Contest_Page.php" class="navbut3"><span><strong>* CONTESTS *</strong></span></a></li>

{elseif $pagename eq "submit"}
This is how I did linked tabs to additional pages. Edit the header.tbl file. The red and green code was added to each {if} and they provide a direct link to the appropriate page. I am still working on this, but it does appear to work for me.
Works great! But, how can I add navigation button only for registered users (just like Submit a new story button)?
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

vB code is On
Smilies are Off
[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
Page Navigation Andreiii Bug Report 2 09-06-2007 06:18 PM
Navigation Overhaul 3dKiller Suggestions 25 08-07-2006 09:22 PM
Add-on: Custom Navigation kbeeveer46 Pligg Mods 0 08-05-2006 10:35 AM
Navigation enviralabs "Mollio-Beat" 0 07-13-2006 12:59 AM
Right navigation enviralabs Bug Report 0 07-09-2006 02:47 AM


LinkBacks Enabled by vBSEO 3.0.0