Welcome Guest, Not a member yet? Register   Sign In
How to call libraries in config file
#3

(04-21-2017, 09:33 PM)JayAdra Wrote: I would just use an English key in the config array, i.e. "profile" and then on the view side of things, call the lang line, e.g.

PHP Code:
foreach($config['menu'] as $key => $value) {
 echo 
$this->lang->line($key);


Thats a good idea and works for my menu names. but i have another arrays which the first item is like
PHP Code:
$config['country'] = array(
    
''                        =>    'Pick a Country'

And im using the array like this
PHP Code:
echo form_dropdown(array(
   
'name'            =>    'country',
   
'placeholder'    =>    $this->lang->line('placeholder_country'),
   ),
   
$country,
   
set_value('country'$get_user->COUNTRY)
   ); 

How can be translate the 'Pick a Country' ?
Reply


Messages In This Thread
How to call libraries in config file - by ardavan - 04-21-2017, 06:53 PM
RE: How to call libraries in config file - by ardavan - 04-22-2017, 02:27 AM



Theme © iAndrew 2016 - Forum software by © MyBB