Important: This page is using cookies (cookies). Using this website without turning off cookies in browser, means that you agree for using it.
Buy Now! Features Downloads

Earn with us!

If you would like to start earning money with vBET join to Affiliate Program.
Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 21

Thread: Translations dropdown in cms/blogs

  1. #11
    Junior Member
    Join Date
    Apr 2010
    Posts
    15

    Default

    Quote Originally Posted by vBET View Post
    In described solution you need to have set custom place for flags!

    To have it working in all configurations just do replace this:
    PHP Code:
    if ('cu' != $vbulletin->options['vbenterprisetranslator_translationsDropdownMenu_position']) {
    $template_hook[$vbulletin->options['vbenterprisetranslator_translationsDropdownMenu_position']] .= $vbenterprisetranslatorflagsdropdown;
    } else {
    vB_Template::preRegister('navbar', array('vbenterprisetranslatorflagsdropdown' => $vbenterprisetranslatorflagsdropdown));

    To this:
    PHP Code:
    if ('cu' != $vbulletin->options['vbenterprisetranslator_translationsDropdownMenu_position']) {
    $template_hook[$vbulletin->options['vbenterprisetranslator_translationsDropdownMenu_position']] .= $vbenterprisetranslatorflagsdropdown;
    } else {
    vB_Template::preRegister('navbar', array('vbenterprisetranslatorflagsdropdown' => $vbenterprisetranslatorflagsdropdown));
    }         
    vB_Template::preRegister('vbcms_navbar_link', array('vbenterprisetranslatorflagsdropdown' => $vbenterprisetranslatorflagsdropdown));  
    vB_Template::preRegister('blog_navbar_link', array('vbenterprisetranslatorflagsdropdown' => $vbenterprisetranslatorflagsdropdown)); 
    So in other words - put your 2 additional lines just 1 line lower (after "}").

    Also I see that in template you put {vb:raw vbenterprisetranslatorflagsdropdown} inside of if clause - put it 1 line lower. It will give you:
    Code:
    *******************************************
    <vb:if condition="$vboptions['selectednavtab'] == 'vbblog'">
    <li class="selected">
    	<a class="navtab" href="blog.php{vb:raw session.sessionurl_q}">{vb:rawphrase blogs}</a>
    	<ul class="floatcontainer">
    		{vb:raw template_hook.blog_navbar_start}
    		<vb:if condition="$show['canpostitems']">
    			<li><a href="{vb:link blog, {vb:raw bbuserinfo}, null, 'userid', 'blog_title'}">{vb:rawphrase your_blog}</a></li>
    		</vb:if>
    		{vb:raw template_hook.blog_navbar_after_your_blog}
    		<li><a href="blog.php?{vb:raw session.sessionurl}do=list">{vb:rawphrase recent_entries}</a></li>
    		{vb:raw template_hook.blog_navbar_after_recent_entries}
    		<li><a href="blog.php?{vb:raw session.sessionurl}do=list&amp;blogtype=best">{vb:rawphrase best_blog_entries}</a></li>
    		{vb:raw template_hook.blog_navbar_after_best_entries}
    		<li><a href="blog.php?{vb:raw session.sessionurl}do=bloglist">{vb:rawphrase blog_list}</a></li>
    		{vb:raw template_hook.blog_navbar_after_blog_list}
    		<vb:if condition="$show['canpostitems']">
    			<li><a href="blog_usercp.php?{vb:raw session.sessionurl}do=editprofile">{vb:rawphrase blog_options}</a></li>
    		</vb:if>
    {vb:raw vbenterprisetranslatorflagsdropdown}
    		{vb:raw template_hook.blog_navbar_end}
    	</ul>
    </li>
    <vb:else />
    	<li><a class="navtab" href="blog.php{vb:raw session.sessionurl_q}">{vb:rawphrase blogs}</a></li>
    </vb:if>
    ***********************************************
    its sure below if code may be while copying here i missed it

  2. #12
    Michał Podbielski (vBET Staff) vBET's Avatar
    Join Date
    Oct 2009
    Posts
    3,037

    Default

    Quote Originally Posted by anand View Post
    its sure below if code may be while copying here i missed it
    So there is an issue with blank page or given code is working?

  3. #13
    Junior Member
    Join Date
    Apr 2010
    Posts
    15

    Default

    given code is not working hope you have tested on vb 4.0.3 if not i will give you access to our webserver/vb

    Quote Originally Posted by vBET View Post
    So there is an issue with blank page or given code is working?

  4. #14
    Junior Member
    Join Date
    Apr 2010
    Posts
    15

    Default

    still waiting for your replies??

  5. #15
    Michał Podbielski (vBET Staff) vBET's Avatar
    Join Date
    Oct 2009
    Posts
    3,037

    Default

    Quote Originally Posted by anand View Post
    still waiting for your replies??
    Sorry - had to accidentally miss his message. Please PM access and I will check and correct it on place.

  6. #16
    Michał Podbielski (vBET Staff) vBET's Avatar
    Join Date
    Oct 2009
    Posts
    3,037

    Default

    Done. Please note that give instructions are correct - you didn't made changes for hook file

  7. #17
    Junior Member
    Join Date
    Apr 2010
    Posts
    15

    Default

    Quote Originally Posted by vBET View Post
    Done. Please note that give instructions are correct - you didn't made changes for hook file
    Thanks for the fix

    Yes i added the code in the hooks but removed later since it gave me white blank pages & also note translation icon comes end of the navbar in blog/cms we want at start of navbar???


    Also you can test yourself the navbar end problem yourself now since you have login & passwords with you

    Thanks
    Anand

  8. #18
    Michał Podbielski (vBET Staff) vBET's Avatar
    Join Date
    Oct 2009
    Posts
    3,037

    Default

    Quote Originally Posted by anand View Post
    Thanks for the fix

    Yes i added the code in the hooks but removed later since it gave me white blank pages & also note translation icon comes end of the navbar in blog/cms we want at start of navbar???


    Also you can test yourself the navbar end problem yourself now since you have login & passwords with you

    Thanks
    Anand
    To have it at the beginning just edit appropriate template and change place of vBET variable for drop-down menu.

    I wrote you in PM that navbar end issue is caused by some other mod which duplicates whole content of $template_hook['navbar_end']. Please note that we are responsible only for our code and here it is not vBET bug. Please ask about solution author of mod which causes the issue. You can find guilty one by temporally disabling other mods one by one. Also you can just set custom place and add flags manually at the end of navbar.

  9. #19
    Michał Podbielski (vBET Staff) vBET's Avatar
    Join Date
    Oct 2009
    Posts
    3,037

    Default

    Added configuration options for drop down menu in CMS and BLOG navbar - will be included in 4.2.2

  10. #20

    Default

    Text automatically translated from: Portuguese to: English
    Translated text
    You can also include the "navbar" in MediaWiki?
    Original text

Page 2 of 3 FirstFirst 123 LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •