Hi all ,
I am using grocery crud with CI and every thing is well.
I have more than one controller and they all use the same crud view with different $output
my crud view looks like:
<?php foreach ($css_files as $file): ?>
<link type="text/css" rel="stylesheet" href="<?php echo $file; ?>" />
<?php endforeach; ?>
<?php foreach ($js_files as $file): ?>
<script src="<?php echo $file; ?>"></script>
<?php endforeach; ?>
<div class="headings">
<h1><?php echo ucfirst(str_replace("_", " ", $current)); ?></h1>
</div>
<br/>
<div>
<?php echo $output; ?>
</div>
and my controllers look like:
function __construct() {
parent::__construct();
$this->load->database();
$this->load->helper('url');
$this->load->library('grocery_CRUD');
$this->load->library('validator');
$this->load->library('form_validation');
$this->lang->load('folders', 'arabic');/*lol*/
$this->lang->load('common', 'arabic');/*lol*/
}
public function index() {
$crud = new grocery_CRUD();
if (isset($this->session->userdata["gui_lang"]))
$crud->set_language($this->session->userdata("gui_lang"));
else
$crud->set_language("arabic");
$crud->set_table('message');
$crud->set_subject('Draft');
$crud->columns(.....);
$crud->where(....);
$crud->display_as('...', $this->lang->line('...'))
$output = $crud->render();
$this->load->view('header');
$this->load->view('sidebar');
$this->load->view('crud', $output);
$this->load->view('footer');
}
I want to convert layout to RTL, I download file from /topic/141-right-to-left-theme-for-rtl-languages/
and use it, the style damaged after I load language file !!!
Important Note: when I omit lines /*lol*/ in the construct (omit loading language files) the damage resloved! but no language then.
pleace any help...
thanks in advance
