views:

272

answers:

2

I am new in Codeigniter i am seeing the Video blog tutorials from Codeigniter but when i am useing scaffolding and try to add something give me like this massage.

<?php
class Blog extends Controller {

   function Blog()
  {
    parent::Controller();

    $this->load->scaffolding('entries');
}

function index()
{
    $data['title'] = "This is my title of the page";
    $data['heading'] = "This is my heading of page";
    $data['todo'] = array("First Name: waliullah", "Last Name: Masud", "Full Name: Waliullah Masud");

    $this->load->view('blog_view', $data);
}

}

?>

A: 

There is no good answer to this question. Scaffolding is old, crappy and deprecated and should not be used in an application. It just generally should not be used!

People coming from Rails often see Scaffolding and get a "nerd-on" over it, but to be honest it is just a temporary developer tool for those who do not have a MySQL client.

Scaffolding has been deprecated for a long time and as of CodeIgniter 2.0 it will not exist at all. Therefore even if you got it working, your application would be fundamentally doomed.

Best to try something else!

Phil Sturgeon
A: 

Phil is right, and as I recall from the documentation, they even state that its a development tool only and is NOT meant for real-world implementation on your site. Its just a half-hearted attempt to stick data into your db while developing - you'd be better off spending time with the database class http://codeigniter.com/user_guide/database/index.html and learning how to do what you need!

eddt