Something I discovered fairly quickly when coding (cake)PHP in eclipse, is that, like code completion in Models, unless you do a little extra configuration, code completion in Views won’t work.

If however, you make a slight modification to the Views index.ctp, and create a HtmlHelper() yourself, then you get code completion on $html->, and access to all the methods, and the rendered view isn’t affected at all.

For example:

<?php
if(false)
 
{
 
$html = new HtmlHelper();
 
}
 
?>

I found the answer to this after posting on the CakePHP google group, and getting a good answer from a user. Top Stuff

Share this post:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • LinkedIn
  • StumbleUpon
  • Technorati

Leave a Reply