Hello guys,
I need help in understanding the actual actions of a helper function in Zend Framework.
I need someone to explain to me what $this->escape($string) actually does to the string passed to it before printing the string into the template.
Thanks in advance
...
Is there a CMS built on Zend Framework?
As alternative, are there classes that allow to easier implement a CMS with Zend Framework?
If there are any CMSs, can you suggest which one is better, or which one you would use?
...
Hi Folks,
is there any way to get an Action Helper from an Service Class?
I have the following Helper:
class Helper_Host extends Zend_Controller_Action_Helper_Abstract
{
/**
* Return Hosturl with path
*
* @return string Hostname
*/
public function direct()
{
$front = Zend_Controller_Front::getIn...
Is there a helper method/object/methodology for getting a reference to a Zend_Application's config resource?
I know I can do something like
$config = new Zend_Config_Ini($file, $environment);
but that's going to reload/parse the config file. I'm looking for a way to peek at the given configuration value for a running Zend_Applicati...
I'm using the Zend framework to display a list of radio options on a html form. I have to use the radio element
because i want the user to see all options on the page, i would have used a checkbox otherwise.
I'm populating the list of radios from a database query.
$sectorname = new Zend_Form_Element_Radio('sectorname');
$sectorname->s...
I'm having difficulty configuring Zend_Form. I have a Zend_Form sub-class. The form has some required information and some additional information. I want the additional information to be accessible via an array. The submitted data will look something like this:
$formData['required1']
$formData['required2']
$formData['addiotnalData']['aD...
I'm new to zend framework and I want to ask if is it possible to have a base controller that will be extended by all other controllers? I want to have a base class wherein I'll put all common methods and properties for all controllers I'll have on my project. Is it advisable to do this with zend or is there a better approach to this?
...
I'm using Zend_Service_Twitter to run a Twitter search and return json. I'm having a problem with the since_id values I'm getting back. When I print_r() the search results, I get back the following:
...
[since_id] => -2017847207
[refresh_url] => ?since_id=6801825835&q=myTwitterSearchQuery
...
The [since_id] value is different to the...
I want to find out how many rows are in a table. The database that I am using is a MySQL database. I already have a Db_Table class that I am using for calls like fetchAll(). But I don't need any information from the table, just the row count. How can I get a count of all the rows in the table without calling fetchAll()?
Solution:
This ...
I want to get the date of the closest Monday in the future (i.e. not in the past).
So if today is Tuesday (Dec 1, 2009) I want to get the date of Monday (Dec 7, 2009).
How can I do this with Zend_Date?
Solution:
Let's say today is Tuesday and we wanted to get the upcoming Monday. Monday is 6 days into the future. So, we would add 6 d...
I'm having this weird thing happen. My Zend Framework (PHP) web application that I have been developing locally works fine on my computer, but once it's uploaded to the server, it thinks that the uploads directory doesn't exist.
My application has an uploads directory which is a symlink to a directory outside of the application:
#local...
I am using following zend code to select all data from a table where verified=1 and it is working for me.
$table = $this->getDbTable();
$select = $table->select();
$select->where('verified = 1');
$rows = $table->fetchAll($select);
No I want to select all data from that table where verified is not equal to '1'. I have tried the followi...
I have been looking at manuals of the Zend search engine, but I don't really understand much of it. I have a php website (classifieds) and I want users to be able to search my mysql database for records.
Can someone explain a little more about the Zend search engine, and how I should actually 'install' it.
I don't have my own server (h...
I an redirection (in some cases) from a controller to the error controller, action 'not-logged-in' using the redirector helper. My problem is the following: I want to pass an argument in the $_POST array (an URL from where the redirection happened) so the user will be able to return to that page after performing a login.
How can i plac...
I have read the intro to the zend manual, and as far as I understand I have to install the framework on my server... And my webhosting provider says they don't support that, so it's not possible...
It must be installed in order for me to use it and implement a search function of my mysql records, right?
Thanks
...
Hi,
Zend Db_NoRecordExists docs seem to be limited to checking only one column. Is there a way to check multiple keys when validating an entry? For example, I am allowing the same email address for different cities.
here's my current validator:
$email->setValidators(array(array('emailAddress'),
array('Db_NoRecordExis...
I am trying to set the date format of the date picker element, but I can't get it to work. How do you set the date format of a ZendX_JQuery_Form_Element_DatePicker element?
Solution:
Strange...I tried my original code sample again, and it worked.
$element = new ZendX_JQuery_Form_Element_DatePicker('date', array(
'jQueryParams' => ...
I have my directory structure set up as follows:
Application Root
|-application
| |--configs
| |--controllers
| | |--helpers
| |
| |--layouts
| | |--scripts
| |
| |--models
| |--views
| |--scripts
| |--index
| |--test
|
|--data
| |--session
|
|--public
|--index.php
|--.htaccess
In my controllers directory...
I have a Zend Framework (PHP) web application that has a table with a lot of rows.
99.9% of the time, the user will take action on the first or second row.
00.1% of the time, the user will need to go back and take action on a different row.
So I only really need to display the first few rows on page load, and keep the rest available ...
I would like to get rid of the definition list format of my Zend_Form. This is the layout that I'm going for:
<form>
<p>
<label for="email" class="required">Your email address:</label>
<input type="text" name="email" id="email" value="">
</p>
<p>
<input type="submit" name="submit" id="submit" value="S...