how to switch HTML alignment(dir)?

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
Aburajeh
User
Posts: 37

how to switch HTML alignment(dir)?

Post by Aburajeh »

Hi,

In My Project tow languages English ( Left alignment ) and Arabic ( Right alignment )

How to switch web alignment from left to right when select Arabic Language

thank you,
Aburajeh


mobhar
User
Posts: 11747

Post by mobhar »

PHPMaker 10 uses Twitter Bootsrap. If you want to make it support for RTL, then google for "twitter bootstrap support rtl".


Aburajeh
User
Posts: 37

Post by Aburajeh »

I am tray

Server Events > Startup Scripts Like as :

// Write your global startup script here
// document.write("page loaded");
<?php if ($gsLanguage == "ar") { // Check your id for Arabic language ?>
ew_Select("html", "*", "this.setAttribute('dir');");
<?php } ?>


Webmaster
User
Posts: 9430

Post by Webmaster »

If v10, changing the dir attribute of the HTML tag only is not sufficient to change the direction. As mobhar wrote:

PHPMaker 10 uses Twitter Bootsrap. If you want to make it support for RTL, then google for "twitter bootstrap support rtl".

Download the *.less files that supports rtl and replace the original Bootstrap *.less files in the installed folder (e.g. C:\Program Files (x86)\PHPMaker 10\themes\bootstrap).


Post Reply