Jun 08

So I have tried to get ZendX_JQuery working the last hour or so (could be more) and it just wouldn’t work.

I googled all over the place. Read blogs, wikis, the Zend Referance guide, stackoverflow questions and forums. They all say to do the same thing: Put this in your layout: $this->jQuery();

and this:

$view = new ZendView(); $view->addHelperPath('ZendX/JQuery/View/Helper', 'ZendXJQueryViewHelper'); $viewRenderer = new ZendControllerActionHelperViewRenderer(); $viewRenderer->setView($view); ZendControllerAction_HelperBroker::addHelper($viewRenderer);

in the bootstrap.php.

The problem is that it work on the views where I use jQuery, but on the others I get a long error message. Here, share the pain with me:

“Fatal error: Uncaught exception ‘ZendLoaderPluginLoaderException’ with message ‘Plugin by name ‘JQuery’ was not found in the registry; used paths: ZendViewHelper: Zend/View/Helper/:./views/helpers/’ in /opt/lampp/htdocs/mjfregistration/library/Zend/Loader/PluginLoader.php:412 Stack trace: #0 /opt/lampp/htdocs/mjfregistration/library/Zend/View/Abstract.php(1170): ZendLoaderPluginLoader->load(‘JQuery’) #1 /opt/lampp/htdocs/mjfregistration/library/Zend/View/Abstract.php(610): ZendViewAbstract->getPlugin(‘helper’, ‘jQuery’) #2 /opt/lampp/htdocs/mjfregistration/library/Zend/View/Abstract.php(336): ZendViewAbstract->getHelper(‘jQuery’) #3 [internal function]: ZendView_Abstract->__call(‘jQuery’, Array) #4 /opt/lampp/htdocs/mjfregistration/application/layouts/scripts/layout.phtml(8): Zend_View->jQuery() #5 /opt/lampp/htdocs/mjfregistration/library/Zend/View.php(108): include(‘/opt/lampp/htdo…’) #6 /opt/lampp/htdocs/mjfregistration/library/Zend/View/Abstract.php(880): Zend_View->_run(‘/opt/lampp/htdo…’) #7 /opt/l in /opt/lampp/htdocs/mjfregistration/library/Zend/Loader/PluginLoader.php on line 412″

So finally I find this video and in it the code that actually works :D

$this->bootstrap("layout"); $layout = $this->getResource("layout"); $view = $layout->getView(); ZendX_JQuery::enableView($view);

I’m not sure why the thing that every other tutorial and blog says to do didn’t work, but this did, so at this point I’m happy:D

written by harri \\ tags: , , ,

Mar 21

I have for some time now considered to start using a php framework for my project, but the question was then which framework to choose. So the frameworks it all have boiled down to is Zend Framework and Codeigniter. I know there is others, but from what I have heard this is the of the better once.

For some reason I has a little drawn over to ZF before I started to research and compare and I have checked out ZF earlier so I may be a little biased. After some googling and research I have come to the conclusion that I will start to use Zend Framework for my php projects. I will not get in to the details in the comparison here, because many other people have written and know much more about it, but I’ll give you some links to read. The major cons with ZF is slower performance and a little harder to set up, but other than that it is great and I think that I can live with those few cons.

Here is some of the articles I read during my research:

written by harri \\ tags: , , , ,

Jan 19

I don’t know if you have ever felt it: the feeling of informationoverload. A sudden panic attack, not the freaky big one, but the small “crap! what to do now?”-feeling. You suddenly notice that you are reading on something else than you intended and wanting to learn/to that in addition to the original intent. You can’t seem to decide what to prioritize and end up trying to do/read/learn it all at once. And at one point you can’t bear it anymore. The only thing you can do is to put it all away and do something completely different.

I had that feeling today. I tried to read learn the Zend PHP framework while plan the application to use it in AND read/learn the Gdata api while planning a another application to use the gdata api in and all of these things simultaneously. It did not work very well. Next time I need do just one of these and complete it before and move on to the next thing.

I wrote a poem about it here. http://www.ekkodill.com/2009/01/informationoverload/

written by harri \\ tags: , , , ,