Questions tagged [codeigniter-2]

CodeIgniter 2.x is an old and no longer supported version of the popular PHP framework. Please refer to the [codeigniter] tag for more information.

Codeigniter 2.x is an old and no longer supported version of the popular PHP framework.

The last 2.x version (2.2.6) was released on October 31st, 2015, which is also the date when security maintenance support for the 2.x version tree was officially ended.

For more up-to-date information on the Codeigniter framework, please refer to the tag.

Links:

3146 questions
0
votes
3 answers

how to do this query with codeigniter?

There is a table contains columns like username,settings1,settings2,settings3 username is a unique and settings1,2,3 is contain 0 or 1 values. $query = $this->db->query("SELECT * FROM tbl_users WHERE username = 'test'"); $queryrow =…
Gihan Lasita
  • 2,955
  • 13
  • 48
  • 65
0
votes
0 answers

The best way to do a MYSQL STRAIGHT_JOIN in the query builder of CodeIgniter [old version 2]

A project uses an older version of the CodeIgniter[2.1.1]. The query builder is used to retrieve specific data. The source code is an example like this: $db ->from('first as A') ->where_in('A.code', $first_values) ->join('second as B',…
Devatim
  • 331
  • 2
  • 10
0
votes
3 answers

Code Igniter 2 - Controller/Method override

If a user is not logged in I would like to override the existing Controller and call the auth/login one instead keeping the browser URI in tact. (Every user has to be logged in to use the site) I have tried a pre controller hook, but its too early.…
Lee
  • 5,816
  • 6
  • 45
  • 61
0
votes
4 answers

Is there an existing CodeIgniter helper/library that uses PHP DateTime class?

Does anyone know of an existing CodeIgniter (CI 2.0) Helper (or Library) that I can use to help with date and time formatting for views? Maybe something that uses the PHP5 DateTime class? Most of our data is in the typical GMT/UTC format within a…
jjwdesign
  • 3,272
  • 8
  • 41
  • 66
0
votes
0 answers

Dompdf set tamil font supported font-family

I have been trying to set tamil font to display in PDF by using dompdf in codeigniter. As followed this instruction Dompdf and set different font-family I have set the font family but this is not working for tamil fonts. I have updated Baamini.ttf…
Vinoth Kumar
  • 489
  • 3
  • 17
  • 45
0
votes
1 answer

insert item into array

I have a result array that comes back from CodeIgniter looking like this: Array ( [ILS] => ils [0] => Array ( [laser_id] => 1 [sort_order] => 1 [laser_name] => ILS12.75 [laser] =>…
sehummel
  • 5,476
  • 24
  • 90
  • 137
0
votes
3 answers

Cannot autoload/crossload libraries

I’m getting error when trying to autoload ion_auth library application/config/autoload.php $autoload['libraries'] = array('database', 'template', 'asset', 'ion_auth/ion_auth'); folder structure: application/ ... modules/ ion_auth/ …
Permana
  • 1,972
  • 2
  • 33
  • 51
0
votes
1 answer

Deploying a framework to a already ready project in PHP

I have a fully ready web app which we developed in php. It s fully procedural as I didn't know I could use OOPS to make things efficient (since was a beginner in PHP). Now i have all the files and my friend introduced CodeIgniter, I want to know how…
anjana
  • 1
  • 1
  • 3
0
votes
1 answer

Doctrine 2 EntityManager causes time loss in first request

Recently I integrated Doctrine 2 ORM into CodeIgniter 2. I configured Doctrine 2 as a library and autoloaded it in CodeIgniter. Within a page I instantiate doctrine entity manager in the following way: private static $em = null; public function…
hdz200
  • 345
  • 1
  • 7
0
votes
1 answer

How do I use response from an API into the controller - CodeIgniter

I tried to integrate an API that built-in laravel and now I have to use that API's response into the Codeigniter project, I'm developing a Codeigniter project(I'm not familiar with this framework and it's my first time working with this), I finally…
Marty
  • 302
  • 4
  • 18
0
votes
1 answer

How I can create a formless file upload using Javascript?

I have the following form: $("#multimedia_upload").on('submit',function(e){ e.preventDefault(); console.log("files submited"); var images = $("#multimedia_upload…
Dimitrios Desyllas
  • 9,082
  • 15
  • 74
  • 164
0
votes
1 answer

Amending the CodeIgniter Active Record Query command?

I am developing a Codeigniter (2.0.2) Application, which will utilise a Master database for all write operations (INSERT/UPDATE/DELETE) and a read replica for all read operations (SELECT). Now I know I can access two different database objects…
TIW
  • 217
  • 4
  • 10
0
votes
1 answer

403 error when moving CodeIgniter app from localhost to QA server

I’ve looked in the forums (both here and on CodeIgniter.com) but haven’t found any answers that help. I have a CI 2.0.2 app that I developed locally in MAMP. It works perfectly. I copied the entire CI install up to our QA server, and am getting 403…
EmmyS
  • 11,892
  • 48
  • 101
  • 156
0
votes
1 answer

Extending CodeIgniter Security.php to enable logging

TLDR; I want to enable database-logging of xss_clean() when replacing evil data. I want to enable database logging of the xss_clean() function in Security.php, basically what I want to do is to know if the input I'm feeding xss_clean() with…
Tobias
  • 491
  • 3
  • 10
0
votes
0 answers

Codeigniter URL routing - naming URL patterns

Currently the Codeigniter routing configuration and site_url only makes it possible to decouple the visible URL from the underlying path to controller. $routing['my/url/'] = "my/controller/path"; However this doesn't help that much when you want to…
Botond Béres
  • 16,057
  • 2
  • 37
  • 50