zend-framework

Best way to get rid of www. and .

I want all traffic to go to: http://www.domain.com http://domain.com | V http://main.domain.com I can use .htaccess or maybe something in PHP, I'm using zend framework. Please note I also have: http://sub1.domain.com http://sub2.domain.com thx ...

How do I flush the Zend Output buffer at the Controller stage?

I have a Zend Controller that serves files to users I have used Noginn SendFile action helper to do the actual streaming of the file, but the code simply uses readfile($path) to place the content of the file into the buffer after setting the MIME and content type etc The problem is that the file that arrives down the pipe has an extra ...

Why can't I view the public folder of Zend Framework Project?

I recently started learning zend framework. I am trying to access the index.php inside the public folder, but when i test the project using WAMP server in browser, I can't find the public folder in the web root. I can see other folders like applications, library, docs but there isn't any public folder. Why can't I view the public folder...

zend one controller many views

hi there when i build my web site it was handling only one interface but now i need to handle many interface i can detect which site to communicate and isolate it from other sites but i stuck with this : all the sites have the same views ... is there are a way so i can rander from the same controller different views .. something like...

Zend_Controller_Router_Route_Regex is case insensitive

For those wondering why Zend_Controller_Router_Route_Regex matches case-different routes, eg. hxxp://example.com/EN vs. hxxp://example.com/en, here's an explanation. Zend_Controller_Router_Route_Regex is implicitly case insensitive. It is set in Zend_Controller_Router_Route_Regex::match() method. This is the piece of code that sets PCR...

change error_message in Zend_Validate_EmailAddress

I need change all standart error message on my message in Zend_Element_Text when i use validator('EmailAddress') this validator trows several differnt message. Value is required and can't be empty '' is no valid email address in the basic format local-part@hostname When i set options setErrorMessage('some my error text') it string sh...

Zend Framework - Class Names - Change Defualt Rules :: How Can be Zend application be configured for more short class names without folders names?

Hi, In zend project have rules default for calling classes that say to put folder class structure before class name. Example: class Application_Model_DbTable_Albums means: that this class inside folders: Application->Model->DBTable, if its called Just class Albums he will be unrecognized. How Can be Zend application be configured fo...

Zend not autoloading models

Ok, this is driving me nuts! I have a directory structure as follows: application - modules -- default --- controllers --- models ---- DbTable ---- Cachmapper.php --- views My config file looks like this [production] phpSettings.display_startup_errors = 0 phpSettings.display_errors = 0 includePaths.library = APPLICATION_PATH "/../li...

PHP Zend XML-RPC - Any way to disable the 'nil' in requests?

I'm using Zend XML-RPC Client library to send XML requests to another non-PHP XML RPC server.(it's a java JBoss install, but I don't have control to change it/patch it/hack it). One request I'm making has a <nil/> element, which is a XML-RPC extension. The XML-RPC server I'm talking to doesn't support that because the request fails with ...

Possible to use _referenceMap with join() on Zend_Db_Select?

Hi All, Example: class Products extends Zend_Db_Table_Abstract { protected $_name = 'products'; protected $_referenceMap = array( 'Bug' => array( 'columns' => array('bug_id'), 'refTableClass' => 'Bugs', 'refColumns' => array('bug_id') ) ); } $obj...

Xcache var_size error

I am trying to use xcache with zend framework to cache the metadata from Zend_Db_Table_Abstract so that describe queries are only called once per table. When implementing xcache into my bootstrap and running the application, I am being presented with the following error: Warning: xcache_get() [function.xcache-get]: xcache.var_size is e...

How to populate() an entire Zend_Form minus one form element?

I have a simple content edit form (Zend_Form) that I populate() with an array generated from the Zend_Db_Table_Row_Abstract->toArray() method. It works quite well. The goal is to not populate one of the form elements with a value. I'm currently solving this by removing that specific key => value pair from the populating array. I'm curi...

Gmail 3-legged OAuth access -- Zend_Mail_Protocol_Exception

I'm trying to access Gmail by using three-legged Oauth PHP code provided by Google ('google-mail-xoauth-tools') here: http://code.google.com/apis/gmail/oauth/code.html. I have my domain registered and everything seems to go fine with OAuth, but after I authorize access I get this error: Fatal error: Uncaught exception 'Zend_Mail_Protoc...

Why Zend_Route don't work?

routes.info.route = "info" routes.info.defaults.module = "default" routes.info.defaults.controller = "index" routes.info.defaults.action = "info" http://localhost/info/ Exception information: Message: Invalid controller specified (info) Request Parameters: array ( 'controller' => 'info', 'action' => 'index', 'module' => 'd...

Array to Array pushing in Zend Session object

Hello! I have some example of pushing array to array in session object: class someClass extends someOtherOne { ...////// some other code here that starts session and creates namespace public function __add2Session($a,$b) { $namespc = $this -> __getnewNameSpace(); //returns a Zend Session Namesapce (object) if ...

Using the ZF autoloader to load models

I have a simple ZF application (no modules) which works fine when I require classes before I use them. However, I'd like to use the ZF autoloader to load them automatically (which I assumed was default behaviour). How would I go about doing this? I'm a bit confused by the new(ish) Zend_Application way of doing things. My directory struc...

Zend DB MYSQL Wrapper

All, I have a PHP application written in Zend Framework with MVC style. I plan to use Zend_DB to connect to the MySQL database and process queries. I am looking for a wrapper class which makes it easy to use Zend_DB class. This wrapper class will have a constructor that connects to the Mysql db using Zend_DB. It will also have a method ...

How do I echo the number of items in an array?

A total newbie question I know. I'm sing Zend framework, and sending an array from the controller: $this->view->googleArray = $viewFeedArray; In the view, I have a foreach loop that is populating a table with the array contents. <?php foreach($this->googleArray as $row) { ?> <tr> <td><?php echo $row['when']; ?></t...

Configure aptana 2.0.1 with zend framework 1.10.3 enable tooltip

I see in video tutorial there is or plugin or spesial setting for aptana studio.When whrite in studio pop up variaty functions and objects with description particularly with zend framework. How to set up a studio ?or what plugin use for this? ...

Is ZendX still active (Specifically ZendX_JQuery) ?

I need to have an autocomplete functionality using jquery, and I've encountered ZendX_JQuery which has such functionality available. However, I've noticed that the entire ZendX_JQuery classes, are a bit old (the default jquery version is 1.3.2, and jquery ui 1.7.1). (see http://framework.zend.com/svn/framework/extras/branches/release-1....