I'm building a custom autoloader based on Zend Framework's autoloading (related question here).
The basic approach, taken from that question, is
class My_Autoloader implements Zend_Loader_Autoloader_Interface
{
public function autoload($class)
{
// add your logic to find the required classes in here
}
}
and then...
Hi,
I want to offer audio files for download on my site, after a user has completed a PayPal transaction. The commerce side of it is already written and working - the site is built in PHP with Zend Framework.
So that I don't incur large charges for storage and bandwidth, I'd like to host the files on a service like Amazon S3. However, ...
How to have Dojo support disabled by default and just enable it if you want to use it ?
I have the problem that dojo support is automaticly loaded when using any form.
Even without any dojo elements.
I have following configuration:
Bootstrap file
if($this->dojo()->isEnabled()){
$this->dojo()->setLocalPath($this->baseUrl().'/js/...
Hi am starting off with Zend Framework and have a question about action helpers. My first application is a simple authentication system (following a tutorial from a book). The registration and authentication seems to work fine but the redirect doesn't.
I have a customer controller that has this among others:
class CustomerControlle...
Hi guys - concerning Gmail labels - what are they technically speaking. I mean through imap connection I can access a gmail mailbox and go through the emails however let say I wish to create a label and attach it to the emails as I loop through them using code - how can I do that in code? I'm using php - and Zend Framework.
EDIT ===
Th...
hello everyone,
I downloaded cahoots from sourceforge.net. It is a zend framework application. Very nicely done and I must say that it should be a nice tutorial for everyone who is struggling to learn Zend framework.
But my problem is that even after reading the instructions this application is still not running. The application just d...
I'm looking for some good resources to learn how to implement internal service layer in Zend Framework. This is interesting post, but with no concrete code samples.
Where to put service classes (/application/modules/modulename/services/?);
How to autoload them (custom autoloader?)
Most common services (user, authentication, cart, cache...
Hi,
i´m a little bit confused by reading all this posts an tutorials about staring with Zend, because there a so many different ways to solve a problem.
I only need a feedback about my code to know if iam on the right way:
To simply get a (hard coded) Navigation for my side (depending on who is logged in) i build a Controller Plugin w...
I am trying to extract the GET parameters from a ZF REST URL. It's not the current request and I don't want to call the URL or execute the route, I just need the parameters. I'm looking for a utility function like parse_url(), but for the Zend REST format. Is there one, or do I have to reinvent the wheel?
I've tried a few things like cr...
The code says Zend_Form_element_File::setDestination() is depricated and to use the rename filter. However the rename filter is currently codes such that when path is set, only temporary name is given. Original filename is lost.
<?php
$file = new Zend_Form_Element_File();
$file->setDestination('/var/www/project/public');
?>
vs
<?php...
I want to check in zend, whether a posted form value 'name' contains a value.For this i have used the following code
one method
if ($this->_getPatram('name') != null ) {
echo 'field name contains value';
} else {
echo 'field name contains null value';
}
second method
if ($this->_hasParam('name')) {
echo 'field name contains...
In my Zend Framework modules, I have views that require specific javascript, CSS and images.
Is that possible to include them in the module in a way that I don't have to copy them in each project that uses the module ? (because the "public/" folder is not part of the module, but specific to each application)
If not, how can I do ?
Tha...
Not so much a programming problem, but more a productivity problem.
We've got quite a few custom view and action helpers in our project. Working with around 7 programmers.
Now when someone, creates a helper or if one would want to use a helper, it all goes through the brokers. This means we do not get intellisense for those helpers, w...
I have made several multi page forms based on the example from zend official site:
zend form advanced
As long as I use text, radio or select elements everything is going OK. When I am trying to use file type element I get error and message:
Invalid argument passed to prepareSubForm()
I think, it is worth to write that when I have thre...
Hi guys I'm building a form that uploads documents to my google docs account however its not working I keep getting an error - the following is my code;
$service = Zend_Gdata_Docs::AUTH_SERVICE_NAME;
$client = Zend_Gdata_ClientLogin::getHttpClient($username, $pww, $service);
$docs = new Zend_Gdata_Docs($client);
$newDocumentEntry = $do...
Hey there,
I've been using the Zend Framework to map subdomain requests to a module in my main MVC application but now I need to change the virtual host config back and use a htaccess file instead. Previously all I needed to do in the virtual host config was to set the subdomain DocumentRoot to be the document root of the main applicati...
Could someone give few tips and/or examples how Controller Plugins and Action Helpers are different? Are there situations where particular task could be accomplished with one but not another? For me they both look more or less the same and I'm often having trouble having to decide when to use what... Are there any big differences?
...
Hi There
I am trying to use the tranlsation webservice from MyMemory: http://mymemory.translated.net/doc/spec.php
Unfortunately, Zend_Soap_Client does generate an XML reqest object that is not recognized by the service. I guess it is because of the ns1-Attribute (Namespace) within the tags. So does anyone know how to remove them?
Tha...
I am having problems getting validation to work for a form built using Zend_Form.
The idea is this: I have two dropdown. One is a list of players. The other is a list of free agents who play the same position as the player. I am using an onChange javascript callback to run some Ajax code that replaces the free agent list dropdown ...
Ive got a url: http://dev.local/foodies/view?id=bluedaniel
and ive got in my bootstrap:
protected function _initRoute() {
$config = new Zend_Config_Ini(APPLICATION_PATH . '/configs/routes.ini', 'production');
$router = new Zend_Controller_Router_Rewrite();
$router->addConfig($config, 'resources');
}
and
iv...