Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Programming Discussions

Reply
 
Thread Tools Display Modes
  #1  
Old 06-28-2008, 12:12 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Need another set of eyes please!

I'm trying to add some links to the drop down UserCP menu in the navbar.

I've added the following in two places in the navbar template:

Code:
	<tr><td class="vbmenu_option"><a href="album.php?$session[sessionurl]do=addalbum">$vbphrase[add_album]</a></td></tr>
	<tr><td class="vbmenu_option"><a href="downloads.php?$session[sessionurl]do=my">$vbphrase[ecdownloads_my_files]</a></td></tr>
It's strange. In IE7, a space shows up, but no text. In FF, both spaces will show up, but text from only one link will show.

Any ideas?
Reply With Quote
  #2  
Old 06-29-2008, 12:59 PM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Please post your navbar template.
Reply With Quote
  #3  
Old 06-29-2008, 05:28 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Absolutely!

Code:
<div class="navbar">
<if condition="$vbulletin->options['mo37_navbar_home']!=''">
<a class="navbar" href="{$vbulletin->options['mo37_navbar_home']}$session[sessionurl_q]">Home</a>
<else />
<a class="navbar" href="index.php$session[sessionurl_q]">Home</a>
</if>
<if condition="$show['member']">
<a class="navbar" href="search.php?$session[sessionurl]do=getnew">New Posts</a>
<a class="navbar" href="usercp.php$session[sessionurl_q]"><if condition="$vbulletin->userinfo[pmunread]>0"><strong>*UserCP*</strong><else />UserCP</if></a><else />
<a class="navbar" href="search.php?$session[sessionurl]do=getdaily">Today's Posts</a>
</if>
<if condition="$vbulletin->options['mo37_default_style_link']==1">
<a class="navbar" href="{$vbulletin->options['mo37_navbar_home']}?$session[sessionurl]styleid={$vbulletin->options['mo37_default_style']}">PC Mode</a>
</if>
</div>
$ad_location[ad_navbar_below]
Thanks!
Reply With Quote
  #4  
Old 06-30-2008, 06:16 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You don't actually have any User CP dropdown code in there...
Reply With Quote
  #5  
Old 06-30-2008, 01:17 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm confused then.

I make the changes in there and they show up (well kind of). If I didn't have any drop down code in there, then how would they show up? I've disabled all plug-ins, and this same drop down shows up, with the blank spaces for my modifications.

In a stock version of vBulletin 3.7.2, if I wanted to add this code, I would add it to this template, correct?

Some observations while trying to mess with this:

The link to add an album in this drop down, only shows up if I'm already in the UserCP.

The link to check my downloads only shows up if I'm in the downloads section.

If I could figure out what code to add to show these two links at all times, then I think it would solve it.
Reply With Quote
  #6  
Old 07-01-2008, 07:03 AM
Dismounted's Avatar
Dismounted Dismounted is offline
 
Join Date: Jun 2005
Location: Melbourne, Australia
Posts: 15,047
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You have a custom style, on the default style, you would edit the navbar template to add links to navbar dropdowns, add links, etc.
Reply With Quote
  #7  
Old 07-01-2008, 12:14 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Strange - I'm using hte stock vbulletin skin, just changed the colors and buttons some.

Any ideas why the links I'm trying to add will show up when they do and not at other times? is it related?
Reply With Quote
  #8  
Old 07-01-2008, 12:41 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So I reverted back to the original version of the template. No drop down.

Then I slowly added in the various changes I have and see where the drop down came to be:

Code:
<td id="usercpoptions" class="vbmenu_control"><a href="usercp.php$session[sessionurl_q]">$vbphrase[user_cp]</a>
        <script type="text/javascript"> vbmenu_register("usercpoptions"); </script></td>
Without that code, I don't have a drop down, with it, I do.

So, it's not a custom style, or anything.

I just can't figure out why I can't get these two links to show up all the time. They are only showing up some of the time.

I've attached 3 images.

no_links shows up when you're just about anywhere in the forum.

Go to the userCP page and album_link is what you see.

If you go to the downloads page, files_link is what you see.

Somehow, it's like there's a conditional going on....I just can't figure it out!
Attached Images
File Type: png no_links.PNG (2.7 KB, 0 views)
File Type: png album_link.PNG (3.0 KB, 0 views)
File Type: png files_link.PNG (3.0 KB, 0 views)
Reply With Quote
  #9  
Old 07-02-2008, 08:30 PM
ssslippy ssslippy is offline
 
Join Date: Jan 2006
Posts: 877
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The phrases u are trying to use are not global phrases. With custom phrases from mods u can search for them in the phrase manager and make them global. You may need to be in debug mode to do this,
Reply With Quote
  #10  
Old 07-04-2008, 04:45 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That would explain the issue! Thanks!

hrmmm - is there an article on how to make a phrase global?
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

Forum Jump


All times are GMT. The time now is 11:38 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07640 seconds
  • Memory Usage 2,264KB
  • Queries Executed 14 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (3)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (3)postbit_attachment
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_attachment
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete