php

PHP is a widely used, high-level, dynamic, object-oriented and interpreted scripting language primarily designed for server-side web development.

58 votes
5 answers
2.1K views
Codeigniter - no input file specified

I am a beginner in Codeigniter and I saw a CI tutorial and was just trying to do a simple thing. I downloaded

avatar
Georgie
0 1 0 9
asked 07 September, 2021
59 votes
6 answers
2.5K views
explain $CI =& get_instance();

Looking through codeigniter's source code, in its helper functions I keep seeing code $CI =& get_ins

avatar
Nereida
0 1 0 9
asked 07 September, 2021
64 votes
5 answers
1.6K views
How to do error logging in CodeIgniter (PHP)

I want error logging in PHP CodeIgniter. How do I enable error logging? I have some questions: What are al

avatar
Don
0 1 0 9
asked 07 September, 2021
50 votes
11 answers
2.3K views
CodeIgniter - accessing $config variable in view

Pretty often I need to access $config variables in views. I know I can pass them from controller to load->v

avatar
Nereida
0 1 0 9
asked 07 September, 2021
57 votes
9 answers
2.5K views
PHP_SELF vs PATH_INFO vs SCRIPT_NAME vs REQUEST_URI

I am building a PHP application in CodeIgniter. CodeIgniter sends all requests to the main controller: index.p

avatar
Nidia
0 1 0 9
asked 07 September, 2021
58 votes
15 answers
851 views
How to print SQL statement in codeigniter model

I have a sql statement in my model, I then say $query = $this->db->query($sql, array(fields, fields1);

avatar
Leonardo
0 1 0 9
asked 07 September, 2021
61 votes
27 answers
844 views
How to remove "index.php" in codeigniter's path

How do I remove the "index.php" sticking out in every path in codeigniter somewhere in the center? I want clea

avatar
Hildegard
0 1 0 9
asked 07 September, 2021
61 votes
11 answers
2.1K views
CodeIgniter: How to get Controller, Action, URL information

I have these URLs: http://backend.domain.com/system/setting/edit/12 http://backend.domain.com/product/edit/1

avatar
Gigi
0 1 0 9
asked 07 September, 2021
52 votes
13 answers
2.1K views
How to insert multiple rows from array using CodeIgniter framework?

I'm passing a large dataset into a MySQL table via PHP using insert commands and I'm wondering if it

avatar
Jefferey
0 1 0 9
asked 07 September, 2021
51 votes
11 answers
2K views
CodeIgniter activerecord, retrieve last insert id?

Are there any options to get the last insert id of a new record in CodeIgniter? $last_id = $this->db->i

avatar
Vi
0 1 0 9
asked 07 September, 2021
67 votes
30 answers
1.2K views
CodeIgniter removing index.php from url

My current urls look like this [mysite]index.php/[rest of the slug]. I want to strip index.php from these urls

avatar
Jeff
0 1 0 9
asked 07 September, 2021
70 votes
3 answers
1.1K views
Only variable references should be returned by reference - Codeigniter

After the server PHP upgrade I am getting the following error with PHP Version 5.6.2 on Apache 2.0 A PHP Erro

avatar
Wei
0 1 0 9
asked 07 September, 2021
61 votes
7 answers
1.8K views
CodeIgniter: Create new helper?

I need to loop lot of arrays in different ways and display it in a page. The arrays are generated by a module

avatar
Omar
0 1 0 9
asked 07 September, 2021
63 votes
7 answers
2.4K views
Which version of CodeIgniter am I currently using?

Quick question. Is there something similar to a phpinfo() - that would display the version for CodeIgniter?

avatar
Forrest
0 1 0 9
asked 07 September, 2021
54 votes
30 answers
2.4K views
Fatal Error: Allowed Memory Size of 134217728 Bytes Exhausted (CodeIgniter + XML-RPC)

I have a bunch of client point of sale (POS) systems that periodically send new sales data to one centralized

avatar
Dwain
0 1 0 9
asked 07 September, 2021
58 votes
29 answers
2.8K views
How do I get a file extension in PHP?

This is a question you can read everywhere on the web with various answers: $ext = end(explode('.',

avatar
Gigi
0 1 0 9
asked 07 September, 2021
60 votes
17 answers
2.3K views
How do I implement basic "Long Polling"?

I can find lots of information on how Long Polling works (For example, this, and this), but no simple examples

avatar
Renaldo
0 1 0 9
asked 07 September, 2021
63 votes
23 answers
2.8K views
Get first key in a (possibly) associative array?

What's the best way to determine the first key in a possibly associative array? My first thought it to ju

avatar
Thurman
0 1 0 9
asked 07 September, 2021
67 votes
30 answers
2K views
How do I convert a string to a number in PHP?

I want to convert these types of values, '3', '2.34', '0.234343', etc. to a numb

avatar
Corrin
0 1 0 9
asked 07 September, 2021
55 votes
11 answers
1.3K views