Welcome Guest, Not a member yet? Register   Sign In
use of php native functions...broke?
#1

[eluser]fivestringsurf[/eluser]
'CI_VERSION', '1.7.2'Taken straight from the user guide; the below code does not work as expected
php's htmlspecialchars function is not evoked.
:

Code:
$this->load->library('table');

$this->table->set_heading('Name', 'Color', 'Size');
$this->table->add_row('Fred', '<strong>Blue</strong>', 'Small');

$this->table->function = 'htmlspecialchars';
echo $this->table->generate();
#2

[eluser]xatrix[/eluser]
Where exactly in the user guide does it say that there is a table->function?

Just use
Code:
add_row('Fred', htmlspecialchars('<strong>Blue</strong>'), 'Small');
#3

[eluser]fivestringsurf[/eluser]
http://ellislab.com/codeigniter/user-gui...table.html
scroll all the way to the bottom
#4

[eluser]xatrix[/eluser]
[quote author="fivestringsurf" date="1296714504"]'CI_VERSION', '1.7.2'[/quote]

This is a 2.0 feature. I've looked at the 1.7.3 user guide and there's no such thing. So, either upgrade or just use the php function as it is.
#5

[eluser]fivestringsurf[/eluser]
I see...i ran through the "upgrades" list but obviously missed it.
how to upgrade?
Is it as simple as replacing all the files and dirs in the folder "system" with the latest system files?
or will my existing code break somewhere? I'm slightly new to codeigniter and have never lived through an upgrade yet.
Thanks for your feedback.
#6

[eluser]InsiteFX[/eluser]
You will also need to change all your controllers and models!

Code:
Controller is now CI_Controller
and
Model is now CI_Model

InsiteFX
#7

[eluser]fivestringsurf[/eluser]
ok,thanks.




Theme © iAndrew 2016 - Forum software by © MyBB