vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=246)
-   -   Forum Home Enhancements - add banner under longin (https://vborg.vbsupport.ru/showthread.php?t=295975)

bing11 03-10-2013 11:00 PM

add banner under longin
 
1 Attachment(s)
This is my first small mod post here.

hope anybody can teach me more

I find 3 ways finish this Job

My way is very easy no any css add or change.

In the header template find

Code:


    </div>
    <div class="ad_global_header">

before this add
Code:

<ul>
            <li>{vb:raw ad_location.global_header2}</li>
            </ul>

and then just remove
Code:

{vb:raw ad_location.global_header2}
and place the HTML code for the banner in the ad_global_header2 template here
Admin CP -> Styles & Templates -> Style Manager -> Edit Templates -> Ad Location Templates -> ad_global_header2

It is working good in Ie7 Safari fireofax and Chrome . but not look good in Opera (Widescreen)

Hope someone can help me.

other 2 ways

is
https://vborg.vbsupport.ru/showthread.php?t=232325

and

http://www.vbulletin.com/forum/forum...username-info? ( I think it is the best one)


They are both great idea. but look like not fit to IE7

Finally I add a function to this mod learn from 3.8

Show this banner only forumhome

When you edit ad_global_header2 just do this

Code:

<if condition="THIS_SCRIPT == 'index'">your html code </if>
It is very Simple. hope can help you

Attachment 144114

richardevans123 03-11-2013 04:16 PM

Do you have any screenshots?

bing11 03-11-2013 05:35 PM

Quote:

Originally Posted by richardevans123 (Post 2409339)
Do you have any screenshots?

upload

tanzeelniazi 03-12-2013 01:21 AM

Nice Mod Install Working Fine in VB4.2.0
1 Question
I use this method 2 Method
First
Header method and 2nd is this: http://www.vbulletin.com/forum/forum...username-info?

But my Banner is not Full in Right Side Showing Little gape

tanzeelniazi 03-12-2013 01:49 AM

Now i am using this method:
http://www.vbulletin.com/forum/forum...username-info?
But My banner showing in only Main Page why he is not showing in all forum i mean when i click another section banner is not showing

bing11 03-12-2013 03:47 AM

Quote:

Originally Posted by tanzeelniazi (Post 2409414)
Now i am using this method:
http://www.vbulletin.com/forum/forum...username-info?
But My banner showing in only Main Page why he is not showing in all forum i mean when i click another section banner is not showing

don't use this code
Code:

<if condition="THIS_SCRIPT == 'index'">your html code </if>

tanzeelniazi 03-12-2013 01:33 PM

Quote:

Originally Posted by bing11 (Post 2409433)
don't use this code
Code:

<if condition="THIS_SCRIPT == 'index'">your html code </if>

Thanks
Why my banned is not Full Right side
i want my banner Full left side Below Logout

bing11 03-14-2013 04:37 AM

use the first one should work

Naijasite 06-15-2013 10:24 PM

how to make the advert to show on forumdisplay and index only?

bosanci28 07-20-2013 11:46 PM

how to center it in the middle of the page?
thanks

sebaldus 09-11-2013 02:18 PM

Quote:

Originally Posted by bosanci28 (Post 2434636)
how to center it in the middle of the page?
thanks

I used the code with success on my first Gfx-artist.com - 4.1.x forums.

Secound after upgrade to 4.2.x I have had problems with this code.

Code:

<if condition="THIS_SCRIPT == 'index'"><center>your html code </center></if>
Used this and the site was fantastic with https://vborg.vbsupport.ru/external/...1.jpg~original

Also had the flying twitter bird and it was great. But now, the bird are gone and not possible to get back flying. Either will the banner be installed as it shall..

Anyone?

The first time I use it, it was fantastic. But secound time I tryed to use it, it only give error msg in tags and thats it..

Can anyone help me out?
Are using same banner in my old myBB forums at: http://www.gfx-artist.com/forum/ but it was more fantastic in the first vBulletin forums as I tested it.

Its there again, but with error msg: Warning: Invalid argument supplied for foreach() in [path]/includes/functions.php on line 3822

vBulletin Message
The following error occurred when attempting to evaluate this template:
PHP Code:

%1$s
This is likely caused by a malformed conditional statement
It is highly recommended that you fix this error before continuingbut you may continue as-is if you wish

And it shows up on :articles - whats new - forums and blogs.

My entire headder code now:
Code:

<div class="above_body"> <!-- closing tag is in template navbar -->
<div id="header" class="floatcontainer doc_header">
        <vb:if condition="$stylevar['titleimage']"><div><a name="top" href="{vb:link forumhome}" class="logo-image"><img src="{vb:stylevar titleimage}" alt="{vb:rawphrase x_powered_by_vbulletin, {vb:raw vboptions.bbtitle}}" /></a></div></vb:if>
        <div id="toplinks" class="toplinks">
                <vb:if condition="$show['member']">
                        <ul class="isuser">
                                <li><a href="login.php?{vb:raw session.sessionurl}do=logout&amp;logouthash={vb:raw bbuserinfo.logouthash}" onclick="return log_out('{vb:rawphrase sure_you_want_to_log_out}')">{vb:rawphrase log_out}</a></li>
                                <vb:if condition="$show['registerbutton']">
                                <li><a href="register.php{vb:raw session.sessionurl_q}" rel="nofollow">{vb:rawphrase register}</a></li>
                                </vb:if>
                                <li><a href="usercp.php{vb:raw session.sessionurl_q}">{vb:rawphrase user_control_panel}</a></li>
                                <li><a href="{vb:link member, {vb:raw bbuserinfo}}">{vb:rawphrase your_profile}</a></li>
                                <vb:if condition="$notifications_total">
                                <li class="popupmenu notifications" id="notifications">
                                        <a class="popupctrl" href="usercp.php{vb:raw session.sessionurl_q}">{vb:rawphrase your_notifications}: <span class="notifications-number"><strong>{vb:raw notifications_total}</strong></span></a>
                                        <ul class="popupbody popuphover">
                                                {vb:raw notifications_menubits}
                                        </ul>
                                </li>
                                <vb:else />
                                <li class="popupmenu nonotifications" id="nonotifications">
                                        <a class="popupctrl" href="usercp.php{vb:raw session.sessionurl_q}">{vb:rawphrase your_notifications}</a>
                                        <ul class="popupbody popuphover">
                                                <li>{vb:rawphrase no_new_messages}</li>
                                                <vb:if condition="$show['pmmainlink']"><li><a href="private.php{vb:raw session.sessionurl_q}">{vb:rawphrase inbox}</a></li></vb:if>
                                        </ul>
                                </li>
                                </vb:if>
                                <li class="welcomelink">{vb:rawphrase welcome_x_link_y, {vb:raw bbuserinfo.username}, {vb:link member, {vb:raw bbuserinfo}}}</li>
                                <vb:if condition="$vboptions['enablefacebookconnect']">
                                        {vb:raw facebook_header}
                                </vb:if>
                        </ul>
            {vb:raw template_hook.header_userinfo}
                        <vb:comment><p>{vb:rawphrase last_visited_x_at_y, {vb:raw pmbox.lastvisitdate}, {vb:raw pmbox.lastvisittime}}</p></vb:comment>
                <vb:else />
                        <ul class="nouser">
                        <vb:if condition="$show['registerbutton']">
                                <li><a href="register.php{vb:raw session.sessionurl_q}" rel="nofollow">{vb:rawphrase register}</a></li>
                        </vb:if>
                                <li><a rel="help" href="faq.php{vb:raw session.sessionurl_q}">{vb:rawphrase help}</a></li>
                                <li>
                        <script type="text/javascript" src="clientscript/vbulletin_md5.js?v={vb:raw vboptions.simpleversion}"></script>
                        <form id="navbar_loginform" action="login.php?{vb:raw session.sessionurl}do=login" method="post" onsubmit="md5hash(vb_login_password, vb_login_md5password, vb_login_md5password_utf, {vb:raw show.nopasswordempty})">
                                <fieldset id="logindetails" class="logindetails">
                                        <div>
                                                <div>
                                        <input type="text" class="textbox<vb:if condition="!$username"> default-value</vb:if>" name="vb_login_username" id="navbar_username" size="10" accesskey="u" tabindex="101" value="<vb:if condition="$username">{vb:raw username}<vb:else />{vb:rawphrase username}</vb:if>" />
                                        <input type="password" class="textbox" tabindex="102" name="vb_login_password" id="navbar_password" size="10" />
                                        <input type="text" class="textbox default-value" tabindex="102" name="vb_login_password_hint" id="navbar_password_hint" size="10" value="{vb:rawphrase password}" style="display:none;" />
                                        <input type="submit" class="loginbutton" tabindex="104" value="{vb:rawphrase log_in}" title="{vb:rawphrase enter_username_to_login_or_register}" accesskey="s" />
                                                </div>
                                        </div>
                                </fieldset>
                                <div id="remember" class="remember">
                                        <label for="cb_cookieuser_navbar"><input type="checkbox" name="cookieuser" value="1" id="cb_cookieuser_navbar" class="cb_cookieuser_navbar" accesskey="c" tabindex="103" /> {vb:rawphrase remember_me}</label>
                                </div>

                                <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="login" />
                                <input type="hidden" name="vb_login_md5password" />
                                <input type="hidden" name="vb_login_md5password_utf" />
                        </form>
                        <script type="text/javascript">
                        YAHOO.util.Dom.setStyle('navbar_password_hint', "display", "inline");
                        YAHOO.util.Dom.setStyle('navbar_password', "display", "none");
                        vB_XHTML_Ready.subscribe(function()
                        {
                        //
                                YAHOO.util.Event.on('navbar_username', "focus", navbar_username_focus);
                                YAHOO.util.Event.on('navbar_username', "blur", navbar_username_blur);
                                YAHOO.util.Event.on('navbar_password_hint', "focus", navbar_password_hint);
                                YAHOO.util.Event.on('navbar_password', "blur", navbar_password);
                        });
                       
                        function navbar_username_focus(e)
                        {
                        //
                                var textbox = YAHOO.util.Event.getTarget(e);
                                if (textbox.value == '<vb:if condition="$username">{vb:raw username}<vb:else />{vb:rawphrase username}</vb:if>')
                                {
                                //
                                        textbox.value='';
                                        textbox.style.color='{vb:stylevar input_color}';
                                }
                        }

                        function navbar_username_blur(e)
                        {
                        //
                                var textbox = YAHOO.util.Event.getTarget(e);
                                if (textbox.value == '')
                                {
                                //
                                        textbox.value='<vb:if condition="$username">{vb:raw username}<vb:else />{vb:rawphrase username}</vb:if>';
                                        textbox.style.color='{vb:stylevar shade_color}';
                                }
                        }
                       
                        function navbar_password_hint(e)
                        {
                        //
                                var textbox = YAHOO.util.Event.getTarget(e);
                               
                                YAHOO.util.Dom.setStyle('navbar_password_hint', "display", "none");
                                YAHOO.util.Dom.setStyle('navbar_password', "display", "inline");
                                YAHOO.util.Dom.get('navbar_password').focus();
                        }

                        function navbar_password(e)
                        {
                        //
                                var textbox = YAHOO.util.Event.getTarget(e);
                               
                                if (textbox.value == '')
                                {
                                        YAHOO.util.Dom.setStyle('navbar_password_hint', "display", "inline");
                                        YAHOO.util.Dom.setStyle('navbar_password', "display", "none");
                                }
                        }
                        </script>
                                </li>
                                <vb:if condition="$vboptions['enablefacebookconnect']">
                                        {vb:raw facebook_header}
                                </vb:if>
                        </ul>
                </vb:if>
        <ul>
            <li>{vb:raw ad_location.global_header2}</li>
            </ul></div>
        <div class="ad_global_header">
                {vb:raw ad_location.global_header1}
                <if condition="THIS_SCRIPT == 'index'"><center><a href="http://s242.photobucket.com/user/sebaldus_2007/media/GFX-DEPO/bannergfx6.png.html" target="_blank"><img src="http://i242.photobucket.com/albums/ff216/sebaldus_2007/GFX-DEPO/bannergfx6.png~original" border="0" alt=" photo bannergfx6.png"/></a></center> </if>
        </div>
        <hr />
</div>

Thanks.
Regards from sebaldus


All times are GMT. The time now is 04:09 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02205 seconds
  • Memory Usage 1,828KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (8)bbcode_code_printable
  • (1)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (11)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete