Alex Tech Adventures The webs best tutorials!

Welcome, Guest
Please Login or Register.    Lost Password?
Go to bottomPage: 123
TOPIC: jQuery with ZF
#152
Re:jQuery with ZF 2 Years, 3 Months ago Karma: 0
there is only a application directory, no library no public ...
msaba
Fresh Boarder
Posts: 4
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#153
Re:jQuery with ZF 2 Years, 3 Months ago Karma: 0
That's all you need- just plug that into a basic project, i.e replace the default application directory with that one ^_^
Mxb_Design
Fresh Boarder
Posts: 6
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#154
Re:jQuery with ZF 2 Years, 3 Months ago Karma: 0
Ahhhh great I found it...missed a very crucial .... "$this->jQuery()->enable();" somewhere in my phtml....

thnx!
msaba
Fresh Boarder
Posts: 4
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#166
Re:jQuery with ZF 2 Years, 2 Months ago Karma: 0
Hi!
Currently I'm experiencing problems with Jquery enabling
I have a bit different configuration and maybe it have influence on my problem.
The error is simple :
Plugin by name 'JQuery' was not found in the registry
My application.ini is:
Code:


includePaths.library = APPLICATION_PATH "/../library"
includePaths.purifier = APPLICATION_PATH "/../library/HTMLPurifier/library"

bootstrap.path = APPLICATION_PATH "/Bootstrap.php"
bootstrap.class = "Bootstrap"

resources.frontController.moduleDirectory = APPLICATION_PATH "/modules"
resources.frontController.defaultControllerName = "main"
resources.frontController.defaultAction = "index"
resources.frontController.defaultModule = "default"
resources.modules = ""

# Layout
resources.view[] = ""
resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts"

# Views
resources.view.encoding = "UTF-8"
resources.view.basePath = APPLICATION_PATH "/views/"
resources.view.helperPath.Tinymce_View_Helper = APPLICATION_PATH "/../library/Tinymce/View/Helper"
resources.view.helperPath.Ig_View_Helper = APPLICATION_PATH "/../library/Ig/Form/"



And bootstrap looks:
Code:


protected function _initViewHelpers()
{
$view = new Zend_View();
$view->setEncoding('UTF-8');
$view->doctype('XHTML1_STRICT');
$view->headTitle('GM');
$view->env = APPLICATION_ENV;
$view->headMeta()->appendHttpEquiv('Content-Type', 'text/html;charset=utf-8')
->appendName('keywords', 'Gitaros meistrai');
$view->addHelperPath("Ig/View/Helper/","Ig_View_Helper_")
                ->addHelperPath("ZendX/JQuery/View/Helper/", "ZendX_JQuery_View_Helper")
->setHelperPath(APPLICATION_PATH.'/helpers', '');
ZendX_JQuery::enableView($view);
    
        /*
        $view->addHelperPath("ZendX/JQuery/View/Helper", "ZendX_JQuery_View_Helper");
      $view->jQuery()->addStylesheet('/js/jquery/css/hot-sneaks/jquery-ui-1.7.2.custom.css')
        ->setLocalPath('/js/jquery/js/jquery-1.3.2.min.js')
        ->setUiLocalPath('/js/jquery/js/jquery-ui-1.7.2.custom.min.js');*/
        
$viewRenderer = new Zend_Controller_Action_Helper_ViewRenderer($view);

$viewRenderer->setView($view);

Zend_Controller_Action_HelperBroker::addHelper($viewRenderer);

Zend_Layout::startMvc(
            array(
'layout' => 'layout',
                'layoutPath' => '/application/views/layouts',
             'pluginClass' => 'ZFBlog_Layout_Controller_Plugin_Layout'
            )
        );
        
        $view = Zend_Layout::getMvcInstance()->getView();
        
$this->bootstrap('layout');
$layout=$this->getResource('layout');

$config=new Zend_Config_Xml(APPLICATION_PATH . '/configs/navigation.xml', 'nav');
$navigation=new Zend_Navigation($config);

$view->navigation($navigation)->setAcl($this->_acl)->setRole(Zend_Registry::get('role')); 

}


Any ideas?
Thank you!
01Kuzma
Fresh Boarder
Posts: 14
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#169
Re:jQuery with ZF 2 Years, 2 Months ago Karma: 16
Do you have zend extra library in include path (either php's include path or inside library directory of your project)?
alexanderrv
Administrator
Posts: 279
graph
User Offline Click here to see the profile of this user
Gender: Male tmthv2 alexchatonly@hotmail.com Location: Freeport, Bahamas Birthdate: 1989-04-14
The administrator has disabled public write access.
 
#170
Re:jQuery with ZF 2 Years, 2 Months ago Karma: 0
Yes, I've added ZendX folder into Library.
I noticed, that firstly I must add view helper's directory in application.ini and then repeat it in bootstrap.
Really strange behaviour :/
01Kuzma
Fresh Boarder
Posts: 14
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
Go to topPage: 123
Moderators: alexanderrv
You are here: Home Forum

Statistics

Members : 1388
Content : 42
Web Links : 1
Content View Hits : 190529

Poll

Interested in TinyBrowser and TinyMce plugin for ZF?
 

Who's Online

We have 36 guests online