The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Social Bookmarks not showing?
I am modifying the default VB4.0.2 template files.
I intend to move the Social Book marks bit into the footer section. For some reason though they are not showing up... They showed up perfectly fine in their default position under a thread but when I move the code into the footer section I only get the word "Bookmarks" (which is the title of the original block) shown but no bookmark links. I removed the conditional <vb:if...> to see if that was causing the problem but alas not? Also - secondary to the above - I would like the bookmarks to appear on ALL pages in the footer. How do I enable them to be shown no matter what page the user is viewing? Here is the current snippet of code from the 'footer' template: Code:
{vb:raw ad_location.ad_footer_start} {vb:raw ad_location.global_above_footer} <div id="footer"> <vb:if condition="$show['dst_correction']"> <!-- auto DST correction code --> <form action="profile.php?do=dst" method="post" name="dstform"> <input type="hidden" name="s" value="{vb:raw session.sessionhash}" /> <input type="hidden" name="securitytoken" value="{vb:raw bbuserinfo.securitytoken}" /> <input type="hidden" name="do" value="dst" /> </form> <script type="text/javascript"> <!-- var tzOffset = {vb:raw bbuserinfo.timezoneoffset} + {vb:raw bbuserinfo.dstonoff}; var utcOffset = new Date().getTimezoneOffset() / 60; if (Math.abs(tzOffset + utcOffset) == 1) { // Dst offset is 1 so its changed document.forms.dstform.submit(); } //--> </script> <!-- / auto DST correction code --> </vb:if> <script type="text/javascript"> <!-- // Main vBulletin Javascript Initialization vBulletin_init(); //--> </script> {vb:raw template_hook.footer_javascript} </div> </div> <!-- closing div for body_wrapper --> <div class="below_body"> <div class="mycustom_footer_box"> <h4><span>{vb:rawphrase bookmarks}</span></h4> <div id="social_bookmarks_list"> <ul class="icon_list">{vb:raw bookmarksites}</ul> </div> </div> <div id="footer_time" class="shade footer_time">{vb:rawphrase all_times_are_gmt_x_time_now_is_y}</div> <div id="footer_copyright" class="shade footer_copyright"> <!-- Do not remove this copyright notice --> {vb:rawphrase powered_by_vbulletin} <!-- Do not remove this copyright notice --> </div> <div id="footer_morecopyright" class="shade footer_morecopyright"> <!-- Do not remove cronimage or your scheduled tasks will cease to function --> {vb:raw cronimage} <!-- Do not remove cronimage or your scheduled tasks will cease to function --> {vb:raw vboptions.copyrighttext} </div> {vb:raw ad_location.ad_footer_end} </div> |
#2
|
||||
|
||||
My guess would be you didn't preregister the variable for use in the footer template. Cellarius wrote a really good article that you may be interested in - [vB4] Rendering templates and registering variables - a short guide Also, I'm not even sure if that will do the trick since the footer gets rendered pretty early on (when global.php is called). So, your best bet is to use a template_hook (may have to add one) instead.
|
#3
|
|||
|
|||
Thanks for the pointers - I'll have a look at the guides and work something out then see what happens
--------------- Added [DATE]1268002308[/DATE] at [TIME]1268002308[/TIME] --------------- Okay. I've read the guides but I am at a loss as to exactly what I should be doing here. From my point of view I shouldn't need to register a variable that is already part of the vBulletin core variables. So, maybe my question should be: How do I make the {vb:raw bookmarksites} accessible in the footer template? Where do I have to register this variable for it to be used in the footer? Don't get me wrong - I know how to handle PHP coding and all that but vBulletin's template system is downright confusing. I mean - I can't write raw php in these templates without some long-winded process explained in the guide linked to by Lynne - which hairbrain thought that up?! :down: |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|