zend-framework

In Zend Lucene, how can I change the field which a query searches?

I am trying to create an "advanced search", where I can let the user search only specific fields of my index. For that, I'm using a boolean query: $sq1 = Zend_Search_Lucene_Search_QueryParser::parse($field1); // <- provided by user $sq2 = Zend_Search_Lucene_Search_QueryParser::parse($field2); // <- provided by user $query = new Zend_Se...

Zend form and Zend filter HtmlEntities

Hi. I have a registration form with a few fields. One of them looks like this: $first_name = new Zend_Form_Element_Text('first_name'); $first_name ->setLabel("First name") ->setRequired(true) ->addFilter(new Zend_Filter_HtmlEntities()); I use the same form for editing user's deta...

Zend Framework call form as subform within a form.

Hello, I am trying to call a form from within another form. I need it to come in as a subform. However, I cannot merely extend it as both forms extend different things that are required. This is kind of what I was thinking but it doesn't work: $subForm3 = new Form_CreateEventInformation(); Basically create a subform3 from th...

Issue with the doctrine-cli

I am having issues getting my database to build from my YAML file. Here is the error: ./scripts/doctrine-cli build-all-load build-all-load - Generated models successfully from YAML schema build-all-load - Couldn't locate driver named mysql build-all-load - Created tables successfully build-all-load - Data was successfully loaded It b...

Zend framework query, add to string

Hi guys, let's say that I have: $query = $this->select() ->where('name LIKE ?','%something%'); ->where('section LIKE ?','%something%'); ->where('cars LIKE ?','%something%'); ............ ............ You get the point! But I want to add the where() clause to the qu...

zend mod rewrite not working

tia here i my .htacess SetEnv APPLICATION_ENV development RewriteEngine On RewriteCond %{REQUEST_FILENAME} -s [OR] RewriteCond %{REQUEST_FILENAME} -l [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^.*$ - [NC,L] RewriteRule ^.*$ index.php [NC,L] ...

Create new framework project in Zend Studio

I hv problem in creating New Framework project on Zend Studio.I'm new to Zend Studio. Using Zend Studio ver.7.1.0. When i'm creating new zend framwork project (Zend Server is successfully installed), It will not create 'application' & 'public' folders. In my previous test project those were created automatically. But now its create only ...

ZendX date picker example not working

Hi Stackland I am rather new to ZendX and I really wanted to get the simple JQuery example on Zend to get working.I have followed the example on the link below but all I get is a plain textbox without any datepicker functionality as I expected. http://stackoverflow.com/questions/1616857/best-way-to-start-using-jquery-in-a-zend-framewor...

Default element value using Zend_Form with Zend_Config_Ini

I have been looking for hours and I can't find any documentation anywhere as to how you set the default value of an element using Zend_Config_Ini as the initialisation to a Zend_Form. I've seen the documentation for how you do it in normal PHP code... $validators = array( 'month' => array( 'digits', 'default' => '1'...

Add scripts to overall layout from within a controller

Hi, I'm using Zend_view/Zend_Layout but i want to be able to append scripts to the overall template depending on the controller, so within the controller i could do something like: public function someAction() { $something->headScript()->appendFile('script.js','text/javascript'); // etc etc } I have enabled Zend_view/Zend_Lay...

Zend navigation from action

<ul> <li> <a href="<?= $this->route('list', 'test1', 'default', array(), null, false) ?>">Test1 </a> </li> <li> <a href="<?= $this->route('list', 'test1', 'default', array(), null, false) ?>">Test2 </a> </li> <li> <a href="<?= $this->route('list', 'test3', 'default', array(), nu...

Add HTML placeholder into Zend_Form

I'm using Zend_Form for an application form using this code: class Form_ApplicationForm extends Zend_Form { public function init() { $this->setAction('/application/new') ->setMethod('post') ->setAttrib('id','application'); $name = new Zend_Form_Element_Text('name'); $name->setLa...

ZEND FW : Joining two tables from different databases

I want to join two tables in differenet databases on the same server. Could someone tell me how I could do this in Zend Frameworks Db adapter? ...

Is it possible to configure custom plugin directories for Zend?

I want to be able to store custom plugins in the library folder of my application (currently I am storing them in the Zend library itself). Is there a way of providing additional plugin directories in the application.ini file? ...

creating a custom form element in Zend_Form

I'm attempting to create a custom form field in Zend_Form to store a snippet of HTML that is required by SWFUpload(for the purposes of a flash file uploader). I've tried following a few different tutorials but i'm getting pretty confused, so far this is what i have: /application/forms/elements/SwfUpload.php ...

Style form elements in Zend Framework

I have some Zend_Form $text = new Zend_Form_Element_Textarea('text'); $text->setLabel('Leave a reply') ->setAttrib('rows', 9) ->setAttrib('cols', 50) ->addValidator('NotEmpty') ->setRequired(true) ->setAttrib('class', 'comment_form'); I wand to style this form, to add some style for label tag and another style...

How do I eliminate the views/scripts folder?

Let's say I'm tired of having to put my page template folders under views/scripts and want to just put them under views, leaving out the "scripts" part of the path. How can I alter the config of ZendFramework to permit me to do that? ...

better implementaion of a global Zend_Log instance?

Is there a better way to have a globally accessible Zend_Log object? In Bootstrap.php I'm doing: protected function _initLogging() { $logger = new Zend_Log(); $writer = new Zend_Log_Writer_Stream(APPLICATION_PATH . '/../app.log'); $logger->addWriter($writer); Zend_Registry::set('log', $logger); } Then throughout the a...

Dwoo does not echo strings with utf8 characters

Hello ! I have got a strange problem with Zend Framework - I fetch data from MySql table that is set to utf8_general_ci. I inserted some data with polish fonts like ś ę ż... and push that data to view (Dwoo). {foreach $units unit} <tr> <td>{$unit.id_unit}</td> <td>{$unit.name}</td> </tr> ...

Eliminating the need for "controller" in the filename of a Zend Framework controller

How do I eliminate the need for the "Controller" suffix in the filename of a Zend Framework controller? It just gets tiresome to keep typing that suffix in when creating controllers, and meanwhile the file is already in a controllers folder so it's superfluous. For instance, by default the homepage on a site goes to "controllers/IndexCo...