I'm using one script of very good multilanguage in my site.
http://www.bitrepository.com/php-how-to-add-multi-language-support-to-a-website.html
But unfortanly I have a problem:
I need to manipulate the information that is inside of the languages pages (languages/lang.en.php
), to edit from my backoffice instead of going to the languages page and fill from there.
It is possible to make echos from the filing-cabinets languages/lang.en.php
for example?
I tried but no sucess, I liked to communicate the languages pages to my database.
I tried to see if i can echo this part of the code in the language file:
$lang['PAGE_TITLE'] = 'My website page title';
Change to
$lang['PAGE_TITLE'] = ''; But doesnt work, it looks like that just works whit html tags.
if in your php page you have the title set as:
<title><?php echo $lang['PAGE_TITLE']; ?></title>
//change this to
<title><?php echo $lang-pagetitle; ?></title>
//and at the top of the document
$lang-pagetitle = $lang['PAGE_TITLE'];
//and when it needs to be changed, put this above where the title is echoed,
//after where $lang-pagetitle is initially defined:
if(whatever condition) {
$lang-pagetitle = "something else";
}