vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Style and Graphics Requests (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=226)
-   -   how to change direction (https://vborg.vbsupport.ru/showthread.php?t=256617)

NNJJ 01-06-2011 08:51 AM

how to change direction
 
hi

how i can change the style direction to be from right to left?

BirdOPrey5 01-06-2011 12:50 PM

True "Right to Left" is controlled by the language chosen... if it's an RTL (right-to-left) language like Arabic then the forum will automatically change to RTL format.

To override this for a language like English you can make a new plugin on the global_start hook with the code:
Code:

$stylevar[textdirection] = "rtl";
Set active to YES and SAVE.

If you just want say the username/avatar on the right side of the postbit instead of the left side you would have to manually edit your templates- in this case the postbit_legacy template.

--------------- Added [DATE]1294327822[/DATE] at [TIME]1294327822[/TIME] ---------------

After further inspection the plugin above only works in VB 3.x, it doesn't work in VB 4.x and I tried many other hooks besides global_start.

For VB4 Go to Admin CP -> Language Manager -> Edit Settings for your language and choose text direction "Right to Left" instead of "Left to Right" - you could probably do this for VB3 too without a plugin.

TheLastSuperman 01-11-2011 12:49 AM

And in a conditional let's say for vB4 you can use for example:

Code:

<div style="float:<vb:if condition="$stylevar['textdirection'] == 'rtl'">right<vb:else
/>left</vb:if>;"> Code Code code etc etc </div>



All times are GMT. The time now is 01:55 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.02859 seconds
  • Memory Usage 1,709KB
  • 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
  • (2)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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