1

When I run my app on my locale machine it works fine, but when I run it on my sever using cpanel, everything works fine expect when I use js helper using jquery library the following error occurs

Error: jqueryEngineHelper could not be found.

Error: Create the class jqueryEngineHelper below in file: app/View/Helper/jqueryEngineHelper.php

<?php class jqueryEngineHelper extends AppHelper { } 

Nb: all the files exists.

2 Answers 2

3

It's incorrectly looking for "jqueryEngineHelper" instead of "JqueryEngineHelper" which most likely means you didn't use correct casing when specifying the helper in controller. Make sure you have public $helpers = array('Js' => array('Jquery')); with capital "J" for "Jquery" and not "jquery"

Sign up to request clarification or add additional context in comments.

3 Comments

Wooow thank you , youre good ! , but why it worked on my localhost ?
Because locally you are using windows which has a case insensitive file system.
Welcome, you might want to select my answer as the accepted one :)
-1

Try with App::uses() to load the helper.

http://book.cakephp.org/2.0/en/core-utility-libraries/app.html#loading-classes

Example from CakePHP documentation:

App::uses('HtmlHelper', 'View/Helper'); 

You try:

App::uses('jqueryEngineHelper', 'View/Helper'); 

EDIT:

Try putting that in your AppController.php at your starting lines in your code.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.