Welcome To Snipplr


Everyone's Recent PHP Snippets Tagged cakephp



Save the source provided to /app/view/helpers/timezone_select.php To use the below helper, just put this code into your view: echo $timezoneSelect->select('timezone', 'Please select your timezone', 'Europe/London'); Also, don't forget to...
1 1437 posted 15 years ago by richt
2 1371 posted 15 years ago by kwanhon
this is all the actions needed for auth and the users login/register system
0 1039 posted 15 years ago by sevennbsp
this is the entire app_controller code with auth setup and use in it.
0 1032 posted 15 years ago by sevennbsp
Another common use of Auth component variables is to allow access to certain methods without the user being logged in (by default Auth restricts access to every action except the login and logout methods).
0 1322 posted 15 years ago by TioSolid
1 1394 posted 15 years ago by gerhardsletten
This works fine, except that it repeats a lot of code
0 1001 posted 16 years ago by squarepegsys
0 1273 posted 16 years ago by jpsirois
1 1571 posted 16 years ago by jpsirois
3 1803 posted 16 years ago by jpsirois
0 1140 posted 16 years ago by benjaminpearson
2 1527 posted 16 years ago by sveggiani
[Google's "AJAX Libraries API"](http://code.google.com/apis/ajaxlibs/) is great and all, but can slow things down if you're doing a lot of refreshing/cache clearing while debugging. Here's a neat trick: stuff something like this in the `<head>` of yo...
1 1693 posted 16 years ago by jdbartlett
When you have a URL like this http://mysite/newsletters/index/2007 The find('first') method adds the 2007 value as ID parameter WTF!?
0 1169 posted 16 years ago by sveggiani
This code within your CakePHP Controller to include a Model.
0 1234 posted 16 years ago by jdbartlett
1 1202 posted 16 years ago by resurge
3 1731 posted 16 years ago by sveggiani