zend-framework

"Hierarchical" rowsets in Zend Framework?

I have two tables - let's call them Customers and Orders. It's a 1:n relationship, where each Order is placed by one Customer, and one Customer can have many orders. The Web app is written in Zend Framework. My goal is to query a customer from the database, and get their 10 most recent orders (for example), and to have all this informat...

How can I prevent the Facebook session key from expiring

I am developing a Facebook app in Zend Framework. I am using the Facebook session key for my PHP session ID (this is the practice recommended by Facebook). The problem is that after an hour or so, it appears that the Facebook session key expires because I lose my PHP session. Is there a way to prevent (or at least significantly delay) th...

Zend_Auth checking if user is logged in

i tried using // do login if request is posted if (isset($_POST) } } Zend_Auth::getInstance()->hasIdentity() seem to be always false ... even after a login ...

CodeIgniter, ZF, etc.

I use ZF a lot and I like it very much. I've learned how to solve a big part of perfomance problems with ZF, so it's became not "enormous" and "monstrous" for me. But I'd like to know if there are any as powerful frameworks as Zend for PHP. Maybe CodeIgniter is? What is it? What are its cool features? Anything else? And, are there any ...

ActiveRecord and many to many relationship ?

I'm trying to implement the Active Record pattern to a ZF project. I used to work with a similar approch before and it works well. But my problem now, is about how to handle many-to-many relationship with my models. Here is an example : Let's say i've an User model. <?php require_once 'MLO/Model/Model.php'; class Model_User extends...

404 error for mod_rewrite using SSL and MAMP

I am building an app in Zend Framework at the moment and testing it all locally. I have Mamp Pro as my web server and I have a self-signed SSL which all seems to work. My problem comes when I try to do mod_rewrite - I just get 404 pages. The way I have things set up (which may not be the best way...) In Mamp I have 2 virtualhosts set...

Zend Framework 1.9 addModuleDirectory not working?

Ok, I'm frustrated beyond words! I have a ZF 1.9 application. The following is in my bootstrap.php: $front = Zend_Controller_Front::getInstance(); $front->addModuleDirectory(dirname(__FILE__).'/modules'); I've put some trace code into the ZF library files, and I can see the call to addModuleDirectory and the subsequent internal call ...

Zend_Db_Select order by random, compatible in mssql / mysql

Alright here's the situation, I have an application written in the Zend_Framework, that is compatible with both MySQL and MSSQL as the backend. Now, ZF is pretty good at solving a lot of the SQL discrepancies/differences between the two languages, but I still have yet to figure this one out. The objective is to select 1 random record f...

How do you migrate an old project to Zend Tool?

I've got a project developed circa Zend Framework 1.7 that I'd like to migrate to Zend Tool and ZF 1.9.4pl1. The main benefit I hope to gain is to be able to use automatic loading of Models, Forms, etc. In other words, I want to eliminate all of these little methods: protected function _getSurveyForm() { require_once APPLICATION_PATH ...

Layout being rendered twice

I seem to have a problem with my layout displaying twice. I was wondering if this was caused by something in my front controller plugin (see below) which utilises Zend Layout only for a particular module and not in the main application. Any answers will be much appreciated. Thanks class My_Controller_Plugin_AdoptLayout extends Zend_Cont...

How to use Zend_Form in a layout script

Hi, i am using Zend Framework, i have an layout.phtml wich renders navigation.phtml. How can i display a search form in this script ? Where is the right place to set the form ? In normal view scripts i will use the controllerAction to set the form , and simply echo it.. Do i need an FrontController Plugin, wich sets the form ? ...

Zend Framework Application Session Resource and Bootstrapping, what is wrong?

Hi: I am using the latest version of Zend Framework (1.9.3PL1). I set the following in my .ini ; Bootstrap session resources resources.session.save_path = APPLICATION_PATH "/../data/sessions" resources.session.use_only_cookies = true resources.session.remember_me_seconds = 864000 Next I want to initialize my session in my bootstrapper...

using dojo tab container with viewScript

Hi, I am trying to get dojo tab containers working using this example: Creating Tab Form. However although this gives a basic feel for a tab form container, I would like to know if it is possible to alter the layout so that I can cusomise it to fit with my current look and feel of the application. I was thinking of viewscripts but uns...

zend framework wiki

Where is zend framework wiki? http://framework.zend.com/wiki/ : "An error occurred with this request: Invalid controller specified (wiki)." googling gives nothing ...

Tracking DB changes with Zend Framework?

I am trying to decide between the Zend Framework and Ruby On Rails for my web application. If I go with ZF, I need the following: A way to incrementally track changes to my database, as with RoR's migration feature (001_something.sql, 002_something_else.sql). A place to put SQL for the next release of my software. At work in our custo...

Creating and updating Zend_Search_Lucene indexes

I'm using Zend_Search_Lucene to create an index of articles to allow them to be searched on my website. Whenever a administrator updates/creates/deletes an article in the admin area, the index is rebuilt: $config = Zend_Registry::get("config"); $cache = $config->lucene->cache; $path = $cache . "/articles"; try { $index = Zend_Searc...

Zend_Form using subforms getValues() problem

Hi all, I am building a form in Zend Framework 1.9 using subforms as well as Zend_JQuery being enabled on those forms. The form itself is fine and all the error checking etc is working as normal. But the issue I am having is that when I'm trying to retrieve the values in my controller, I'm receiving just the form entry for the last subf...

Zend framework session expires prematurely

This should be extremely simple, but I can't seem to get it! I'm using Zend Framework for PHP and handling sessions with the Zend_Session module. This is what I have in my Initializer (or bootstrap): Zend_Session::start(); Zend_Session::rememberMe(864000); 864000 seconds should be good for 10 days, but I'm still being kicked out at ...

Which framework for a project?

I am contemplating between three frameworks: Django, CakePHP and Zend. The project will include social aspect (members), will have a cart/checkout, lots of different forms and very heavy database usage. I would like to write most of my sql by myself but have only basic knowledge of web development. Both PHP and Python will be new languag...

How to reuse methods in ZF views

In my application i have the following classic template on 3 columns ********************************************************* * * * * ********************************************************* * * * * * * * *...