Welcome Guest, Not a member yet? Register   Sign In
Scaffolding Troubles
#1

[eluser]webdezzo[/eluser]
Hey all,

I am new to CI, and trying to get this puppy working. All is well until I try setting up scaffolding. I have tried the .htaccess implementations, and still am having no luck. It appears that the edit / insert / view functionality is working properly, but I keep getting php notices. I have set directive :

AddHandler application/x-httpd-php5 .php

in my .htaccess file as my host requires, and still nothing.

http://www.undecisive.com/index.php/blog/scaffolding

Thanks in advance!
#2

[eluser]Phil Sturgeon[/eluser]
Erm, Is blog a controller or a subdirectoy?

You cant have scaffolding in a subdirectory unless you implement the code-hack I wrote here
#3

[eluser]webdezzo[/eluser]
Blog was a controller, I recently updated with the bare bones install to make sure I wasn't messing anything up. Here is the new url, same thing happening:

http://www.undecisive.com/welcome/scaffolding/

It's just the default welcome page, with a db setup and scaffolding on it. Everything seems to be working fine, its just throwing alot of php notices?
#4

[eluser]Phil Sturgeon[/eluser]
If it is a controller then you shouldnt be using a method to call it. You are meant to put the scaffolding command into the controllers constructor as shown in the user guide.

Eg:

Code:
<?php
class Blog extends Controller {

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

            $this->load->scaffolding('table_name');
       }
}
?>

Then call is as /blog/scaff_trig.

This is of course very annoying as it does limit your use of the scaffolding, but I preffer to just make one scaffolding file then change the table name around now and then.




Theme © iAndrew 2016 - Forum software by © MyBB