PDA

View Full Version : Solved custom flag placement



StarBuG
31-03-10, 10:43
Hi

I want to add the flags to my navbar template at this position:
http://www.patientenfragen.net/images/screenshots/screen_vbet.png

But whatever I do it does not work.
Either it totally breaks the layout if I add it as list element into the navbar template
<li>{vb:raw vbenterprisetranslatorflags}</li>

and if I wrap it into a div and position it via CSS (like on the screenshot), the flags are not clickable on firefox (but on IE8 they are)


.vbetflags_position {
position: absolute;
right:200px;
top: 25px;
}

<div id="flaggen" class="vbetflags_position">
{vb:raw vbenterprisetranslatorflags}
</div>


Please help

StarBuG

vBET
31-03-10, 14:36
You can use dropdown menu if you want - vBET has build in support for adding it into navbar.

If you want to place in navbar normal flags please modify template: vbenterprisetranslator_flags
Please try this one (not tested):


<!--vBET_SNTA--><!--vBET_NRE-->
<vb:each from="flags" value="flag">
<li><a rel="novbseo" href="{vb:var flag.url}" <vb:if condition="$flag['code']==$vbulletin->options['vbenterprisetranslator_forumlanguage']">onclick="document.cookie = 'vbet_language=; expires=Thu, 01-Jan-1970 00:00:01 GMT; path=/'; return true;"</vb:if>><img src="images/vbet/flags/{vb:var flag.code}.gif" alt="{vb:var flag.name}" <vb:if condition="$vbulletin->options['vbenterprisetranslator_flags_noborder'] && !$flag['highlight']">border="0"</vb:if><vb:if condition="$flag['highlight']">style="border-style: solid; border-width: 1px; border-color: yellow;"</vb:if>/></a></li>
</vb:each>
<!--vBET_ENTA-->


Please let us know did it help :)

StarBuG
01-04-10, 11:45
Your code puts the flags above each other and they are still not clickable.
I don't want a drop down because it will be missed by the users.
With flags directly visible it is easier to find for users.

vBET
01-04-10, 12:02
Just tested this code and it is OK. Please make sure that you added flags in appropriate place. In case of future problems please send HTML output for those broken flags.

StarBuG
01-04-10, 12:44
Ahh ok,

I tried it with the DIV container and that did't work.
Now with the <li> Version it works.

Thank you

Juice
17-11-10, 18:11
You can use dropdown menu if you want - vBET has build in support for adding it into navbar.

If you want to place in navbar normal flags please modify template: vbenterprisetranslator_flags
Please try this one (not tested):


<!--vBET_SNTA--><!--vBET_NRE-->
<vb:each from="flags" value="flag">
<li><a rel="novbseo" href="{vb:var flag.url}" <vb:if condition="$flag['code']==$vbulletin->options['vbenterprisetranslator_forumlanguage']">onclick="document.cookie = 'vbet_language=; expires=Thu, 01-Jan-1970 00:00:01 GMT; path=/'; return true;"</vb:if>><img src="images/vbet/flags/{vb:var flag.code}.gif" alt="{vb:var flag.name}" <vb:if condition="$vbulletin->options['vbenterprisetranslator_flags_noborder'] && !$flag['highlight']">border="0"</vb:if><vb:if condition="$flag['highlight']">style="border-style: solid; border-width: 1px; border-color: yellow;"</vb:if>/></a></li>
</vb:each>
<!--vBET_ENTA-->


Please let us know did it help :)

Hi there,

in vBulletin 4.0.8 I´ve changed the template vbenterprisetranslator_flags from


<!--vBET_SNTA--><!--vBET_NRE-->
<div class="vbetflagsbox">
<vb:each from="flags" value="flag">
<a rel="novbseo" href="{vb:var flag.url}" <vb:if condition="$flag['code']==$vbulletin->options['vbenterprisetranslator_forumlanguage']">onclick="document.cookie = 'vbet_language=; expires=Thu, 01-Jan-1970 00:00:01 GMT; path=/'; return true;"</vb:if>><img class="vbet-flag vbet-{vb:raw flag.code}" width="16" height="11" src="images/vbet/flags/clear.gif" alt="{vb:var flag.name}" <vb:if condition="$vbulletin->options['vbenterprisetranslator_flags_noborder'] && !$flag['highlight']">border="0"</vb:if><vb:if condition="$flag['highlight']">style="border-style: solid; border-width: 1px; border-color: yellow;"</vb:if>/></a>
</vb:each>
</div><!--vBET_ENTA-->

to your modificated one



<!--vBET_SNTA--><!--vBET_NRE-->
<vb:each from="flags" value="flag">
<li><a rel="novbseo" href="{vb:var flag.url}" <vb:if condition="$flag['code']==$vbulletin->options['vbenterprisetranslator_forumlanguage']">onclick="document.cookie = 'vbet_language=; expires=Thu, 01-Jan-1970 00:00:01 GMT; path=/'; return true;"</vb:if>><img src="images/vbet/flags/{vb:var flag.code}.gif" alt="{vb:var flag.name}" <vb:if condition="$vbulletin->options['vbenterprisetranslator_flags_noborder'] && !$flag['highlight']">border="0"</vb:if><vb:if condition="$flag['highlight']">style="border-style: solid; border-width: 1px; border-color: yellow;"</vb:if>/></a></li>
</vb:each>
<!--vBET_ENTA-->


but the flags won´t do what they are supposed to. A turn and burn. Can anyone gimme a helping hand on this ?

mateuszr
18-11-10, 10:30
Could you open a new thread with your issue?
Additionaly, specify, in which place you want to have these flags.

AfrikaansAlbanianArabicBelarusianBulgarianCatalanChineseCroatianCzechDanishDutchEnglishEstonianFilipinoFinnishFrenchGalicianGermanGreekHaitian CreoleHebrewHindiHungarianIcelandicIndonesianIrishItalianJapaneseKoreanLatvianLithuanianMacedonianMalayMalteseNorwegianPersianPolishPortugueseRomanianRussianSerbianSlovakSlovenianSpanishSwahiliSwedishTaiwaneseThaiTurkishUkrainianVietnameseWelshYiddish
Translated to other languages thanks to vB Enterprise Translator 4.10.1