Changeset 1339202
- Timestamp:
- 01/29/2016 07:29:02 PM (10 years ago)
- File:
-
- 1 edited
-
multi-language-site-basis/trunk/index.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
multi-language-site-basis/trunk/index.php
r1336334 r1339202 435 435 $final='_____'.$variable.'_____'; 436 436 $res = $wpdb->get_results("SELECT * from `".Table1__MLSS."` WHERE `title_indx`= '$variable' AND `lang` = '".$x."'"); 437 if(!empty($res)){ 438 $got_word = $res[0]->translation; 439 if (!empty($got_word)) {$final=stripslashes($res[0]->translation); } 440 else{ 441 if(!empty($desired)){ 442 foreach($desired as $eachLang=>$eachValue){ 443 UPDATEE_OR_INSERTTT__MLSS(Table1__MLSS, 444 array('translation'=>$eachValue), 445 array('title_indx'=>$variable, 'lang'=> $eachLang) ); 446 } 447 $final=$desired[$lang]; 448 } 449 } 437 if(!empty($res)) { $got_word = $res[0]->translation; } 438 439 if(!empty($got_word)) {$final=stripslashes($got_word); } 440 else{ 441 if(!empty($desired)){ 442 foreach($desired as $eachLang=>$eachValue){ 443 UPDATEE_OR_INSERTTT__MLSS(Table1__MLSS, 444 array('translation'=>$eachValue), 445 array('title_indx'=>$variable, 'lang'=> $eachLang) ); 446 } 447 $final=$desired[$lang]; 448 } 450 449 } 451 450 return $final ;
Note: See TracChangeset
for help on using the changeset viewer.