HtmlHelper::inputTag() had the $size param removed.
HtmlHelper::inputTag() had variable with underscore in name still.
param in method was camelCased
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@328 3807eeeb-6ff5-0310-8944-8be069107fe0
Be sure to review the changes made to the blog tutorial.
Some specific changes to note we pass model names in inputTag().
was: $html->inputTag('title', 40)
now: $html->inputTag('post/title', 40)
Also in the tagErrorMsg() we pass the model name.
was: $html->tagErrorMsg('body', 'Body is required.')
now: $html->tagErrorMsg('post/body', 'Body is required.')
https://trac.cakephp.org/wiki/Cake/Tutorials/BlogPosts
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@306 3807eeeb-6ff5-0310-8944-8be069107fe0
It looks like the way you where coding it was to be used as a Singleton.
In Controller::render() I am setting all View() attributed by pass reference.
I do not think it will effect other parts of the system.
You can see why I did this by uncommenting the print_r function in View::render().
Reload url in browser.
Then in Controller::render() remove the & from:
$view->autoRender =& $this->autoRender;
This is the only one that seems to cause array to print.
This may also caused in the Router::connect().
Look at this if you get time.
I noticed that each setting in the conf/routes.php file calls outer::connect();
Tee profiler show this happening 6 times on current install from trunk
Router::parse() is called 2 times.
We really need to get some good unit test in place.
Also speeded things up a little.
Profiler test:
Before changes on default install from trunk
Between:
Total Request Time: 13013.4 Milliseconds
Total Request Time: 13065.84 Milliseconds
28 files
After changes
Between:
Total Request Time: 10230.99 Milliseconds
Total Request Time: 10511.59 Milliseconds
27 files
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@304 3807eeeb-6ff5-0310-8944-8be069107fe0
The first one is for consistency (no UppperCase filenames, please), the second is because while I'm no enemy of application security, the application has to be safe _after_ it's written, not before. And to easily write an application, the developer should have the DEBUG mode set to 1 or 2.
Other than that, I think it's a very good idea to put the tag generators in helpers :)
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@271 3807eeeb-6ff5-0310-8944-8be069107fe0
I am not finished with copying methods out of template.php, but it will come - also data validation would not be a problem helpers inclusion happens in the Template::_render().
Also, there was a bug with error functions (as Controller::missingView) - on linux, calling $this->render('../errors/missingController'); rsulted in an error - beacouse apparently is_file() cannot work with '..'. I added a simple fix in Template::_getViewFn.
I've also made some cleanups. Will continue to work tonight.
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@264 3807eeeb-6ff5-0310-8944-8be069107fe0
- Time::daysAsSql returns SQL limits for a set of days, perhaps should be in DBO,
- cleanups
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@259 3807eeeb-6ff5-0310-8944-8be069107fe0
- "public" cannot be defined as constant (PHP5 keyword)
- Cannot re-assign $this in libs/template.php on line 217...
Other:
- Started on refactoring as described in #27 - but this feels like fooled aproach. We need to modularize HTML and AJAX stuff to be included only on-call.
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@256 3807eeeb-6ff5-0310-8944-8be069107fe0
The point is to provide custom error messages for Cake. As you will see, the quality of documentation is astounding.
git-svn-id: https://svn.cakephp.org/repo/trunk/cake@255 3807eeeb-6ff5-0310-8944-8be069107fe0