I am using codeigniter and any data that is within the for loop doesn’t have the CSS applied. The file is pointed correctly as all the other css works fine, however I can’t find a solution to this anywhere HTML : CSS (I haven’t included all the css just the parts within the loop as my css file is very
Tag: codeigniter
Codeigniter , PHP – form validation only letter in other language?
In Codeigniter 3 I use alpha to validate form for only letters $this->form_validation->set_rules(‘firstname’, ‘FirstName’, ‘trim|required|alpha’, array(‘required’ => ‘…
CodeIgniter : how to write where_in OR where_in query?
I’m using codeigniter to query a database, and I need to conditionally compare arrays in the where clause. So basically I want to do: where_in OR where_in depending on what array has data in it. So I will have either an array of user_id OR an array of area_id’s. I’m not sure how to combine the where_in comparison. This is
CodeIgniter count too slow – pagination
I’m trying to make a search using CodeIgniter faster. I use the pagination library and I have to count the records returned from the query on a table which contains more than 1.2 million records. The num_rows() function is very slow ( takes approximately 3 seconds ) Any solutions? Answer As the comments from @MonkeyZeus suggests, performance will improve by
How to use PHP function into API Blocks with ConfigureIT
I am creating API’s using the api builder on Configure.It. can anyone explain me how to use the php custom function in the api block. Answer Hello Nitish, Please check below comments. Hope it will helpful for you. In API Configuration we can add php function in following blocks. Php function in these blocks uses for different purpose. Query Block
In Codeigniter what is the purpose of hook ? Why we have to create?
i am new to codeigniter. In Every interview all asked about hooks. i am not getting that what is hook why i have to use it ? what the benefit of it. Answer This is example link for use it hooks in codeigniter https://qasimbadami.wordpress.com/2012/05/18/codeigniter-hooks-tutorial/ Note : suppose you have big project and almost 100 controller , if every time to
How to rewrite url with htaccess?
I have to build up a bank search website. I want to rewrite url like below link bank Please see above link. In this when you select bank and all details the url is also changing. I want to use same url in codeigniter website which is the replica of this site. But all of you knows that codeigniter work
Codeigniter 3 redirection adds index.php to every redirect
this is a function in my controller function is deleting properly my record but it redirects the user to which gives me error 404 my .htaccess is like this: i have set the index_page in config.php Answer Removing the index.php file in Codeigniter By default, the index.php file will be included in your URLs: If your Apache server has mod_rewrite
Codeigniter CSRF valid for only one time ajax request
I want to upload image on the server on change event of jQuery but using codeigniter csrf I am able to upload image only one time. How can I upload images using ajax for multiple requests.Please keep …
In codeigniter i am send a php variable from view page to controller through the tag, but i can’t display value in controller page
this is my view page code this is my controller function Answer Use this $this->input->get()