New user, having a couple of issues |
[eluser]darkpedro[/eluser]
Hi there. I'm a new user to both PHP and CI. I've gone through the tutorials and a couple of other CI tutorials that I've found. So, I get stuck on all the forms tutorial for the dumbest reason. For some reason I cannot get a submit button to work. I get everything to display, I can fill things in, but when I click submit, nothing happens. I'm using Code: <php echo form_open('form/submit'); ?> Code: <?php echo form_submit('submit', 'Submit'); ?> Code: <?php echo form_close(); ?> Does anyone have any suggestions? Is learning CI alongside of PHP even a good idea? Thanks for your help. edit: I've also autoloaded the 'url' and 'form' helpers.
[eluser]Michael Wales[/eluser]
Code: <php echo form_open('form/submit'); ?> Should be: Code: <?php echo form_open('form/submit'); ?> Note the <?php. That's the only thing I see - everything else looks good. If this doesn't fix it, mind pasting your entire method for us to view?
[eluser]darkpedro[/eluser]
Oops. Didn't see that. It didn't work though. I've got a slightly modified version of the godbit tutorial, listed below. I've had the same problem on your drunk tutorial (nice one btw). Code: <?php And Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> I appreciate your help.
[eluser]lszanto[/eluser]
Just a suggestion, try taking the form and url helpers out of the autoload and just loading them in the regform class. I can't think of anything else to suggest sorry.
[eluser]darkpedro[/eluser]
Hmm. It appears that I may have mis-spoke. I do have action now. It may have taken a refresh after I added the ? to the <?php. Thanks for your help guys.
[eluser]darkpedro[/eluser]
[quote author="lszanto" date="1192980783"]Just a suggestion, try taking the form and url helpers out of the autoload and just loading them in the regform class. I can't think of anything else to suggest sorry.[/quote] That looks to fix the issue. Anything you guys know of that I need to do to autoload the autoload?
[eluser]Michael Wales[/eluser]
Your autoload should work fine. Try adding those helpers back in (I do it all the time, as can be seen in my tuts) and try again. Note: When you reload you app - always, always use Ctrl+F5. This ensures your browsing isn't caching anything and you are pulling down the page from the server. Also, if you have caching enabled within CI, turn it off until you are done working on your app.
[eluser]darkpedro[/eluser]
wow, I'm having some real issues. When I try to load those back in, the 'form' helper seems to break the whole damn thing. I keep getting the Code: Fatal error: ob_start() [<a href='ref.outcontrol'>ref.outcontrol</a>]: Cannot use output buffering in output buffering display handlers in C:\wamp\www\system\libraries\Exceptions.php on line 160 The learning curve on php + CI seems pretty steep. Does it level off fairly quickly?
|
Welcome Guest, Not a member yet? Register Sign In |