<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-2181687498608084775</id><updated>2012-02-16T00:51:57.478-08:00</updated><title type='text'>Zend FrameWork</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default?start-index=101&amp;max-results=100'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>6866</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6899125778438250263</id><published>2011-03-09T06:28:00.000-08:00</published><updated>2011-03-09T08:21:01.885-08:00</updated><title type='text'>AW: [fw-webservices] Zend_Soap_AutoDiscover bug</title><content type='html'>Hi Omar,&lt;p&gt;can you see the &amp;quot;extra content&amp;quot; by requesting the wsdl file directly?&lt;br&gt;&lt;a href="http://localhost/architecture/applications/security/public/ws/Security.php?wsdl"&gt;http://localhost/architecture/applications/security/public/ws/Security.php?wsdl&lt;/a&gt;&lt;p&gt;How do you call the Webservice? Native SoapClient or with Zend_Soap?&lt;p&gt;Maybe this bugreport describes your problem: &lt;a href="http://bugs.php.net/bug.php?id=48216"&gt;http://bugs.php.net/bug.php?id=48216&lt;/a&gt; (Read the user comments).&lt;p&gt;Like Richard already wrote, we need more info to help. &lt;p&gt;Regards,&lt;br&gt;Thorsten Ruf&lt;p&gt;&amp;gt; -----Urspr&amp;#252;ngliche Nachricht-----&lt;br&gt;&amp;gt; Von: Richard Quadling [mailto:&lt;a href="mailto:rquadling@gmail.com"&gt;rquadling@gmail.com&lt;/a&gt;]&lt;br&gt;&amp;gt; Gesendet: Mittwoch, 9. M&amp;#228;rz 2011 14:07&lt;br&gt;&amp;gt; An: Ing. Omar Antonio D&amp;#237;az Pe&amp;#241;a&lt;br&gt;&amp;gt; Cc: &lt;a href="mailto:fw-webservices@lists.zend.com"&gt;fw-webservices@lists.zend.com&lt;/a&gt;&lt;br&gt;&amp;gt; Betreff: Re: [fw-webservices] Zend_Soap_AutoDiscover bug&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; 2011/3/5 Ing. Omar Antonio D&amp;#237;az Pe&amp;#241;a &amp;lt;&lt;a href="mailto:oadiaz@uci.cu"&gt;oadiaz@uci.cu&lt;/a&gt;&amp;gt;:&lt;br&gt;&amp;gt; &amp;gt; Hi:&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; I&amp;#39;m traying to publish a WSDL-based WebService using&lt;br&gt;&amp;gt; Zend_Soap_AutoDiscover,&lt;br&gt;&amp;gt; &amp;gt; I&amp;#39;ve made my own class and managed the requests for making all works&lt;br&gt;&amp;gt; well&lt;br&gt;&amp;gt; &amp;gt; but when I&amp;#39;m trying to use this WS from another PHP application I&lt;br&gt;&amp;gt; receive&lt;br&gt;&amp;gt; &amp;gt; this error: &amp;quot;SOAP-ERROR: Parsing WSDL: Couldn&amp;#39;t load from&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;#39;&lt;a href="http://localhost/architecture/applications/security/public/ws/Security"&gt;http://localhost/architecture/applications/security/public/ws/Security&lt;/a&gt;&lt;br&gt;&amp;gt; .php?&lt;br&gt;&amp;gt; &amp;gt; wsdl&amp;#39; : Extra content at the end of the document&amp;quot;. The most estrange&lt;br&gt;&amp;gt; part is&lt;br&gt;&amp;gt; &amp;gt; its only happens in Windows platform because I&amp;#39;ve tested the same&lt;br&gt;&amp;gt; code in&lt;br&gt;&amp;gt; &amp;gt; Ubuntu Server and works as I expect.&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Excuse me for my English.&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Regards&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Omar&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Can you provide a link to the live WSDL please? If you don&amp;#39;t want to&lt;br&gt;&amp;gt; do this on list, then off list for me is fine.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; You can see from my posts on &lt;a href="http://news.php.net/php.soap"&gt;http://news.php.net/php.soap&lt;/a&gt; that I&amp;#39;ll&lt;br&gt;&amp;gt; help. And if I mess up, please be shout about it. Conversely, if I&lt;br&gt;&amp;gt; help ...&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Richard.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; Richard Quadling&lt;br&gt;&amp;gt; Twitter : EE : Zend&lt;br&gt;&amp;gt; @RQuadling : &lt;a href="http://e-e.com/M_248814.html"&gt;e-e.com/M_248814.html&lt;/a&gt; : &lt;a href="http://bit.ly/9O8vFY"&gt;bit.ly/9O8vFY&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6899125778438250263?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6899125778438250263/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6899125778438250263' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6899125778438250263'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6899125778438250263'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/aw-fw-webservices-zendsoapautodiscover.html' title='AW: [fw-webservices] Zend_Soap_AutoDiscover bug'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2805793171839069034</id><published>2011-03-09T05:07:00.000-08:00</published><updated>2011-03-09T06:05:08.940-08:00</updated><title type='text'>Re: [fw-webservices] Zend_Soap_AutoDiscover bug</title><content type='html'>2011/3/5 Ing. Omar Antonio D&amp;#237;az Pe&amp;#241;a &amp;lt;&lt;a href="mailto:oadiaz@uci.cu"&gt;oadiaz@uci.cu&lt;/a&gt;&amp;gt;:&lt;br&gt;&amp;gt; Hi:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I&amp;#39;m traying to publish a WSDL-based WebService using Zend_Soap_AutoDiscover,&lt;br&gt;&amp;gt; I&amp;#39;ve made my own class and managed the requests for making all works well&lt;br&gt;&amp;gt; but when I&amp;#39;m trying to use this WS from another PHP application I receive&lt;br&gt;&amp;gt; this error: &amp;quot;SOAP-ERROR: Parsing WSDL: Couldn&amp;#39;t load from&lt;br&gt;&amp;gt; &amp;#39;&lt;a href="http://localhost/architecture/applications/security/public/ws/Security.php"&gt;http://localhost/architecture/applications/security/public/ws/Security.php&lt;/a&gt;?&lt;br&gt;&amp;gt; wsdl&amp;#39; : Extra content at the end of the document&amp;quot;. The most estrange part is&lt;br&gt;&amp;gt; its only happens in Windows platform because I&amp;#39;ve tested the same code in&lt;br&gt;&amp;gt; Ubuntu Server and works as I expect.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Excuse me for my English.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Regards&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Omar&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;p&gt;Can you provide a link to the live WSDL please? If you don&amp;#39;t want to&lt;br&gt;do this on list, then off list for me is fine.&lt;p&gt;You can see from my posts on &lt;a href="http://news.php.net/php.soap"&gt;http://news.php.net/php.soap&lt;/a&gt; that I&amp;#39;ll&lt;br&gt;help. And if I mess up, please be shout about it. Conversely, if I&lt;br&gt;help ...&lt;p&gt;Richard.&lt;p&gt;-- &lt;br&gt;Richard Quadling&lt;br&gt;Twitter : EE : Zend&lt;br&gt;@RQuadling : &lt;a href="http://e-e.com/M_248814.html"&gt;e-e.com/M_248814.html&lt;/a&gt; : &lt;a href="http://bit.ly/9O8vFY"&gt;bit.ly/9O8vFY&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2805793171839069034?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2805793171839069034/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2805793171839069034' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2805793171839069034'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2805793171839069034'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-webservices-zendsoapautodiscover.html' title='Re: [fw-webservices] Zend_Soap_AutoDiscover bug'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2630032084746850057</id><published>2011-03-09T04:04:00.001-08:00</published><updated>2011-03-09T04:04:51.175-08:00</updated><title type='text'>Re: [fw-db] Programmatically Clear Metadata Cache?</title><content type='html'>&amp;gt; You can save cache to registry or get it from bootstrap as it is the same&lt;br&gt;&amp;gt; instance as in table if that comes handy for you.&lt;p&gt;Also consider using Zend_Cache_Manager as a resource bootstrappable via application.ini, as you can retrieve the cache from there, too (especially if you have more than one cache instance). &lt;p&gt;&lt;br&gt;Says: Andreas.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2630032084746850057?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2630032084746850057/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2630032084746850057' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2630032084746850057'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2630032084746850057'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-db-programmatically-clear_09.html' title='Re: [fw-db] Programmatically Clear Metadata Cache?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-9101836438596554778</id><published>2011-03-08T23:10:00.001-08:00</published><updated>2011-03-08T23:10:41.338-08:00</updated><title type='text'>Re: [fw-db] Programmatically Clear Metadata Cache?</title><content type='html'>You can save cache to registry or get it from bootstrap as it is the same&lt;br&gt;instance as in table if that comes handy for you.&lt;br&gt;---&lt;br&gt;Regards,&lt;br&gt;Saša Stamenković&lt;p&gt;&lt;br&gt;On Tue, Mar 8, 2011 at 7:49 PM, JB Christy &amp;lt;&lt;a href="mailto:jbchristy@pacbell.net"&gt;jbchristy@pacbell.net&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt; Thanks for your helpful reply. Hopefully I can figure out how to call that&lt;br&gt;&amp;gt; $table-&amp;gt;getDefaultMetadataCache()-&amp;gt;clean() at the right time / in the&lt;br&gt;&amp;gt; right context.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; -JB&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; ------------------------------&lt;br&gt;&amp;gt; *From:* Саша Стаменковић &amp;lt;&lt;a href="mailto:umpirsky@gmail.com"&gt;umpirsky@gmail.com&lt;/a&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; *To:* JBChristy &amp;lt;&lt;a href="mailto:JBChristy@pacbell.net"&gt;JBChristy@pacbell.net&lt;/a&gt;&amp;gt;&lt;br&gt;&amp;gt; *Cc:* &lt;a href="mailto:fw-db@lists.zend.com"&gt;fw-db@lists.zend.com&lt;/a&gt;&lt;br&gt;&amp;gt; *Sent:* Mon, March 7, 2011 10:57:20 PM&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; *Subject:* Re: [fw-db] Programmatically Clear Metadata Cache?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; You can set table metadata cache with&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; $cache = Zend_Cache::factory(...);&lt;br&gt;&amp;gt; Zend_Db_Table_Abstract::setDefaultMetadataCache($cache);&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; and clear cache with&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; $cache-&amp;gt;clean(...);&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; when the metadata changes.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; ---&lt;br&gt;&amp;gt; Regards,&lt;br&gt;&amp;gt; Saša Stamenković&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On Mon, Mar 7, 2011 at 10:40 PM, JBChristy &amp;lt;&lt;a href="mailto:JBChristy@pacbell.net"&gt;JBChristy@pacbell.net&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; I&amp;#39;ve just up automatic (mem)caching of all Zend_DB_Table&amp;#39;s. From time to&lt;br&gt;&amp;gt;&amp;gt; time, of course, the metadata changes. We do this in our production&lt;br&gt;&amp;gt;&amp;gt; environment by running sql scripts that add / drop / change columns as&lt;br&gt;&amp;gt;&amp;gt; necessary. I need some programmatic way to expire the metadata cache after&lt;br&gt;&amp;gt;&amp;gt; the sql runs, and no later than when updated code goes live, which is a&lt;br&gt;&amp;gt;&amp;gt; matter of minutes. I can&amp;#39;t just wait til it times out.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; I&amp;#39;ve dug into Zend 1.11 Zend_Db_Table_Abstract, and the memcache key is an&lt;br&gt;&amp;gt;&amp;gt; md5 encoding of an optional port, optional host, dbname, schema name and&lt;br&gt;&amp;gt;&amp;gt; table name. There does not appear to be member function to expire the&lt;br&gt;&amp;gt;&amp;gt; cache,&lt;br&gt;&amp;gt;&amp;gt; nor even a function to return the md5 encoded key so I can delete it&lt;br&gt;&amp;gt;&amp;gt; manually.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; How are we supposed to clear the metadata cache when the metadata changes?&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Thanks in advance for your help!&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; --&lt;br&gt;&amp;gt;&amp;gt; View this message in context:&lt;br&gt;&amp;gt;&amp;gt; &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt; Sent from the Zend DB mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-9101836438596554778?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/9101836438596554778/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=9101836438596554778' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9101836438596554778'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9101836438596554778'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-db-programmatically-clear_5458.html' title='Re: [fw-db] Programmatically Clear Metadata Cache?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-9053367769116432714</id><published>2011-03-08T10:49:00.001-08:00</published><updated>2011-03-08T10:49:12.724-08:00</updated><title type='text'>Re: [fw-db] Programmatically Clear Metadata Cache?</title><content type='html'>Thanks for your helpful reply. Hopefully I can figure out how to call that &lt;br&gt;$table-&amp;gt;getDefaultMetadataCache()-&amp;gt;clean() at the right time / in the right &lt;br&gt;context.&lt;p&gt;-JB&lt;p&gt;&lt;p&gt;&lt;p&gt;________________________________&lt;br&gt;From: Саша Стаменковић &amp;lt;&lt;a href="mailto:umpirsky@gmail.com"&gt;umpirsky@gmail.com&lt;/a&gt;&amp;gt;&lt;br&gt;To: JBChristy &amp;lt;&lt;a href="mailto:JBChristy@pacbell.net"&gt;JBChristy@pacbell.net&lt;/a&gt;&amp;gt;&lt;br&gt;Cc: &lt;a href="mailto:fw-db@lists.zend.com"&gt;fw-db@lists.zend.com&lt;/a&gt;&lt;br&gt;Sent: Mon, March 7, 2011 10:57:20 PM&lt;br&gt;Subject: Re: [fw-db] Programmatically Clear Metadata Cache?&lt;p&gt;You can set table metadata cache with&lt;p&gt;$cache = Zend_Cache::factory(...);&lt;br&gt;Zend_Db_Table_Abstract::setDefaultMetadataCache($cache);&lt;p&gt;and clear cache with&lt;p&gt;$cache-&amp;gt;clean(...);&lt;p&gt;when the metadata changes.&lt;p&gt;---&lt;br&gt;Regards,&lt;br&gt;Saša Stamenković&lt;p&gt;&lt;p&gt;On Mon, Mar 7, 2011 at 10:40 PM, JBChristy &amp;lt;&lt;a href="mailto:JBChristy@pacbell.net"&gt;JBChristy@pacbell.net&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;I&amp;#39;ve just up automatic (mem)caching of all Zend_DB_Table&amp;#39;s. From time to&lt;br&gt;&amp;gt;time, of course, the metadata changes. We do this in our production&lt;br&gt;&amp;gt;environment by running sql scripts that add / drop / change columns as&lt;br&gt;&amp;gt;necessary. I need some programmatic way to expire the metadata cache after&lt;br&gt;&amp;gt;the sql runs, and no later than when updated code goes live, which is a&lt;br&gt;&amp;gt;matter of minutes. I can&amp;#39;t just wait til it times out.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;I&amp;#39;ve dug into Zend 1.11 Zend_Db_Table_Abstract, and the memcache key is an&lt;br&gt;&amp;gt;md5 encoding of an optional port, optional host, dbname, schema name and&lt;br&gt;&amp;gt;table name. There does not appear to be member function to expire the cache,&lt;br&gt;&amp;gt;nor even a function to return the md5 encoded key so I can delete it&lt;br&gt;&amp;gt;manually.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;How are we supposed to clear the metadata cache when the metadata changes?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;Thanks in advance for your help!&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;--&lt;br&gt;&amp;gt;View this message in context: &lt;br&gt;&amp;gt;&lt;a href="http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;Sent from the Zend DB mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-9053367769116432714?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/9053367769116432714/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=9053367769116432714' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9053367769116432714'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9053367769116432714'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-db-programmatically-clear_08.html' title='Re: [fw-db] Programmatically Clear Metadata Cache?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4753164242498590135</id><published>2011-03-07T22:57:00.001-08:00</published><updated>2011-03-07T22:57:51.737-08:00</updated><title type='text'>Re: [fw-db] Programmatically Clear Metadata Cache?</title><content type='html'>You can set table metadata cache with&lt;p&gt;$cache = Zend_Cache::factory(...);&lt;br&gt;Zend_Db_Table_Abstract::setDefaultMetadataCache($cache);&lt;p&gt;and clear cache with&lt;p&gt;$cache-&amp;gt;clean(...);&lt;p&gt;when the metadata changes.&lt;p&gt;---&lt;br&gt;Regards,&lt;br&gt;Saša Stamenković&lt;p&gt;&lt;br&gt;On Mon, Mar 7, 2011 at 10:40 PM, JBChristy &amp;lt;&lt;a href="mailto:JBChristy@pacbell.net"&gt;JBChristy@pacbell.net&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt; I&amp;#39;ve just up automatic (mem)caching of all Zend_DB_Table&amp;#39;s. From time to&lt;br&gt;&amp;gt; time, of course, the metadata changes. We do this in our production&lt;br&gt;&amp;gt; environment by running sql scripts that add / drop / change columns as&lt;br&gt;&amp;gt; necessary. I need some programmatic way to expire the metadata cache after&lt;br&gt;&amp;gt; the sql runs, and no later than when updated code goes live, which is a&lt;br&gt;&amp;gt; matter of minutes. I can&amp;#39;t just wait til it times out.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I&amp;#39;ve dug into Zend 1.11 Zend_Db_Table_Abstract, and the memcache key is an&lt;br&gt;&amp;gt; md5 encoding of an optional port, optional host, dbname, schema name and&lt;br&gt;&amp;gt; table name. There does not appear to be member function to expire the&lt;br&gt;&amp;gt; cache,&lt;br&gt;&amp;gt; nor even a function to return the md5 encoded key so I can delete it&lt;br&gt;&amp;gt; manually.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; How are we supposed to clear the metadata cache when the metadata changes?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Thanks in advance for your help!&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; View this message in context:&lt;br&gt;&amp;gt; &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend DB mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4753164242498590135?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4753164242498590135/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4753164242498590135' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4753164242498590135'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4753164242498590135'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-db-programmatically-clear.html' title='Re: [fw-db] Programmatically Clear Metadata Cache?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3777036658426559305</id><published>2011-03-07T13:40:00.001-08:00</published><updated>2011-03-07T13:40:45.855-08:00</updated><title type='text'>[fw-db] Programmatically Clear Metadata Cache?</title><content type='html'>I&amp;#39;ve just up automatic (mem)caching of all Zend_DB_Table&amp;#39;s. From time to&lt;br&gt;time, of course, the metadata changes. We do this in our production&lt;br&gt;environment by running sql scripts that add / drop / change columns as&lt;br&gt;necessary. I need some programmatic way to expire the metadata cache after&lt;br&gt;the sql runs, and no later than when updated code goes live, which is a&lt;br&gt;matter of minutes. I can&amp;#39;t just wait til it times out.&lt;p&gt;I&amp;#39;ve dug into Zend 1.11 Zend_Db_Table_Abstract, and the memcache key is an&lt;br&gt;md5 encoding of an optional port, optional host, dbname, schema name and&lt;br&gt;table name. There does not appear to be member function to expire the cache,&lt;br&gt;nor even a function to return the md5 encoded key so I can delete it&lt;br&gt;manually.&lt;p&gt;How are we supposed to clear the metadata cache when the metadata changes?&lt;p&gt;Thanks in advance for your help!&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Programmatically-Clear-Metadata-Cache-tp3340068p3340068.html&lt;/a&gt;&lt;br&gt;Sent from the Zend DB mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3777036658426559305?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3777036658426559305/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3777036658426559305' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3777036658426559305'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3777036658426559305'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-db-programmatically-clear-metadata.html' title='[fw-db] Programmatically Clear Metadata Cache?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5246473013802927621</id><published>2011-03-07T13:19:00.000-08:00</published><updated>2011-03-07T13:24:09.279-08:00</updated><title type='text'>[fw-webservices] Using Http Auth with a class that extends Zend_Service_Abstract</title><content type='html'>Hi there,&lt;p&gt;I have some troubles with an home-made Url Shortener using Digest HTTP&lt;br&gt;Auth for authentication.&lt;p&gt;The problem is my shortener use a Zend_Rest_Client to forward his query,&lt;br&gt;and that Rest Client extends Zend_Service_Abstract. And&lt;br&gt;Zend_Service_Abstract share his Http Client with all of it&amp;#39;s subclasses&lt;br&gt;(getter and setter are final static methods too...).&lt;p&gt;So, if I give credentials to the HTTP Client Adapter, I must reset them&lt;br&gt;after each call to the shorten method, or I could send them to another&lt;br&gt;Web Server which is clearly not what I want.&lt;p&gt;I see that the problem seems to be solved in the actual ZF2&lt;br&gt;AbstractService, so I think this behavior is no longer wanted.&lt;p&gt;Do you have any idea of how I could avoid this annoying credentials&lt;br&gt;reset after each request ? Without changing my Web Service&lt;br&gt;authentication, of course...&lt;p&gt;Thanks for help,&lt;br&gt;Lucas&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5246473013802927621?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5246473013802927621/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5246473013802927621' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5246473013802927621'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5246473013802927621'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-webservices-using-http-auth-with.html' title='[fw-webservices] Using Http Auth with a class that extends Zend_Service_Abstract'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4031094285285225192</id><published>2011-03-07T07:23:00.000-08:00</published><updated>2011-03-07T07:49:12.096-08:00</updated><title type='text'>[fw-server] Re: How to move app fron Zend Server CE to another LAMP?</title><content type='html'>thx a lot&lt;br&gt;everything works nice now&lt;br&gt;thx again&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-from-Zend-Server-CE-to-another-LAMP-tp3337679p3339236.html"&gt;http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-from-Zend-Server-CE-to-another-LAMP-tp3337679p3339236.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Server mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4031094285285225192?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4031094285285225192/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4031094285285225192' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4031094285285225192'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4031094285285225192'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-server-re-how-to-move-app-fron-zend_07.html' title='[fw-server] Re: How to move app fron Zend Server CE to another LAMP?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-7729256603745761519</id><published>2011-03-07T06:37:00.001-08:00</published><updated>2011-03-07T06:37:21.150-08:00</updated><title type='text'>Re: [fw-server] Re: How to move app fron Zend Server CE to another LAMP?</title><content type='html'>If you see default apache 404 page, then most likely mod_rewrite is not &lt;br&gt;configured properly.&lt;p&gt;regards&lt;br&gt;Petar&lt;p&gt;On 03/07/2011 03:48 PM, Mr.Kilmister wrote:&lt;br&gt;&amp;gt; Yes, it is,&lt;br&gt;&amp;gt; And even the website is launched, but only partly :(&lt;br&gt;&amp;gt; I have 4 elements:&lt;br&gt;&amp;gt; - paginator, to find data, it works fine&lt;br&gt;&amp;gt; - accordion, to find details, works good&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; but I also have a view helper:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; layout.phtml&lt;br&gt;&amp;gt; &amp;lt;?php echo $this-&amp;gt;login(); ?&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Login.php&lt;br&gt;&amp;gt; &amp;lt;?php&lt;br&gt;&amp;gt; class Application_View_Helper_Login extends Zend_View_Helper_Abstract&lt;br&gt;&amp;gt; {&lt;br&gt;&amp;gt;      public function login()&lt;br&gt;&amp;gt;      {&lt;br&gt;&amp;gt;          $output = null;&lt;br&gt;&amp;gt;          if (Zend_Auth::getInstance()-&amp;gt;hasIdentity()) {&lt;br&gt;&amp;gt;              $output = &amp;#39;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;                       &amp;quot;&amp;#39; . $this- view-&amp;gt;url(&lt;br&gt;&amp;gt;                          array(&lt;br&gt;&amp;gt;                              &amp;#39;controller&amp;#39; =&amp;gt;  &amp;#39;auth&amp;#39;,&lt;br&gt;&amp;gt;                              &amp;#39;action&amp;#39;     =&amp;gt;  &amp;#39;logout&amp;#39;&lt;br&gt;&amp;gt;                          ),&lt;br&gt;&amp;gt;                          &amp;#39;default&amp;#39;,&lt;br&gt;&amp;gt;                          true) . &amp;#39;&amp;quot;&amp;gt;logout&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;#39;;&lt;br&gt;&amp;gt;          } else {&lt;br&gt;&amp;gt;              $output = &amp;#39;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;                       &amp;quot;&amp;#39; . $this- view-&amp;gt;url(&lt;br&gt;&amp;gt;                          array(&lt;br&gt;&amp;gt;                              &amp;#39;controller&amp;#39; =&amp;gt;  &amp;#39;auth&amp;#39;,&lt;br&gt;&amp;gt;                              &amp;#39;action&amp;#39;     =&amp;gt;  &amp;#39;login&amp;#39;&lt;br&gt;&amp;gt;                          ),&lt;br&gt;&amp;gt;                          &amp;#39;default&amp;#39;,&lt;br&gt;&amp;gt;                          true) . &amp;#39;&amp;quot;&amp;gt;login&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;#39;;&lt;br&gt;&amp;gt;          }&lt;br&gt;&amp;gt;          return $output;&lt;br&gt;&amp;gt;      }&lt;br&gt;&amp;gt; }&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; It prints out an error:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Not Found&lt;br&gt;&amp;gt; The requested URL /auth/login was not found on this server.&lt;br&gt;&amp;gt; Apache/2.2.16 (Ubuntu) Server at 127.0.0.1 Port 80&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; (After login it will be the last part wiht ajax...)&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; What&amp;#39;s wrong?&lt;br&gt;&amp;gt; Could you help me, please?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-from-Zend-Server-CE-to-another-LAMP-tp3337679p3338993.html"&gt;http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-from-Zend-Server-CE-to-another-LAMP-tp3337679p3338993.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend Server mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-7729256603745761519?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/7729256603745761519/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=7729256603745761519' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7729256603745761519'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7729256603745761519'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-server-re-how-to-move-app-fron.html' title='Re: [fw-server] Re: How to move app fron Zend Server CE to another LAMP?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8209814674333760424</id><published>2011-03-07T05:48:00.000-08:00</published><updated>2011-03-07T06:04:04.283-08:00</updated><title type='text'>[fw-server] Re: How to move app fron Zend Server CE to another LAMP?</title><content type='html'>Yes, it is,&lt;br&gt;And even the website is launched, but only partly :(&lt;br&gt;I have 4 elements:&lt;br&gt;- paginator, to find data, it works fine&lt;br&gt;- accordion, to find details, works good&lt;p&gt;but I also have a view helper:&lt;p&gt;layout.phtml&lt;br&gt;&amp;lt;?php echo $this-&amp;gt;login(); ?&amp;gt;&lt;p&gt;Login.php&lt;br&gt;&amp;lt;?php&lt;br&gt;class Application_View_Helper_Login extends Zend_View_Helper_Abstract&lt;br&gt;{&lt;br&gt;    public function login()&lt;br&gt;    {&lt;br&gt;        $output = null;&lt;br&gt;        if (Zend_Auth::getInstance()-&amp;gt;hasIdentity()) {&lt;br&gt;            $output = &amp;#39;&lt;br&gt;                &lt;p&gt;                     &amp;quot;&amp;#39; . $this- view-&amp;gt;url(&lt;br&gt;                        array(&lt;br&gt;                            &amp;#39;controller&amp;#39; =&amp;gt; &amp;#39;auth&amp;#39;,&lt;br&gt;                            &amp;#39;action&amp;#39;     =&amp;gt; &amp;#39;logout&amp;#39;&lt;br&gt;                        ),&lt;br&gt;                        &amp;#39;default&amp;#39;,&lt;br&gt;                        true) . &amp;#39;&amp;quot;&amp;gt;logout &lt;br&gt;                &lt;br&gt;&amp;#39;;&lt;br&gt;        } else {&lt;br&gt;            $output = &amp;#39;&lt;br&gt;                &lt;p&gt;                     &amp;quot;&amp;#39; . $this- view-&amp;gt;url(&lt;br&gt;                        array(&lt;br&gt;                            &amp;#39;controller&amp;#39; =&amp;gt; &amp;#39;auth&amp;#39;,&lt;br&gt;                            &amp;#39;action&amp;#39;     =&amp;gt; &amp;#39;login&amp;#39;&lt;br&gt;                        ),&lt;br&gt;                        &amp;#39;default&amp;#39;,&lt;br&gt;                        true) . &amp;#39;&amp;quot;&amp;gt;login &lt;br&gt;                &lt;br&gt;&amp;#39;;&lt;br&gt;        }&lt;br&gt;        return $output;&lt;br&gt;    }&lt;br&gt;}&lt;p&gt;It prints out an error:&lt;p&gt;Not Found&lt;br&gt;The requested URL /auth/login was not found on this server.&lt;br&gt;Apache/2.2.16 (Ubuntu) Server at 127.0.0.1 Port 80&lt;p&gt;(After login it will be the last part wiht ajax...)&lt;p&gt;What&amp;#39;s wrong?&lt;br&gt;Could you help me, please?&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-from-Zend-Server-CE-to-another-LAMP-tp3337679p3338993.html"&gt;http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-from-Zend-Server-CE-to-another-LAMP-tp3337679p3338993.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Server mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8209814674333760424?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8209814674333760424/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8209814674333760424' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8209814674333760424'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8209814674333760424'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-server-re-how-to-move-app-fron-zend.html' title='[fw-server] Re: How to move app fron Zend Server CE to another LAMP?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1943573458750683599</id><published>2011-03-07T04:34:00.000-08:00</published><updated>2011-03-07T04:35:11.089-08:00</updated><title type='text'>Re: [fw-mvc] Zend framework ACL - newbie help needed</title><content type='html'>Hi all, &lt;br&gt;Sorry to bother but I didn&amp;#39;t receive a reply to the below - just wondering if &lt;br&gt;anyone can help me out? It is regarding Zend Acl and a simple method to learn &lt;br&gt;how to use this. &lt;p&gt;Matthew your reply is definitely useful but I am having trouble putting it all &lt;br&gt;together as explained in my latest reply below :( &lt;p&gt;Help!&lt;p&gt;Thanks,&lt;br&gt;Rishi&lt;p&gt;&lt;p&gt;&lt;br&gt;________________________________&lt;br&gt;From: Rishi Daryanani &amp;lt;&lt;a href="mailto:rishijd@yahoo.com"&gt;rishijd@yahoo.com&lt;/a&gt;&amp;gt;&lt;br&gt;To: Matthew Weier O&amp;#39;Phinney &amp;lt;&lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&amp;gt;; &lt;a href="mailto:fw-mvc@lists.zend.com"&gt;fw-mvc@lists.zend.com&lt;/a&gt;&lt;br&gt;Sent: Wed, March 2, 2011 7:20:02 PM&lt;br&gt;Subject: Re: [fw-mvc] Zend framework ACL - newbie help needed&lt;p&gt;Hi Matthew,&lt;p&gt;Thanks veyr much for your reply. I have a few questions, and we are having &lt;br&gt;trouble setting it up so I&amp;#39;ll write that here as well:&lt;p&gt;Regarding $identity in your example - this is using Zend Auth as you said. For &lt;br&gt;now, I don&amp;#39;t want to go into Zend Auth until I understand how to perform a &lt;br&gt;simple task on Zend Acl ;) Your examples have used $identity but if you think it &lt;p&gt;does simplify it please let me know, otherwise for now I am trying it without &lt;br&gt;the user of Zend Auth, as we are simply logging in the user with their username &lt;br&gt;+ user group ID (1, 2, or 3).&lt;br&gt;Further details:&lt;p&gt;* I was able to make the Zend_Acl object&lt;p&gt;But below parts are still unclear to me.&lt;br&gt;* Add roles to the Zend_Acl object&lt;br&gt;* Add resources to the Zend_Acl object&lt;br&gt;How can I match these roles with the currently existing users in my database? &lt;br&gt;For example I have following groups in my database.&lt;p&gt;1 Administrator&lt;br&gt;2 Regional Administrator&lt;br&gt;3 Content Manager&lt;p&gt;Basically, the above groups are &amp;quot;roles&amp;quot; . Administrator will have all privileges &lt;p&gt;in my CMS.&lt;p&gt;* Add resources to the Zend_Acl object&lt;br&gt;This is also not entirely clear to me. Should these be in the controller?&lt;br&gt;Eg-&lt;br&gt;&lt;a href="http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025#Zend_Acl%26MVCIntegration-AldemarBernal-4.DependenciesonOtherFrameworkComponents"&gt;http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025#Zend_Acl%26MVCIntegration-AldemarBernal-4.DependenciesonOtherFrameworkComponents&lt;/a&gt;&lt;p&gt;&lt;br&gt;$acl-&amp;gt;add(new Zend_Acl_Resource(&amp;#39;news&amp;#39;))  (is &amp;quot;news&amp;quot; a controller? In where are &lt;br&gt;we defining the behavior of the $acl-&amp;gt;add()? Is this inbuilt?)&lt;p&gt;Below is the the code I&amp;#39;m currently using. In the bootstrap.php :&lt;p&gt;Helper - library/My/Controller/Helper/&lt;br&gt;Plugin - library/My/Controller/Plugin/&lt;p&gt;/** Creating the ACL object */&lt;br&gt;require_once &amp;#39;Zend/Acl.php&amp;#39;;&lt;br&gt;$acl = new Zend_Acl();&lt;p&gt;/** Creating the Role object */&lt;br&gt;require_once &amp;#39;Zend/Acl/Role.php&amp;#39;;&lt;br&gt;$acl-&amp;gt;addRole(new Zend_Acl_Role(&amp;#39;staff&amp;#39;));&lt;br&gt;$acl-&amp;gt;addRole(new Zend_Acl_Role(&amp;#39;member&amp;#39;)); &lt;p&gt;&lt;br&gt;/**&lt;br&gt;* Creating resources:&lt;br&gt;*  - News Controller&lt;br&gt;* Creating privileges:&lt;br&gt;*  - Allow defaultRole to access news controller&lt;br&gt;*  - Deny defaultRole to access add action of news controller&lt;br&gt;*/&lt;br&gt;require_once &amp;#39;Zend/Acl/Resource.php&amp;#39;;&lt;br&gt;$acl-&amp;gt;add(new Zend_Acl_Resource(&amp;#39;admin&amp;#39;))&lt;br&gt;    -&amp;gt;allow(&amp;#39;staff&amp;#39;, &amp;#39;admin&amp;#39;)&lt;br&gt;    -&amp;gt;deny(&amp;#39;staff&amp;#39;, &amp;#39;admin&amp;#39;, &amp;#39;reports&amp;#39;);&lt;p&gt;&lt;br&gt;/** Registering the Plugin object */&lt;br&gt;//require_once &amp;#39;Zend/Controller/Plugin/Acl.php&amp;#39;;&lt;br&gt;//$front-&amp;gt;registerPlugin(new Zend_Controller_Plugin_Acl($acl));&lt;p&gt;&lt;br&gt;/* OK, do your stuff, front controller */&lt;br&gt;$frontController-&amp;gt;dispatch();&lt;p&gt;&lt;br&gt;I realise I need to go through the above again, but I&amp;#39;d like to post out a few &lt;br&gt;questions:&lt;p&gt;i) Are &amp;quot;plugin&amp;quot; files required? The link above mentions that we should upload a &lt;br&gt;certain ACL plugin + helper. Other tutorials mention this too. Is this correct?&lt;p&gt;ii) Because my boot strap has routes for the CMS (&amp;quot;AdminController&amp;quot;) and front &lt;br&gt;end (&amp;quot;IndexController&amp;quot;), can I only define roles and resources within my CMS / &lt;br&gt;AdminController? Or must this kind of code be in the bootstrap.php file?&lt;p&gt;iii) I understand the concept - that a &amp;#39;resource&amp;#39; (say, the reporting module in &lt;br&gt;the CMS) needs to be defined. A bunch of &amp;#39;roles&amp;#39; also would be defined, i.e. &lt;br&gt;user groups (&amp;quot;AdministratorRole&amp;quot; would get all rights, and &amp;quot;ContentManagerRole&amp;quot; &lt;br&gt;would get a few rights).&lt;br&gt;Then, when I am actually at the controller action for my &amp;#39;reporting module&amp;#39; for &lt;br&gt;example, what code do I put in to tell ZF that &amp;quot;we are in the reporting module &lt;br&gt;resource, so check the logged in user&amp;#39;s rights and grant access if permitted&amp;quot;?&lt;p&gt;Many thanks,&lt;br&gt;Rishi&lt;p&gt;&lt;p&gt;&lt;br&gt;________________________________&lt;br&gt;From: Matthew Weier O&amp;#39;Phinney &amp;lt;&lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&amp;gt;&lt;br&gt;To: &lt;a href="mailto:fw-mvc@lists.zend.com"&gt;fw-mvc@lists.zend.com&lt;/a&gt;&lt;br&gt;Sent: Mon, February 28, 2011 10:07:18 PM&lt;br&gt;Subject: Re: [fw-mvc] Zend framework ACL - newbie help needed&lt;p&gt;-- Rishi Daryanani &amp;lt;&lt;a href="mailto:rishijd@yahoo.com"&gt;rishijd@yahoo.com&lt;/a&gt;&amp;gt; wrote&lt;br&gt;(on Monday, 28 February 2011, 06:06 AM -0800):&lt;br&gt;&amp;gt; I&amp;#39;m very new to ACL and it&amp;#39;s not something we&amp;#39;ve tried below. Any guidance &lt;br&gt;&amp;gt;would &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; be appreciated; I&amp;#39;m going to start with code experimentation but would like to &lt;p&gt;&lt;br&gt;&amp;gt; know if I&amp;#39;m on the right track.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; We are using a custom developed CMS which is using ZF&amp;quot;, and we have our front &lt;br&gt;&amp;gt; end website as well. The CMS uses a controller called &amp;quot;AdminController&amp;quot;, and &lt;br&gt;&amp;gt;the &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; front end only uses a controller called &amp;quot;IndexController&amp;quot;. I want to introduce &lt;p&gt;&lt;br&gt;&amp;gt; access control to this CMS. Therefore some user groups will be restricted to &lt;br&gt;&amp;gt; some areas of the CMS.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; Current potential solution :&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; I&amp;#39;m thinking of achieving this functionality as described below.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; 1. Have  a database table to store the type of the user.&lt;br&gt;&amp;gt; 2. Have a separate table to store the pages the user is allowed or not allowed. &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; 3. Check in each page whether the user have the access or not and display the &lt;br&gt;&amp;gt; page accordingly.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; Which is the best way to implement this using Zend framework? &amp;quot;Zend_Auth&amp;quot; or &lt;br&gt;&amp;gt; &amp;quot;Zend_Acl&amp;quot; ? &lt;p&gt;Zend_Auth is used for authentication of a user; i.e., evaluating the&lt;br&gt;provided credentials to determine identity.&lt;p&gt;Zend_Acl is used for authorization; i.e., to determine whether a given&lt;br&gt;user has the rights to access a given resource.&lt;p&gt;What you describe above is the realm of Zend_Acl.&lt;p&gt;&amp;gt; I have looked in to the &amp;quot;Zend_Acl&amp;quot; and it sounds good, however &lt;br&gt;&amp;gt; could someone guide me - what is the procedure for implementing this? Here are &lt;p&gt;&lt;br&gt;&amp;gt; the links I found:&lt;br&gt;&amp;gt; &lt;a href="http://framework.zend.com/manual/en/zend.acl.introduction.html"&gt;http://framework.zend.com/manual/en/zend.acl.introduction.html&lt;/a&gt; &lt;br&gt;&amp;gt; &lt;a href="http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025"&gt;http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025&lt;/a&gt; &lt;p&gt;The basic workflow is:&lt;p&gt;* Create a Zend_Acl object&lt;br&gt;* Add roles to the Zend_Acl object&lt;br&gt;* Add resources to the Zend_Acl object&lt;br&gt;* Create the permissions&lt;p&gt;Now, that said, there are a variety of ways to do this. You can do it&lt;br&gt;up-front -- i.e., define all roles, resources, and permissions in a&lt;br&gt;given object or in your bootstrap. If you have only a handful of ACLs to&lt;br&gt;create, this is a straight-forward approach.&lt;p&gt;Another approach is to add them as you need them.&lt;p&gt;As an example, when you grab the user identity during login or later&lt;br&gt;from the Zend_Auth session container, you might include the role in the&lt;br&gt;identity information. You can then add this to the ACL as you grab it:&lt;p&gt;    $acl-&amp;gt;addRole($identity-&amp;gt;role);&lt;p&gt;You could also define an array of roles, and then one master role for&lt;br&gt;the user (which would indicate the user inherits all of those roles):&lt;p&gt;    foreach ($identity-&amp;gt;roles as $role) {&lt;br&gt;        $acl-&amp;gt;addRole($role);&lt;br&gt;    }&lt;br&gt;    $acl-&amp;gt;addRole($identity-&amp;gt;username, $identity-&amp;gt;roles);&lt;p&gt;Later, when you grab your page, you might also include ACL information&lt;br&gt;in the page metadata. This allows you to setup the resource and&lt;br&gt;permissions ad-hoc. As an example, let&amp;#39;s assume that a &amp;quot;page&amp;quot; object&lt;br&gt;might have the following in its structure:&lt;p&gt;    public $identifier;&lt;br&gt;    public $roles = array(&lt;br&gt;        array(&amp;#39;role&amp;#39; =&amp;gt; array(&amp;#39;read&amp;#39;, &amp;#39;write&amp;#39;))&lt;br&gt;    );&lt;p&gt;    $acl-&amp;gt;addResource($page-&amp;gt;identifier);&lt;br&gt;    foreach ($page-&amp;gt;roles as $role =&amp;gt; $rights) {&lt;br&gt;        if (!$acl-&amp;gt;hasRole($role)) {&lt;br&gt;            $acl-&amp;gt;addRole($role);&lt;br&gt;        }&lt;br&gt;        $acl-&amp;gt;allow($role, $page-&amp;gt;identifier, $rights);&lt;br&gt;    }&lt;p&gt;Then, you can test right there and then:&lt;p&gt;    if (!$acl-&amp;gt;isAllowed($identity-&amp;gt;role, $page-&amp;gt;identifier, $currentPrivilege)) &lt;p&gt;{&lt;br&gt;        throw new AclException;&lt;br&gt;    }&lt;p&gt;This allows you some flexibility -- you don&amp;#39;t have to define all ACLs up&lt;br&gt;front, and can grow the graph as your content grows. That said, it can&lt;br&gt;get tricky if you want to introduce role inheritance, so you have to&lt;br&gt;setup a strict convention of how the roles are stored.&lt;p&gt;Hope that helps get you started!&lt;p&gt;&amp;gt; The gist of my understanding is:&lt;br&gt;&amp;gt; - In the AdminController (or is it bootstrap.php) I have to define a set of &lt;br&gt;&amp;gt; Roles and Resources that are accessed/denied for those roles. This follows the &lt;p&gt;&lt;br&gt;&amp;gt; above tutorial example. In my case, I need to add a new user role called &amp;quot;staff &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; user&amp;quot; who will just have access to one function in the CMS, a basic &amp;quot;customer &lt;br&gt;&amp;gt; lookup&amp;quot; reporting function.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; - However I also need to check (in the &amp;quot;customer lookup&amp;quot; function) if the &lt;br&gt;&amp;gt; logged-in user has access rights to view this page. In all other pages, I need &lt;p&gt;&lt;br&gt;&amp;gt; to DENY access rights actually, if the logged in user is a &amp;quot;staff user&amp;quot;. Is &lt;br&gt;&amp;gt; there a tutorial like this which explains it for newbies? Or could someone &lt;br&gt;&amp;gt;guide &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; me on what kind of code goes where? &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I&amp;#39;m not sure how I can tell ZF the name of the resource of each &lt;br&gt;&amp;gt;section/function &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; of the CMS. For example, if I have a section called &amp;quot;Reports&amp;quot;, and functions &lt;br&gt;&amp;gt; called&lt;br&gt;&amp;gt; - &amp;quot;Customer Lookup&amp;quot;&lt;br&gt;&amp;gt; - &amp;quot;Orders report&amp;quot;&lt;br&gt;&amp;gt; - &amp;quot;Members report&amp;quot;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; then what code would I put in for each of the above controller functions to &lt;br&gt;&amp;gt; assign a resource name and possibly a module/sub-resource name to each &lt;br&gt;&amp;gt;function?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Many thanks,&lt;br&gt;&amp;gt; Rishi&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;      &lt;p&gt;-- &lt;br&gt;Matthew Weier O&amp;#39;Phinney&lt;br&gt;Project Lead            | &lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&lt;br&gt;Zend Framework          | &lt;a href="http://framework.zend.com/"&gt;http://framework.zend.com/&lt;/a&gt;&lt;br&gt;PGP key: &lt;a href="http://framework.zend.com/zf-matthew-pgp-key.asc"&gt;http://framework.zend.com/zf-matthew-pgp-key.asc&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1943573458750683599?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1943573458750683599/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1943573458750683599' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1943573458750683599'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1943573458750683599'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-mvc-zend-framework-acl-newbie_07.html' title='Re: [fw-mvc] Zend framework ACL - newbie help needed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6729588467690037822</id><published>2011-03-07T00:43:00.001-08:00</published><updated>2011-03-07T00:43:44.530-08:00</updated><title type='text'>Re: [fw-server] How to move app fron Zend Server CE to another LAMP?</title><content type='html'>Hi is Zend folder within library folder on the Ubuntu server?&lt;p&gt;On 03/06/2011 05:20 PM, Mr.Kilmister wrote:&lt;br&gt;&amp;gt; Hi Zenders!&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I&amp;#39;ve just finished my first application. I wrote it on a Kubuntu with&lt;br&gt;&amp;gt; installed Zend Server CE. I have a second server, Ubuntu, where the&lt;br&gt;&amp;gt; application must be ultimately found. This Ubuntu is a pure, clean LAMP,&lt;br&gt;&amp;gt; Zend was never there.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I copied /usr/local/Zend/share/ZendFramework/library/* to the application&lt;br&gt;&amp;gt; directory.&lt;br&gt;&amp;gt; Then I threw the entire application directory into /var/www on Ubuntu.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I hope Ubuntu see Zend library...:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; print_r(inlude_path):&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; /var/www/[my-app]/application/../library:/var/www/[my-app]/library:./usr/share/php:/usr/&lt;br&gt;&amp;gt; share/pear&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; but nothing work:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;quot;An error occurred&lt;br&gt;&amp;gt; Application error&amp;quot;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; What&amp;#39;s wrong?&lt;br&gt;&amp;gt; Could you help me, please?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-fron-Zend-Server-CE-to-another-LAMP-tp3337679p3337679.html"&gt;http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-fron-Zend-Server-CE-to-another-LAMP-tp3337679p3337679.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend Server mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6729588467690037822?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6729588467690037822/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6729588467690037822' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6729588467690037822'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6729588467690037822'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-server-how-to-move-app-fron-zend.html' title='Re: [fw-server] How to move app fron Zend Server CE to another LAMP?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1664261416078609364</id><published>2011-03-06T07:47:00.001-08:00</published><updated>2011-03-06T07:47:26.236-08:00</updated><title type='text'>[fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default</title><content type='html'>The way I usually handle this:&lt;br&gt;- I register a Layout Plugin, extending Zend_Layout_Controller_Plugin_Layout&lt;br&gt;- I use the preDispatch hook to determine what module, controller, action I&lt;br&gt;am in&lt;br&gt;- I switch between layouts and views depending on the context&lt;p&gt;For me, that&amp;#39;s by far the easiest method.&lt;br&gt;GJ&lt;p&gt;&lt;br&gt;Xerkus wrote:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; May be this can be useful to you:&lt;br&gt;&amp;gt; &lt;a href="http://stackoverflow.com/q/5210475/605093"&gt;http://stackoverflow.com/q/5210475/605093&lt;/a&gt;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I need to test this idea in real application though.&lt;br&gt;&amp;gt; &lt;p&gt;&lt;br&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3337702.html"&gt;http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3337702.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1664261416078609364?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1664261416078609364/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1664261416078609364' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1664261416078609364'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1664261416078609364'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-mvc-re-troubles-with-custom-view_6642.html' title='[fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2894840722176060883</id><published>2011-03-06T07:20:00.000-08:00</published><updated>2011-03-06T13:40:23.884-08:00</updated><title type='text'>[fw-server] How to move app fron Zend Server CE to another LAMP?</title><content type='html'>Hi Zenders!&lt;p&gt;I&amp;#39;ve just finished my first application. I wrote it on a Kubuntu with&lt;br&gt;installed Zend Server CE. I have a second server, Ubuntu, where the&lt;br&gt;application must be ultimately found. This Ubuntu is a pure, clean LAMP,&lt;br&gt;Zend was never there.&lt;p&gt;I copied /usr/local/Zend/share/ZendFramework/library/* to the application&lt;br&gt;directory.&lt;br&gt;Then I threw the entire application directory into /var/www on Ubuntu.&lt;p&gt;I hope Ubuntu see Zend library...:&lt;p&gt;print_r(inlude_path):&lt;p&gt;/var/www/[my-app]/application/../library:/var/www/[my-app]/library:./usr/share/php:/usr/&lt;br&gt;share/pear&lt;p&gt;but nothing work:&lt;p&gt;&amp;quot;An error occurred&lt;br&gt;Application error&amp;quot;&lt;p&gt;What&amp;#39;s wrong?&lt;br&gt;Could you help me, please?&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-fron-Zend-Server-CE-to-another-LAMP-tp3337679p3337679.html"&gt;http://zend-framework-community.634137.n4.nabble.com/How-to-move-app-fron-Zend-Server-CE-to-another-LAMP-tp3337679p3337679.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Server mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2894840722176060883?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2894840722176060883/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2894840722176060883' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2894840722176060883'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2894840722176060883'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-server-how-to-move-app-fron-zend.html' title='[fw-server] How to move app fron Zend Server CE to another LAMP?'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1927928915479041221</id><published>2011-03-06T06:05:00.000-08:00</published><updated>2011-03-06T07:20:16.532-08:00</updated><title type='text'>[fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default</title><content type='html'>May be this can be useful to you:&lt;br&gt;&lt;a href="http://stackoverflow.com/q/5210475/605093"&gt;http://stackoverflow.com/q/5210475/605093&lt;/a&gt;&lt;p&gt;I need to test this idea in real application though.&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3337615.html"&gt;http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3337615.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1927928915479041221?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1927928915479041221/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1927928915479041221' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1927928915479041221'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1927928915479041221'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-mvc-re-troubles-with-custom-view_06.html' title='[fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3349202548644542110</id><published>2011-03-05T11:51:00.001-08:00</published><updated>2011-03-05T11:51:50.321-08:00</updated><title type='text'>Re: [fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default</title><content type='html'>On Sat, Mar 5, 2011 at 2:11 AM, jonnott &amp;lt;&lt;a href="mailto:jonnott@gmail.com"&gt;jonnott@gmail.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt; Is there another way to state this setting globally without using an&lt;br&gt;&amp;gt; INI file? The problem is that I need to generate this path *dynamically*, as&lt;br&gt;&amp;gt; the ZF entry-point is within a shared codebase.&lt;p&gt;&lt;br&gt;Yes, you can bootstrap your view instance and then pull it from the&lt;br&gt;bootstrap to modify it. This ensures that you are accessing and modifying&lt;br&gt;the same view instance throughout your application.&lt;p&gt;To make sure your view is bootstrapped, add at least one configuration&lt;br&gt;option to application.ini. If you want to use all the defaults, then pass in&lt;br&gt;an empty config:&lt;p&gt;# application/configs/application.ini&lt;br&gt;; Bootstraps the view with default values&lt;br&gt;resources.view[] =&lt;p&gt;Then, you can pull the view from the bootstrap from within an action&lt;br&gt;controller like this:&lt;p&gt;# application/controllers/IndexController.php&lt;br&gt;public function init()&lt;br&gt;{&lt;br&gt;    $bootstrap = $this-&amp;gt;getInvokeArg(&amp;#39;bootstrap&amp;#39;);&lt;br&gt;    $view = $bootstrap-&amp;gt;getResource(&amp;#39;view&amp;#39;);&lt;br&gt;}&lt;p&gt;&amp;gt;From that point you can then add your custom view script paths:&lt;p&gt;$view-&amp;gt;addScriptPath(&amp;#39;path/to/my/view/scripts&amp;#39;);&lt;p&gt;Would this work at the Zend_Controller_Action::preDispatch() level, or&lt;br&gt;&amp;gt; is that too late? (assuming the above would normally be in the front&lt;br&gt;&amp;gt; controller plugin routeShutdown() method).&lt;p&gt;&lt;br&gt;Automatic view script rendering occurs during postDispatch, so swapping&lt;br&gt;paths in preDispatch or even within your action body should work. In my&lt;br&gt;example above I used init, which occurs before preDispatch.&lt;p&gt;My thinking would be to create a base action controller with this in&lt;br&gt;&amp;gt; preDispatch() which I can subclass for whatever action controllers need this&lt;br&gt;&amp;gt; logic.&lt;p&gt;&lt;br&gt;If you find that you need to provide this functionality in more than one&lt;br&gt;action controller, I suggest using action helpers instead of creating a base&lt;br&gt;action controller. The problem with base action controllers is that they&lt;br&gt;tend to get bloated with some functionality for controllers A, B, and C and&lt;br&gt;other functionality for controllers D, E, and F. Maintaing this can become&lt;br&gt;problematic and often requires a large ugly switch.&lt;p&gt;Action helpers allow you to take that bit of functionality and encapsulate&lt;br&gt;it in its own class, allowing you to use it on-demand from any action&lt;br&gt;controller.&lt;p&gt;For more info on action helpers check out the docs:&lt;p&gt;&lt;a href="http://framework.zend.com/manual/en/zend.controller.actionhelpers.html"&gt;http://framework.zend.com/manual/en/zend.controller.actionhelpers.html&lt;/a&gt;&lt;p&gt;Will this work just as well with inverted logic/booleans,&lt;br&gt;&amp;gt; i.e. Zend_Controller_Front-&amp;gt;setParam(&amp;#39;noViewRenderer&amp;#39;)=true; and&lt;br&gt;&amp;gt; then $viewRenderer-&amp;gt;setNoRender(false); in the routeShutdown() or&lt;br&gt;&amp;gt; action controller preDispatch()&lt;p&gt;&lt;br&gt;Setting the param &amp;quot;noViewRenderer&amp;quot; to true prevents the front controller&lt;br&gt;from registering the view renderer helper entirely, but in your case I&lt;br&gt;believe you want it registered but simply not performing any automatic view&lt;br&gt;script rendering.&lt;p&gt;So I would go with my original suggestion of leaving the view renderer there&lt;br&gt;(because you might need it), disabling automatic view rendering (a property&lt;br&gt;of the view renderer itself), and then re-enabling it when required.&lt;p&gt;--&lt;br&gt;*Hector Virgen*&lt;br&gt;Sr. Web Developer&lt;br&gt;&lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3349202548644542110?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3349202548644542110/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3349202548644542110' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3349202548644542110'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3349202548644542110'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-mvc-re-troubles-with-custom-view.html' title='Re: [fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6601621114366620255</id><published>2011-03-05T02:11:00.000-08:00</published><updated>2011-03-05T02:12:03.172-08:00</updated><title type='text'>[fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default</title><content type='html'>Thanks Hector. Couple of further questions..&lt;p&gt;&lt;br&gt;Hector Virgen wrote:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; resources.view.basePath = APPLICATION_PATH &amp;quot;/custom/path/to/views/&amp;quot;&lt;br&gt;&amp;gt; &lt;p&gt;Is there another way to state this setting globally without using an INI&lt;br&gt;file? The problem is that I need to generate this path *dynamically*, as the&lt;br&gt;ZF entry-point is within a shared codebase.&lt;p&gt;&lt;br&gt;Hector Virgen wrote:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; $viewRenderer =&lt;br&gt;&amp;gt; Zend_Controller_Action_HelperBroker::getStaticHelper(&amp;#39;viewRenderer&amp;#39;);&lt;br&gt;&amp;gt; $viewRenderer-&amp;gt;setNoRender(true); // disable view rendering&lt;br&gt;&amp;gt; &lt;p&gt;Questions on this would be:&lt;p&gt;- Would this work at the Zend_Controller_Action::preDispatch() level, or is&lt;br&gt;that too late? (assuming the above would normally be in the front controller&lt;br&gt;plugin routeShutdown() method). My thinking would be to create a base action&lt;br&gt;controller with this in preDispatch() which I can subclass for whatever&lt;br&gt;action controllers need this logic.&lt;p&gt;- Will this work just as well with inverted logic/booleans, i.e.&lt;br&gt;Zend_Controller_Front-&amp;gt;setParam(&amp;#39;noViewRenderer&amp;#39;)=true; and then&lt;br&gt;$viewRenderer-&amp;gt;setNoRender(false); in the routeShutdown() or action&lt;br&gt;controller preDispatch() ??&lt;p&gt;Jonny&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3336467.html"&gt;http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3336467.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6601621114366620255?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6601621114366620255/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6601621114366620255' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6601621114366620255'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6601621114366620255'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-mvc-re-troubles-with-custom-view.html' title='[fw-mvc] Re: troubles with custom view-scripts location and noViewRender=true by default'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8657899184468582292</id><published>2011-03-04T16:44:00.000-08:00</published><updated>2011-03-04T15:44:43.092-08:00</updated><title type='text'>[fw-webservices] Zend_Soap_AutoDiscover bug</title><content type='html'>Hi:&lt;p&gt; &lt;p&gt;I&amp;#39;m traying to publish a WSDL-based WebService using Zend_Soap_AutoDiscover,&lt;br&gt;I&amp;#39;ve made my own class and managed the requests for making all works well&lt;br&gt;but when I&amp;#39;m trying to use this WS from another PHP application I receive&lt;br&gt;this error: &amp;quot;SOAP-ERROR: Parsing WSDL: Couldn&amp;#39;t load from&lt;br&gt;&amp;#39;&lt;a href="http://localhost/architecture/applications/security/public/ws/Security.php"&gt;http://localhost/architecture/applications/security/public/ws/Security.php&lt;/a&gt;?&lt;br&gt;wsdl&amp;#39; : Extra content at the end of the document&amp;quot;. The most estrange part is&lt;br&gt;its only happens in Windows platform because I&amp;#39;ve tested the same code in&lt;br&gt;Ubuntu Server and works as I expect.&lt;p&gt; &lt;p&gt;Excuse me for my English.&lt;p&gt; &lt;p&gt;Regards&lt;p&gt;Omar&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8657899184468582292?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8657899184468582292/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8657899184468582292' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8657899184468582292'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8657899184468582292'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-webservices-zendsoapautodiscover-bug.html' title='[fw-webservices] Zend_Soap_AutoDiscover bug'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6455204702862559869</id><published>2011-03-04T10:17:00.001-08:00</published><updated>2011-03-04T10:17:55.581-08:00</updated><title type='text'>Re: [fw-mvc] troubles with custom view-scripts location and noViewRender=true by default</title><content type='html'>I would approach this problem differently:&lt;p&gt;1) Use application.ini to set up your custom view script path&lt;p&gt;resources.view.basePath = APPLICATION_PATH &amp;quot;/custom/path/to/views/&amp;quot;&lt;p&gt;2) Use the plugin to disable the view renderer as necessary&lt;p&gt;$viewRenderer =&lt;br&gt;Zend_Controller_Action_HelperBroker::getStaticHelper(&amp;#39;viewRenderer&amp;#39;);&lt;br&gt;$viewRenderer-&amp;gt;setNoRender(true); // disable view rendering&lt;p&gt;Then you can wrap that in your logic to decide whether views should be&lt;br&gt;rendered.&lt;p&gt;I hope this helps.&lt;p&gt;--&lt;br&gt;*Hector Virgen*&lt;br&gt;Sr. Web Developer&lt;br&gt;&lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6455204702862559869?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6455204702862559869/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6455204702862559869' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6455204702862559869'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6455204702862559869'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-mvc-troubles-with-custom-view.html' title='Re: [fw-mvc] troubles with custom view-scripts location and noViewRender=true by default'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-323992723007619623</id><published>2011-03-04T09:40:00.001-08:00</published><updated>2011-03-04T09:40:35.802-08:00</updated><title type='text'>[fw-mvc] troubles with custom view-scripts location and noViewRender=true by default</title><content type='html'>Been having a nightmare trying to use a completely custom view scripts&lt;br&gt;location, combined with having noViewRenderer=true by default in&lt;br&gt;Zend_Controller_Front, but then switching it on for certain action&lt;br&gt;controllers via a routeShutdown plugin hook.&lt;p&gt;I&amp;#39;m know the noViewRenderer param gets passed through to the dispatcher,&lt;br&gt;hence toggling it at the routeShutdown stage. I can test at various other&lt;br&gt;points below the dispatcher (i.e. in the action controller) that if I&amp;#39;ve set&lt;br&gt;noViewRenderer=false, this appears to persist down to the action controller&lt;br&gt;level.&lt;p&gt;I want to set a completely custom path to my view scripts, so I can&amp;#39;t use&lt;br&gt;the default view scenario which gets set up by the viewRenderer action&lt;br&gt;helper, as it seems to test for the presence of a view scripts folder&lt;br&gt;according to the &amp;#39;stock&amp;#39; folder structure.&lt;p&gt;So I tied replacing the initView() method of my action controller thus:&lt;p&gt;public function initView () {&lt;p&gt;		$this-&amp;gt;view = new Zend_View(array(&amp;#39;basePath&amp;#39; =&amp;gt; APPLICATION_PATH .&lt;br&gt;&amp;#39;/custom/path/to/views/&amp;#39;));&lt;br&gt;		&lt;br&gt;		$viewRenderer = new Zend_Controller_Action_Helper_ViewRenderer($view);&lt;br&gt;		$this-&amp;gt;_helper-&amp;gt;addHelper($viewRenderer); // even slightly on track?!?!&lt;br&gt;		&lt;br&gt;		return $this-&amp;gt;view;&lt;br&gt;}&lt;p&gt;I&amp;#39;m then trying all sorts in my action method to try and get the view&lt;br&gt;working. I can get the view scripts loaded and rendered no problem. But&lt;br&gt;whatever I try, the view object that my view script sees somehow doesn&amp;#39;t&lt;br&gt;have any of the vars I&amp;#39;ve assigned it in the controller - i.e. it looks to&lt;br&gt;be a different view object altogether..&lt;p&gt;public function indexAction () {&lt;p&gt;		$this-&amp;gt;initView(); // tried both with and without this, in various&lt;br&gt;permutations&lt;br&gt;		$this-&amp;gt;view-&amp;gt;myvar = &amp;#39;hello world&amp;#39;;&lt;p&gt;		$this-&amp;gt;view-&amp;gt;render(&amp;#39;somescript&amp;#39;); // tried this, with or without .phtml&lt;br&gt;// OR&lt;br&gt;		$this-&amp;gt;render(); // ..also tried this&lt;br&gt;}&lt;p&gt;The direct Zend_Controller_Action::render() version seems to use code within&lt;br&gt;the viewRenderer helper to work out what view script it should load, and&lt;br&gt;whether it exists or not. Conversely, the $this-&amp;gt;view-&amp;gt;render() approach&lt;br&gt;uses the view object&amp;#39;s native methods to do the same. Neither is playing&lt;br&gt;ball for me it would seem. Things might go wrong within the ::_script()&lt;br&gt;private method of the Zend_View_Abstract class from my extensive&lt;br&gt;problem-hunting (stab in the dark) investigations.&lt;p&gt;Can anyone help?&lt;p&gt;I basically want to:&lt;p&gt;- have noViewRenderer=true (M &amp;amp; C, but no V) by default, but for selected&lt;br&gt;actions/controllers I need to use a view and view scripts&lt;br&gt;- have completely custom paths to where my view scripts are located in my&lt;br&gt;bespoke folder structure&lt;p&gt;...can it be that hard?&lt;p&gt;Jon&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3335661.html"&gt;http://zend-framework-community.634137.n4.nabble.com/troubles-with-custom-view-scripts-location-and-noViewRender-true-by-default-tp3335661p3335661.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-323992723007619623?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/323992723007619623/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=323992723007619623' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/323992723007619623'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/323992723007619623'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-mvc-troubles-with-custom-view.html' title='[fw-mvc] troubles with custom view-scripts location and noViewRender=true by default'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-48315820505030126</id><published>2011-03-04T03:36:00.000-08:00</published><updated>2011-03-04T07:11:19.504-08:00</updated><title type='text'>[fw-mvc] Zend/JQuery collapsible fieldset</title><content type='html'>Hello,&lt;br&gt;I&amp;#39;m experimenting a weird behaviour of my Zend/Jquery built form,&lt;br&gt;I have built a complete form with zend, I set up fielset groups and would&lt;br&gt;like now to make them collapsible with jQuery. I did it already with a&lt;br&gt;normal html file and because of my lack of skills about zendframework, I&lt;br&gt;tried to follow the same &amp;quot;spirit&amp;quot; on the zend form. &lt;br&gt;Basically the problem is that the fieldset always toggles down and not up.&lt;br&gt;It works when I use the jQuery &amp;quot;hide&amp;quot; function which sets the display&lt;br&gt;property to &amp;quot;none&amp;quot; but doesn&amp;#39;t when it uses a jQuery method playing with the&lt;br&gt;css in cache.&lt;br&gt;I know there would probably be a smarter to implement this feature with zend&lt;br&gt;and you are very welcome if you point it to me :)&lt;p&gt;but here are the basic codes :&lt;p&gt;[url=&lt;a href="http://www.hiboox.fr/go/images/informatique/untitled,0f51c660ec65f7fb5e87f5863695c0e5.jpg.html][img]http://free0.hiboox.com/images/0911/0f51c660ec65f7fb5e87f5863695c0e5.jpg[/img][/url"&gt;http://www.hiboox.fr/go/images/informatique/untitled,0f51c660ec65f7fb5e87f5863695c0e5.jpg.html][img]http://free0.hiboox.com/images/0911/0f51c660ec65f7fb5e87f5863695c0e5.jpg[/img][/url&lt;/a&gt;]&lt;p&gt;the layout :&lt;p&gt;[code]&lt;br&gt;    &amp;lt;?php echo $this-&amp;gt;headMeta(); ?&amp;gt;&lt;br&gt;    &amp;lt;?php echo $this-&amp;gt;headTitle(); ?&amp;gt;&lt;br&gt;    &amp;lt;?php echo&lt;br&gt;$this-&amp;gt;headLink()-&amp;gt;prependStylesheet($this-&amp;gt;baseUrl().&amp;#39;/css/site.css&amp;#39;); ?&amp;gt;&lt;br&gt;    &amp;lt;?php echo&lt;br&gt;$this-&amp;gt;headLink()-&amp;gt;prependStylesheet($this-&amp;gt;baseUrl().&amp;#39;/css/jquery.fancybox-1.3.4.css&amp;#39;);&lt;br&gt;?&amp;gt;&lt;br&gt;    &amp;lt;?php $this-&amp;gt;jQuery()-&amp;gt;enable();&lt;br&gt;		  echo $this-&amp;gt;jQuery();?&amp;gt;&lt;br&gt;	&amp;lt;?php echo&lt;br&gt;$this-&amp;gt;headScript()-&amp;gt;appendFile($this-&amp;gt;baseUrl().&amp;#39;/scripts/jquery.fancybox-1.3.4.pack.js&amp;#39;)?&amp;gt;&lt;br&gt;	&amp;lt;?php echo&lt;br&gt;$this-&amp;gt;headScript()-&amp;gt;appendFile($this-&amp;gt;baseUrl().&amp;#39;/scripts/collapsible.js&amp;#39;)?&amp;gt;&lt;p&gt;&lt;p&gt;&lt;p&gt;&lt;br&gt;    &lt;p&gt;        &lt;br&gt;&amp;lt;?php echo $this-&amp;gt;escape($this-&amp;gt;title); ?&amp;gt;&lt;p&gt;        &amp;lt;?php echo $this-&amp;gt;layout()-&amp;gt;content; ?&amp;gt;&lt;br&gt;    &lt;p&gt;&lt;p&gt;[/code]  &lt;p&gt;the function : &lt;br&gt;[code]$.fn.collapsible = function ()&lt;br&gt;{&lt;br&gt;  &lt;br&gt;  //toggle the component with class msg_body&lt;br&gt;  $(&amp;quot;#msg_head&amp;quot;).click(function()&lt;br&gt;  {&lt;br&gt;    //var arrow = this.getElementsByTagName(&amp;quot;img&amp;quot;);&lt;br&gt;	if ($(this).hasClass(&amp;#39;msg_head_collapsed&amp;#39;)){&lt;br&gt;				$(this).removeClass(&amp;#39;msg_head_collapsed&amp;#39;).addClass(&amp;#39;msg_head&amp;#39;);&lt;br&gt;				//arrow[0].src = &amp;quot;images/arrow_down.png&amp;quot;;&lt;br&gt;				&lt;br&gt;	}&lt;br&gt;	else if ($(this).hasClass(&amp;#39;msg_head&amp;#39;)){&lt;br&gt;				$(this).removeClass(&amp;#39;msg_head&amp;#39;).addClass(&amp;#39;msg_head_collapsed&amp;#39;);&lt;br&gt;				//arrow[0].src = &amp;quot;images/arrow_right.png&amp;quot;;&lt;br&gt;				&lt;br&gt;	}	&lt;br&gt;	&lt;br&gt;	&lt;br&gt;	$(this).next(&amp;quot;.msg_body&amp;quot;).slideToggle(&amp;#39;slow&amp;#39;);&lt;br&gt;	&lt;br&gt;	 &lt;br&gt;	&lt;br&gt;  });................[/code]&lt;p&gt;the form : [code]&amp;lt;?php&lt;p&gt;class Application_Form_Testform extends Zend_Form&lt;br&gt;{&lt;p&gt;    public function init()&lt;br&gt;    {&lt;br&gt;        $countryList=array(&amp;#39;USA&amp;#39;,&amp;#39;UK&amp;#39;);&lt;br&gt;        $firstName =  $this-&amp;gt;createElement(&amp;#39;text&amp;#39;, &amp;#39;firstName&amp;#39;);&lt;br&gt;        $firstName-&amp;gt;setLabel(&amp;#39;First Name&amp;#39;)&lt;br&gt;                -&amp;gt;setAttrib(&amp;#39;size&amp;#39;,25)&lt;br&gt;                -&amp;gt;addValidator(&amp;#39;StringLength&amp;#39;, false,array(3,50))&lt;br&gt;                -&amp;gt;setValue(&amp;#39;&amp;#39;)&lt;br&gt;                -&amp;gt;setRequired(true);&lt;br&gt;        &lt;br&gt;        $lastName =  $this-&amp;gt;createElement(&amp;#39;text&amp;#39;, &amp;#39;lastName&amp;#39;);&lt;br&gt;        $lastName-&amp;gt;setLabel(&amp;#39;Last Name:&amp;#39;)&lt;br&gt;                -&amp;gt;setAttrib(&amp;#39;size&amp;#39;, 25)&lt;br&gt;                -&amp;gt;addValidator(&amp;#39;StringLength&amp;#39;, false,array(3,50))&lt;br&gt;                -&amp;gt;setValue(&amp;#39;&amp;#39;)&lt;br&gt;                -&amp;gt;setRequired(true);&lt;br&gt;       &lt;br&gt;        &lt;br&gt;       &lt;br&gt;        &lt;br&gt;       [....]&lt;br&gt;        &lt;br&gt;        $this-&amp;gt;addElements( array (&lt;br&gt;        &lt;br&gt;                            $firstName,&lt;br&gt;                            $lastName,&lt;br&gt;                            $address1,&lt;br&gt;                            $address2,&lt;br&gt;                            $postalCode,&lt;br&gt;                            $city,&lt;br&gt;                            $state,&lt;br&gt;                            $country,&lt;br&gt;                            $phone,&lt;br&gt;                            $emailAddress,&lt;br&gt;                            $website,&lt;br&gt;                            $userName,&lt;br&gt;                            $password,&lt;br&gt;                            $confirmPassword&lt;br&gt;                            )&lt;br&gt;                );&lt;br&gt;        &lt;br&gt;        $this-&amp;gt;addDisplayGroup(array(&lt;br&gt;        &lt;br&gt;                    &amp;#39;firstName&amp;#39;,&lt;br&gt;                    &amp;#39;lastName&amp;#39;,&lt;br&gt;                    &amp;#39;userName&amp;#39;,&lt;br&gt;                    &amp;#39;address1&amp;#39;,&lt;br&gt;                    &amp;#39;address2&amp;#39;,&lt;br&gt;                    &amp;#39;postalCode&amp;#39;,&lt;br&gt;                    &amp;#39;city&amp;#39;,&lt;br&gt;                    &amp;#39;state&amp;#39;,&lt;br&gt;                    &amp;#39;country&amp;#39;,&lt;br&gt;                    &amp;#39;phone&amp;#39;&lt;br&gt;        &lt;br&gt;            ),&amp;#39;contact&amp;#39;);&lt;br&gt;        &lt;br&gt;        $contact = $this-&amp;gt;getDisplayGroup(&amp;#39;contact&amp;#39;);&lt;br&gt;        /*$contact-&amp;gt;setDecorators(array(&lt;br&gt;        &lt;br&gt;                    &amp;#39;FormElements&amp;#39;,&lt;br&gt;                    &amp;#39;Fieldset&amp;#39;,&lt;br&gt;                    array(&amp;#39;HtmlTag&amp;#39;,array(&amp;#39;tag&amp;#39;=&amp;gt;&amp;#39;div&amp;#39;,&amp;#39;class&amp;#39;=&amp;gt;&amp;#39;msg_body&amp;#39;))&lt;br&gt;        &lt;br&gt;                    ));*/&lt;br&gt;                    &lt;br&gt;        $contact-&amp;gt;addDecorator(&amp;#39;Fieldset&amp;#39;);&lt;br&gt;		$contact-&amp;gt;setLegend(&amp;#39;zoby zoba&amp;#39;)-&amp;gt;setAttrib(&amp;#39;id&amp;#39;, &amp;#39;zob&amp;#39;);&lt;br&gt;        &lt;br&gt;    [/code]&lt;p&gt;thank you very much for the help...&lt;br&gt;Alex&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Zend-JQuery-collapsible-fieldset-tp3335099p3335099.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Zend-JQuery-collapsible-fieldset-tp3335099p3335099.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-48315820505030126?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/48315820505030126/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=48315820505030126' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/48315820505030126'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/48315820505030126'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-mvc-zendjquery-collapsible-fieldset.html' title='[fw-mvc] Zend/JQuery collapsible fieldset'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2530923204485828078</id><published>2011-03-02T05:50:00.001-08:00</published><updated>2011-03-02T05:50:17.127-08:00</updated><title type='text'>Re: [fw-mvc] Zend framework ACL - newbie help needed</title><content type='html'>Hi Matthew,&lt;p&gt;Thanks veyr much for your reply. I have a few questions, and we are having &lt;br&gt;trouble setting it up so I&amp;#39;ll write that here as well:&lt;p&gt;Regarding $identity in your example - this is using Zend Auth as you said. For &lt;br&gt;now, I don&amp;#39;t want to go into Zend Auth until I understand how to perform a &lt;br&gt;simple task on Zend Acl ;) Your examples have used $identity but if you think it &lt;br&gt;does simplify it please let me know, otherwise for now I am trying it without &lt;br&gt;the user of Zend Auth, as we are simply logging in the user with their username &lt;br&gt;+ user group ID (1, 2, or 3).&lt;br&gt;Further details:&lt;p&gt;* I was able to make the Zend_Acl object&lt;p&gt;But below parts are still unclear to me.&lt;br&gt;* Add roles to the Zend_Acl object&lt;br&gt;* Add resources to the Zend_Acl object&lt;br&gt;How can I match these roles with the currently existing users in my database? &lt;br&gt;For example I have following groups in my database.&lt;p&gt;1 Administrator&lt;br&gt;2 Regional Administrator&lt;br&gt;3 Content Manager&lt;p&gt;Basically, the above groups are &amp;quot;roles&amp;quot; . Administrator will have all privileges &lt;br&gt;in my CMS.&lt;p&gt;* Add resources to the Zend_Acl object&lt;br&gt;This is also not entirely clear to me. Should these be in the controller?&lt;br&gt;Eg-&lt;br&gt;&lt;a href="http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025#Zend_Acl%26MVCIntegration-AldemarBernal-4.DependenciesonOtherFrameworkComponents"&gt;http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025#Zend_Acl%26MVCIntegration-AldemarBernal-4.DependenciesonOtherFrameworkComponents&lt;/a&gt;&lt;p&gt;$acl-&amp;gt;add(new Zend_Acl_Resource(&amp;#39;news&amp;#39;))  (is &amp;quot;news&amp;quot; a controller? In where are &lt;br&gt;we defining the behavior of the $acl-&amp;gt;add()? Is this inbuilt?)&lt;p&gt; Below is the the code I&amp;#39;m currently using. In the bootstrap.php :&lt;p&gt;Helper - library/My/Controller/Helper/&lt;br&gt;Plugin - library/My/Controller/Plugin/&lt;p&gt;/** Creating the ACL object */&lt;br&gt;require_once &amp;#39;Zend/Acl.php&amp;#39;;&lt;br&gt;$acl = new Zend_Acl();&lt;p&gt;/** Creating the Role object */&lt;br&gt;require_once &amp;#39;Zend/Acl/Role.php&amp;#39;;&lt;br&gt;$acl-&amp;gt;addRole(new Zend_Acl_Role(&amp;#39;staff&amp;#39;));&lt;br&gt;$acl-&amp;gt;addRole(new Zend_Acl_Role(&amp;#39;member&amp;#39;)); &lt;p&gt;&lt;br&gt;/**&lt;br&gt; * Creating resources:&lt;br&gt; *  - News Controller&lt;br&gt; * Creating privileges:&lt;br&gt; *  - Allow defaultRole to access news controller&lt;br&gt; *  - Deny defaultRole to access add action of news controller&lt;br&gt; */&lt;br&gt;require_once &amp;#39;Zend/Acl/Resource.php&amp;#39;;&lt;br&gt;$acl-&amp;gt;add(new Zend_Acl_Resource(&amp;#39;admin&amp;#39;))&lt;br&gt;    -&amp;gt;allow(&amp;#39;staff&amp;#39;, &amp;#39;admin&amp;#39;)&lt;br&gt;    -&amp;gt;deny(&amp;#39;staff&amp;#39;, &amp;#39;admin&amp;#39;, &amp;#39;reports&amp;#39;);&lt;p&gt;&lt;br&gt;/** Registering the Plugin object */&lt;br&gt;//require_once &amp;#39;Zend/Controller/Plugin/Acl.php&amp;#39;;&lt;br&gt;//$front-&amp;gt;registerPlugin(new Zend_Controller_Plugin_Acl($acl));&lt;p&gt;&lt;br&gt;/* OK, do your stuff, front controller */&lt;br&gt;$frontController-&amp;gt;dispatch();&lt;p&gt;&lt;br&gt;I realise I need to go through the above again, but I&amp;#39;d like to post out a few &lt;br&gt;questions:&lt;p&gt;i) Are &amp;quot;plugin&amp;quot; files required? The link above mentions that we should upload a &lt;br&gt;certain ACL plugin + helper. Other tutorials mention this too. Is this correct?&lt;p&gt;ii) Because my boot strap has routes for the CMS (&amp;quot;AdminController&amp;quot;) and front &lt;br&gt;end (&amp;quot;IndexController&amp;quot;), can I only define roles and resources within my CMS / &lt;br&gt;AdminController? Or must this kind of code be in the bootstrap.php file?&lt;p&gt;iii) I understand the concept - that a &amp;#39;resource&amp;#39; (say, the reporting module in &lt;br&gt;the CMS) needs to be defined. A bunch of &amp;#39;roles&amp;#39; also would be defined, i.e. &lt;br&gt;user groups (&amp;quot;AdministratorRole&amp;quot; would get all rights, and &amp;quot;ContentManagerRole&amp;quot; &lt;br&gt;would get a few rights).&lt;br&gt;Then, when I am actually at the controller action for my &amp;#39;reporting module&amp;#39; for &lt;br&gt;example, what code do I put in to tell ZF that &amp;quot;we are in the reporting module &lt;br&gt;resource, so check the logged in user&amp;#39;s rights and grant access if permitted&amp;quot;?&lt;p&gt;Many thanks,&lt;br&gt;Rishi&lt;p&gt;&lt;p&gt;&lt;br&gt;________________________________&lt;br&gt;From: Matthew Weier O&amp;#39;Phinney &amp;lt;&lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&amp;gt;&lt;br&gt;To: &lt;a href="mailto:fw-mvc@lists.zend.com"&gt;fw-mvc@lists.zend.com&lt;/a&gt;&lt;br&gt;Sent: Mon, February 28, 2011 10:07:18 PM&lt;br&gt;Subject: Re: [fw-mvc] Zend framework ACL - newbie help needed&lt;p&gt;-- Rishi Daryanani &amp;lt;&lt;a href="mailto:rishijd@yahoo.com"&gt;rishijd@yahoo.com&lt;/a&gt;&amp;gt; wrote&lt;br&gt;(on Monday, 28 February 2011, 06:06 AM -0800):&lt;br&gt;&amp;gt; I&amp;#39;m very new to ACL and it&amp;#39;s not something we&amp;#39;ve tried below. Any guidance &lt;br&gt;&amp;gt;would &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; be appreciated; I&amp;#39;m going to start with code experimentation but would like to &lt;p&gt;&amp;gt; know if I&amp;#39;m on the right track.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; We are using a custom developed CMS which is using ZF&amp;quot;, and we have our front &lt;br&gt;&amp;gt; end website as well. The CMS uses a controller called &amp;quot;AdminController&amp;quot;, and &lt;br&gt;&amp;gt;the &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; front end only uses a controller called &amp;quot;IndexController&amp;quot;. I want to introduce &lt;p&gt;&amp;gt; access control to this CMS. Therefore some user groups will be restricted to &lt;br&gt;&amp;gt; some areas of the CMS.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; Current potential solution :&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; I&amp;#39;m thinking of achieving this functionality as described below.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; 1. Have  a database table to store the type of the user.&lt;br&gt;&amp;gt; 2. Have a separate table to store the pages the user is allowed or not allowed. &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; 3. Check in each page whether the user have the access or not and display the &lt;br&gt;&amp;gt; page accordingly.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; Which is the best way to implement this using Zend framework? &amp;quot;Zend_Auth&amp;quot; or &lt;br&gt;&amp;gt; &amp;quot;Zend_Acl&amp;quot; ? &lt;p&gt;Zend_Auth is used for authentication of a user; i.e., evaluating the&lt;br&gt;provided credentials to determine identity.&lt;p&gt;Zend_Acl is used for authorization; i.e., to determine whether a given&lt;br&gt;user has the rights to access a given resource.&lt;p&gt;What you describe above is the realm of Zend_Acl.&lt;p&gt;&amp;gt; I have looked in to the &amp;quot;Zend_Acl&amp;quot; and it sounds good, however &lt;br&gt;&amp;gt; could someone guide me - what is the procedure for implementing this? Here are &lt;p&gt;&amp;gt; the links I found:&lt;br&gt;&amp;gt; &lt;a href="http://framework.zend.com/manual/en/zend.acl.introduction.html"&gt;http://framework.zend.com/manual/en/zend.acl.introduction.html&lt;/a&gt; &lt;br&gt;&amp;gt; &lt;a href="http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025"&gt;http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025&lt;/a&gt; &lt;p&gt;The basic workflow is:&lt;p&gt;* Create a Zend_Acl object&lt;br&gt;* Add roles to the Zend_Acl object&lt;br&gt;* Add resources to the Zend_Acl object&lt;br&gt;* Create the permissions&lt;p&gt;Now, that said, there are a variety of ways to do this. You can do it&lt;br&gt;up-front -- i.e., define all roles, resources, and permissions in a&lt;br&gt;given object or in your bootstrap. If you have only a handful of ACLs to&lt;br&gt;create, this is a straight-forward approach.&lt;p&gt;Another approach is to add them as you need them.&lt;p&gt;As an example, when you grab the user identity during login or later&lt;br&gt;from the Zend_Auth session container, you might include the role in the&lt;br&gt;identity information. You can then add this to the ACL as you grab it:&lt;p&gt;    $acl-&amp;gt;addRole($identity-&amp;gt;role);&lt;p&gt;You could also define an array of roles, and then one master role for&lt;br&gt;the user (which would indicate the user inherits all of those roles):&lt;p&gt;    foreach ($identity-&amp;gt;roles as $role) {&lt;br&gt;        $acl-&amp;gt;addRole($role);&lt;br&gt;    }&lt;br&gt;    $acl-&amp;gt;addRole($identity-&amp;gt;username, $identity-&amp;gt;roles);&lt;p&gt;Later, when you grab your page, you might also include ACL information&lt;br&gt;in the page metadata. This allows you to setup the resource and&lt;br&gt;permissions ad-hoc. As an example, let&amp;#39;s assume that a &amp;quot;page&amp;quot; object&lt;br&gt;might have the following in its structure:&lt;p&gt;    public $identifier;&lt;br&gt;    public $roles = array(&lt;br&gt;        array(&amp;#39;role&amp;#39; =&amp;gt; array(&amp;#39;read&amp;#39;, &amp;#39;write&amp;#39;))&lt;br&gt;    );&lt;p&gt;    $acl-&amp;gt;addResource($page-&amp;gt;identifier);&lt;br&gt;    foreach ($page-&amp;gt;roles as $role =&amp;gt; $rights) {&lt;br&gt;        if (!$acl-&amp;gt;hasRole($role)) {&lt;br&gt;            $acl-&amp;gt;addRole($role);&lt;br&gt;        }&lt;br&gt;        $acl-&amp;gt;allow($role, $page-&amp;gt;identifier, $rights);&lt;br&gt;    }&lt;p&gt;Then, you can test right there and then:&lt;p&gt;    if (!$acl-&amp;gt;isAllowed($identity-&amp;gt;role, $page-&amp;gt;identifier, $currentPrivilege)) &lt;br&gt;{&lt;br&gt;        throw new AclException;&lt;br&gt;    }&lt;p&gt;This allows you some flexibility -- you don&amp;#39;t have to define all ACLs up&lt;br&gt;front, and can grow the graph as your content grows. That said, it can&lt;br&gt;get tricky if you want to introduce role inheritance, so you have to&lt;br&gt;setup a strict convention of how the roles are stored.&lt;p&gt;Hope that helps get you started!&lt;p&gt;&amp;gt; The gist of my understanding is:&lt;br&gt;&amp;gt; - In the AdminController (or is it bootstrap.php) I have to define a set of &lt;br&gt;&amp;gt; Roles and Resources that are accessed/denied for those roles. This follows the &lt;p&gt;&amp;gt; above tutorial example. In my case, I need to add a new user role called &amp;quot;staff &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; user&amp;quot; who will just have access to one function in the CMS, a basic &amp;quot;customer &lt;br&gt;&amp;gt; lookup&amp;quot; reporting function.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; - However I also need to check (in the &amp;quot;customer lookup&amp;quot; function) if the &lt;br&gt;&amp;gt; logged-in user has access rights to view this page. In all other pages, I need &lt;p&gt;&amp;gt; to DENY access rights actually, if the logged in user is a &amp;quot;staff user&amp;quot;. Is &lt;br&gt;&amp;gt; there a tutorial like this which explains it for newbies? Or could someone &lt;br&gt;&amp;gt;guide &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; me on what kind of code goes where? &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I&amp;#39;m not sure how I can tell ZF the name of the resource of each &lt;br&gt;&amp;gt;section/function &lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; of the CMS. For example, if I have a section called &amp;quot;Reports&amp;quot;, and functions &lt;br&gt;&amp;gt; called&lt;br&gt;&amp;gt; - &amp;quot;Customer Lookup&amp;quot;&lt;br&gt;&amp;gt; - &amp;quot;Orders report&amp;quot;&lt;br&gt;&amp;gt; - &amp;quot;Members report&amp;quot;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; then what code would I put in for each of the above controller functions to &lt;br&gt;&amp;gt; assign a resource name and possibly a module/sub-resource name to each &lt;br&gt;&amp;gt;function?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Many thanks,&lt;br&gt;&amp;gt; Rishi&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;      &lt;p&gt;-- &lt;br&gt;Matthew Weier O&amp;#39;Phinney&lt;br&gt;Project Lead            | &lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&lt;br&gt;Zend Framework          | &lt;a href="http://framework.zend.com/"&gt;http://framework.zend.com/&lt;/a&gt;&lt;br&gt;PGP key: &lt;a href="http://framework.zend.com/zf-matthew-pgp-key.asc"&gt;http://framework.zend.com/zf-matthew-pgp-key.asc&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2530923204485828078?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2530923204485828078/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2530923204485828078' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2530923204485828078'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2530923204485828078'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/re-fw-mvc-zend-framework-acl-newbie.html' title='Re: [fw-mvc] Zend framework ACL - newbie help needed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8423474486119713497</id><published>2011-03-02T04:38:00.000-08:00</published><updated>2011-03-02T07:07:02.247-08:00</updated><title type='text'>[fw-server] Zend_Soap client and SoapServer UTF-8 encoding problem</title><content type='html'>Hello and thank in advance&lt;br&gt;I have a website and The site works on one server and DB on the other&lt;br&gt;server. When I enter on site text to submit to DB on non english letters, it&lt;br&gt;saves and ther render corect. For example if I enter &amp;quot;Привет Всем&amp;quot; I will&lt;br&gt;see the same text on the site when display.&lt;p&gt;All MySQL collation as table as fields are utf8_general_ci Meta&lt;br&gt;content-encoding on the page also utf-8 as on site as on phpMyAdmin&lt;p&gt;Although if I access DB with phpMyAdmin I see &amp;#208;š&amp;#208;&amp;#190;&amp;#208;&amp;#189;&amp;#209;&amp;#209;‚&amp;#208;&amp;#189;&amp;#208;&amp;#176;&amp;#209;‚&amp;#208;&amp;#184;&amp;#208;&amp;#189; &amp;#208;Ÿ&amp;#208;&amp;#176;&amp;#208; If I&lt;br&gt;change it to Привет Всем then on the site I see ???????? ????&lt;p&gt;It was not working like this on our local test on 2 different servers with&lt;br&gt;Windows on them. But after deploy to centOS online server it bacome work&lt;br&gt;like this.&lt;p&gt;Looks like it double encode text to UTF-8. I cannot find where is it.&lt;p&gt;Zend_Soap_Client:: or SoapServer:: or MySQL encoding.&lt;p&gt;I rejected idea of Mysql because I though that if it is MySQl then it saves&lt;br&gt;wrong, and then when it extraxts it should send wrong data.&lt;p&gt;kindest regards&lt;p&gt;--&lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Zend-Soap-client-and-SoapServer-UTF-8-encoding-problem-tp3331415p3331415.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Zend-Soap-client-and-SoapServer-UTF-8-encoding-problem-tp3331415p3331415.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Server mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8423474486119713497?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8423474486119713497/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8423474486119713497' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8423474486119713497'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8423474486119713497'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/03/fw-server-zendsoap-client-and.html' title='[fw-server] Zend_Soap client and SoapServer UTF-8 encoding problem'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-834503875129868029</id><published>2011-02-28T08:37:00.001-08:00</published><updated>2011-02-28T08:37:38.035-08:00</updated><title type='text'>Re: [fw-mvc] Zend framework ACL - newbie help needed</title><content type='html'>-- Rishi Daryanani &amp;lt;&lt;a href="mailto:rishijd@yahoo.com"&gt;rishijd@yahoo.com&lt;/a&gt;&amp;gt; wrote&lt;br&gt;(on Monday, 28 February 2011, 06:06 AM -0800):&lt;br&gt;&amp;gt; I&amp;#39;m very new to ACL and it&amp;#39;s not something we&amp;#39;ve tried below. Any guidance would &lt;br&gt;&amp;gt; be appreciated; I&amp;#39;m going to start with code experimentation but would like to &lt;br&gt;&amp;gt; know if I&amp;#39;m on the right track.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; We are using a custom developed CMS which is using ZF&amp;quot;, and we have our front &lt;br&gt;&amp;gt; end website as well. The CMS uses a controller called &amp;quot;AdminController&amp;quot;, and the &lt;br&gt;&amp;gt; front end only uses a controller called &amp;quot;IndexController&amp;quot;. I want to introduce &lt;br&gt;&amp;gt; access control to this CMS. Therefore some user groups will be restricted to &lt;br&gt;&amp;gt; some areas of the CMS.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; Current potential solution :&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; I&amp;#39;m thinking of achieving this functionality as described below.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; 1. Have  a database table to store the type of the user.&lt;br&gt;&amp;gt; 2. Have a separate table to store the pages the user is allowed or not allowed. &lt;br&gt;&amp;gt; 3. Check in each page whether the user have the access or not and display the &lt;br&gt;&amp;gt; page accordingly.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; Which is the best way to implement this using Zend framework? &amp;quot;Zend_Auth&amp;quot; or &lt;br&gt;&amp;gt; &amp;quot;Zend_Acl&amp;quot; ? &lt;p&gt;Zend_Auth is used for authentication of a user; i.e., evaluating the&lt;br&gt;provided credentials to determine identity.&lt;p&gt;Zend_Acl is used for authorization; i.e., to determine whether a given&lt;br&gt;user has the rights to access a given resource.&lt;p&gt;What you describe above is the realm of Zend_Acl.&lt;p&gt;&amp;gt; I have looked in to the &amp;quot;Zend_Acl&amp;quot; and it sounds good, however &lt;br&gt;&amp;gt; could someone guide me - what is the procedure for implementing this? Here are &lt;br&gt;&amp;gt; the links I found:&lt;br&gt;&amp;gt; &lt;a href="http://framework.zend.com/manual/en/zend.acl.introduction.html"&gt;http://framework.zend.com/manual/en/zend.acl.introduction.html&lt;/a&gt; &lt;br&gt;&amp;gt; &lt;a href="http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025"&gt;http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025&lt;/a&gt; &lt;p&gt;The basic workflow is:&lt;p&gt; * Create a Zend_Acl object&lt;br&gt; * Add roles to the Zend_Acl object&lt;br&gt; * Add resources to the Zend_Acl object&lt;br&gt; * Create the permissions&lt;p&gt;Now, that said, there are a variety of ways to do this. You can do it&lt;br&gt;up-front -- i.e., define all roles, resources, and permissions in a&lt;br&gt;given object or in your bootstrap. If you have only a handful of ACLs to&lt;br&gt;create, this is a straight-forward approach.&lt;p&gt;Another approach is to add them as you need them.&lt;p&gt;As an example, when you grab the user identity during login or later&lt;br&gt;from the Zend_Auth session container, you might include the role in the&lt;br&gt;identity information. You can then add this to the ACL as you grab it:&lt;p&gt;    $acl-&amp;gt;addRole($identity-&amp;gt;role);&lt;p&gt;You could also define an array of roles, and then one master role for&lt;br&gt;the user (which would indicate the user inherits all of those roles):&lt;p&gt;    foreach ($identity-&amp;gt;roles as $role) {&lt;br&gt;        $acl-&amp;gt;addRole($role);&lt;br&gt;    }&lt;br&gt;    $acl-&amp;gt;addRole($identity-&amp;gt;username, $identity-&amp;gt;roles);&lt;p&gt;Later, when you grab your page, you might also include ACL information&lt;br&gt;in the page metadata. This allows you to setup the resource and&lt;br&gt;permissions ad-hoc. As an example, let&amp;#39;s assume that a &amp;quot;page&amp;quot; object&lt;br&gt;might have the following in its structure:&lt;p&gt;    public $identifier;&lt;br&gt;    public $roles = array(&lt;br&gt;        array(&amp;#39;role&amp;#39; =&amp;gt; array(&amp;#39;read&amp;#39;, &amp;#39;write&amp;#39;))&lt;br&gt;    );&lt;p&gt;    $acl-&amp;gt;addResource($page-&amp;gt;identifier);&lt;br&gt;    foreach ($page-&amp;gt;roles as $role =&amp;gt; $rights) {&lt;br&gt;        if (!$acl-&amp;gt;hasRole($role)) {&lt;br&gt;            $acl-&amp;gt;addRole($role);&lt;br&gt;        }&lt;br&gt;        $acl-&amp;gt;allow($role, $page-&amp;gt;identifier, $rights);&lt;br&gt;    }&lt;p&gt;Then, you can test right there and then:&lt;p&gt;    if (!$acl-&amp;gt;isAllowed($identity-&amp;gt;role, $page-&amp;gt;identifier, $currentPrivilege)) {&lt;br&gt;        throw new AclException;&lt;br&gt;    }&lt;p&gt;This allows you some flexibility -- you don&amp;#39;t have to define all ACLs up&lt;br&gt;front, and can grow the graph as your content grows. That said, it can&lt;br&gt;get tricky if you want to introduce role inheritance, so you have to&lt;br&gt;setup a strict convention of how the roles are stored.&lt;p&gt;Hope that helps get you started!&lt;p&gt;&amp;gt; The gist of my understanding is:&lt;br&gt;&amp;gt; - In the AdminController (or is it bootstrap.php) I have to define a set of &lt;br&gt;&amp;gt; Roles and Resources that are accessed/denied for those roles. This follows the &lt;br&gt;&amp;gt; above tutorial example. In my case, I need to add a new user role called &amp;quot;staff &lt;br&gt;&amp;gt; user&amp;quot; who will just have access to one function in the CMS, a basic &amp;quot;customer &lt;br&gt;&amp;gt; lookup&amp;quot; reporting function.&lt;br&gt;&amp;gt;  &lt;br&gt;&amp;gt; - However I also need to check (in the &amp;quot;customer lookup&amp;quot; function) if the &lt;br&gt;&amp;gt; logged-in user has access rights to view this page. In all other pages, I need &lt;br&gt;&amp;gt; to DENY access rights actually, if the logged in user is a &amp;quot;staff user&amp;quot;. Is &lt;br&gt;&amp;gt; there a tutorial like this which explains it for newbies? Or could someone guide &lt;br&gt;&amp;gt; me on what kind of code goes where? &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I&amp;#39;m not sure how I can tell ZF the name of the resource of each section/function &lt;br&gt;&amp;gt; of the CMS. For example, if I have a section called &amp;quot;Reports&amp;quot;, and functions &lt;br&gt;&amp;gt; called&lt;br&gt;&amp;gt; - &amp;quot;Customer Lookup&amp;quot;&lt;br&gt;&amp;gt; - &amp;quot;Orders report&amp;quot;&lt;br&gt;&amp;gt; - &amp;quot;Members report&amp;quot;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; then what code would I put in for each of the above controller functions to &lt;br&gt;&amp;gt; assign a resource name and possibly a module/sub-resource name to each function?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Many thanks,&lt;br&gt;&amp;gt; Rishi&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;       &lt;p&gt;-- &lt;br&gt;Matthew Weier O&amp;#39;Phinney&lt;br&gt;Project Lead            | &lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&lt;br&gt;Zend Framework          | &lt;a href="http://framework.zend.com/"&gt;http://framework.zend.com/&lt;/a&gt;&lt;br&gt;PGP key: &lt;a href="http://framework.zend.com/zf-matthew-pgp-key.asc"&gt;http://framework.zend.com/zf-matthew-pgp-key.asc&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-834503875129868029?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/834503875129868029/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=834503875129868029' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/834503875129868029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/834503875129868029'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-zend-framework-acl-newbie.html' title='Re: [fw-mvc] Zend framework ACL - newbie help needed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-462417382055996154</id><published>2011-02-28T06:06:00.000-08:00</published><updated>2011-02-28T06:07:04.389-08:00</updated><title type='text'>[fw-mvc] Zend framework ACL - newbie help needed</title><content type='html'>Hi,&lt;p&gt;I&amp;#39;m very new to ACL and it&amp;#39;s not something we&amp;#39;ve tried below. Any guidance would &lt;br&gt;be appreciated; I&amp;#39;m going to start with code experimentation but would like to &lt;br&gt;know if I&amp;#39;m on the right track.&lt;p&gt;&lt;br&gt;We are using a custom developed CMS which is using ZF&amp;quot;, and we have our front &lt;br&gt;end website as well. The CMS uses a controller called &amp;quot;AdminController&amp;quot;, and the &lt;br&gt;front end only uses a controller called &amp;quot;IndexController&amp;quot;. I want to introduce &lt;br&gt;access control to this CMS. Therefore some user groups will be restricted to &lt;br&gt;some areas of the CMS.&lt;br&gt; &lt;br&gt;Current potential solution :&lt;br&gt; &lt;br&gt;I&amp;#39;m thinking of achieving this functionality as described below.&lt;br&gt; &lt;br&gt;1. Have  a database table to store the type of the user.&lt;br&gt;2. Have a separate table to store the pages the user is allowed or not allowed. &lt;br&gt;3. Check in each page whether the user have the access or not and display the &lt;br&gt;page accordingly.&lt;br&gt; &lt;br&gt;Which is the best way to implement this using Zend framework? &amp;quot;Zend_Auth&amp;quot; or &lt;br&gt;&amp;quot;Zend_Acl&amp;quot; ? I have looked in to the &amp;quot;Zend_Acl&amp;quot; and it sounds good, however &lt;br&gt;could someone guide me - what is the procedure for implementing this? Here are &lt;br&gt;the links I found:&lt;br&gt;&lt;a href="http://framework.zend.com/manual/en/zend.acl.introduction.html"&gt;http://framework.zend.com/manual/en/zend.acl.introduction.html&lt;/a&gt; &lt;br&gt;&lt;a href="http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025"&gt;http://framework.zend.com/wiki/pages/viewpage.action?pageId=39025&lt;/a&gt; &lt;br&gt; &lt;br&gt;The gist of my understanding is:&lt;br&gt;- In the AdminController (or is it bootstrap.php) I have to define a set of &lt;br&gt;Roles and Resources that are accessed/denied for those roles. This follows the &lt;br&gt;above tutorial example. In my case, I need to add a new user role called &amp;quot;staff &lt;br&gt;user&amp;quot; who will just have access to one function in the CMS, a basic &amp;quot;customer &lt;br&gt;lookup&amp;quot; reporting function.&lt;br&gt; &lt;br&gt;- However I also need to check (in the &amp;quot;customer lookup&amp;quot; function) if the &lt;br&gt;logged-in user has access rights to view this page. In all other pages, I need &lt;br&gt;to DENY access rights actually, if the logged in user is a &amp;quot;staff user&amp;quot;. Is &lt;br&gt;there a tutorial like this which explains it for newbies? Or could someone guide &lt;br&gt;me on what kind of code goes where? &lt;p&gt;I&amp;#39;m not sure how I can tell ZF the name of the resource of each section/function &lt;br&gt;of the CMS. For example, if I have a section called &amp;quot;Reports&amp;quot;, and functions &lt;br&gt;called&lt;br&gt;- &amp;quot;Customer Lookup&amp;quot;&lt;br&gt;- &amp;quot;Orders report&amp;quot;&lt;br&gt;- &amp;quot;Members report&amp;quot;&lt;p&gt;then what code would I put in for each of the above controller functions to &lt;br&gt;assign a resource name and possibly a module/sub-resource name to each function?&lt;p&gt;Many thanks,&lt;br&gt;Rishi&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-462417382055996154?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/462417382055996154/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=462417382055996154' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/462417382055996154'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/462417382055996154'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-zend-framework-acl-newbie-help.html' title='[fw-mvc] Zend framework ACL - newbie help needed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-7724956920503388389</id><published>2011-02-25T04:02:00.000-08:00</published><updated>2011-02-25T04:03:07.953-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>On Thu, Feb 24, 2011 at 6:40 PM, Bill Karwin &amp;lt;&lt;a href="mailto:bill@karwin.com"&gt;bill@karwin.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; On Feb 24, 2011, at 1:55 PM, David Mintz wrote:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;  Thanks for the helpful observations. The trouble with NULL is that it&amp;#39;s&lt;br&gt;&amp;gt;&amp;gt; too vague. I have cases where I need something that means &amp;quot;not applicable,&amp;quot;&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;unknown,&amp;quot; or most often, &amp;quot;we don&amp;#39;t care&amp;quot; because the proceeding took place&lt;br&gt;&amp;gt;&amp;gt; before the generic duty magistrate whose actual identity really isn&amp;#39;t&lt;br&gt;&amp;gt;&amp;gt; important, and users don&amp;#39;t want to be forced to identify her/him by name.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Fair enough.  For what it&amp;#39;s worth, it has been a subject of debate over&lt;br&gt;&amp;gt; many years among relational theorists whether NULL should be a single value&lt;br&gt;&amp;gt; or should there be multiple &amp;quot;types&amp;quot; of NULL for different purposes.  E.g.&lt;br&gt;&amp;gt; &amp;quot;applicable but unknown at this time&amp;quot; is different from &amp;quot;inapplicable&amp;quot;.&lt;br&gt;&amp;gt;  There have been proposals for up to four different types of NULL-like&lt;br&gt;&amp;gt; value.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On the other extreme, people like C. J. Date argue strongly that any kind&lt;br&gt;&amp;gt; of NULL is inappropriate in the relational model.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; In your case, I&amp;#39;d still recommend using NULL for the foreign key, simply&lt;br&gt;&amp;gt; because it solves your issue with -1.  The worst solution in my view is to&lt;br&gt;&amp;gt; use a non-null value to do what NULL is meant to do.  Once you start saying,&lt;br&gt;&amp;gt; &amp;quot;we can&amp;#39;t use DRI constraints because...&amp;quot; then IMHO it doesn&amp;#39;t matter how&lt;br&gt;&amp;gt; you finish that sentence, because you&amp;#39;ve already broken your logical&lt;br&gt;&amp;gt; database design.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; If you still need to distinguish between &amp;quot;n/a&amp;quot;, &amp;quot;unknown&amp;quot; or &amp;quot;we don&amp;#39;t&lt;br&gt;&amp;gt; care&amp;quot; then add another column called `why_no_judge` or something.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;p&gt;Say no more! I&amp;#39;m convinced. I am sort of an enthusiast programmer, a guy&lt;br&gt;with a non-IT job title who has picked up skills to solve problems in the&lt;br&gt;workplace (there being no one else in the organization to do it). In my&lt;br&gt;non-expert opinion this is a situation where you have to do something a&lt;br&gt;little ugly, that doesn&amp;#39;t feel completely right, no matter what. And I think&lt;br&gt;your solution is less ugly and will work better than what I was going to do.&lt;br&gt;Thanks.&lt;p&gt;-- &lt;br&gt;David Mintz&lt;br&gt;&lt;a href="http://davidmintz.org/"&gt;http://davidmintz.org/&lt;/a&gt;&lt;br&gt;It ain&amp;#39;t over:&lt;br&gt;&lt;a href="http://www.healthcare-now.org/"&gt;http://www.healthcare-now.org/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-7724956920503388389?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/7724956920503388389/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=7724956920503388389' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7724956920503388389'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7724956920503388389'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_25.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8477214724348753430</id><published>2011-02-24T18:49:00.001-08:00</published><updated>2011-02-24T18:49:48.815-08:00</updated><title type='text'>Re: [fw-gdata] Bad request</title><content type='html'>Catch the exception and look for the body of it (var_dump if necessary)  It&lt;br&gt;should provide more info about the cause of the exception for the body of&lt;br&gt;the HttpResponse object.&lt;p&gt;Cheers,&lt;br&gt;-Ryan&lt;p&gt;&lt;br&gt;On Thu, Feb 24, 2011 at 2:53 AM, knasboll &amp;lt;&lt;a href="mailto:tony@perfectfools.com"&gt;tony@perfectfools.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; Please advi&lt;br&gt;&amp;gt; ce...&lt;br&gt;&amp;gt; This code below returns&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; [code:protected] =&amp;gt; 400&lt;br&gt;&amp;gt; [message:protected] =&amp;gt; Bad Request&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Cannot figure out how to do it, xxx is correct in my code :)&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; $client = Zend_Gdata_ClientLogin::getHttpClient($email, $password,&lt;br&gt;&amp;gt; Zend_Gdata_Gapps::AUTH_SERVICE_NAME);&lt;br&gt;&amp;gt; $service = new Zend_Gdata_Gapps($client, $domain);&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; $get =&lt;br&gt;&amp;gt; &amp;quot;&lt;a href="https://apps-apis.google.com/a/feeds/emailsettings/2.0/xxx.com/xxx/"&gt;https://apps-apis.google.com/a/feeds/emailsettings/2.0/xxx.com/xxx/&lt;/a&gt;&amp;quot;;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; $client-&amp;gt;setUri($get);&lt;br&gt;&amp;gt; $client-&amp;gt;request(&amp;#39;GET&amp;#39;);&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; View this message in context:&lt;br&gt;&amp;gt; &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Bad-request-tp3322408p3322408.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Bad-request-tp3322408p3322408.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend gdata mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8477214724348753430?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8477214724348753430/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8477214724348753430' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8477214724348753430'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8477214724348753430'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-gdata-bad-request.html' title='Re: [fw-gdata] Bad request'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6215862360374647187</id><published>2011-02-24T16:42:00.000-08:00</published><updated>2011-02-24T16:46:12.311-08:00</updated><title type='text'>Re: [fw-mvc] Sessions and passing them between websites</title><content type='html'>Hey Thomas,&lt;p&gt;&amp;gt; idea is to be able to embed a form on another website, and then process that form  through Action controllers on a site built using the Zend Framework&lt;p&gt;Why are sessions required? Can you just have the form on site A POST to &lt;br&gt;the form on site B?&lt;p&gt;If you did go this route, any non-valid form handling would happen on &lt;br&gt;site B, but outside of that you can do this without any sessions.&lt;p&gt;If it is imperative that site A always display the form including the &lt;br&gt;in-valid form processing results (error messages, required fields, etc), &lt;br&gt;then you&amp;#39;ll need to find a way to make Site A and site B share &lt;br&gt;information.  If these sites are not sharing the same top level domain &lt;br&gt;name, this gets harder b/c the session identifier used by Zend_Session &lt;br&gt;will not be the same (that would require some kind of SSO solution.)&lt;p&gt;Ultimately, it depends on how complex your solution to be.&lt;p&gt;-ralph&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6215862360374647187?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6215862360374647187/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6215862360374647187' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6215862360374647187'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6215862360374647187'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-sessions-and-passing-them_24.html' title='Re: [fw-mvc] Sessions and passing them between websites'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4375578455981906293</id><published>2011-02-24T15:40:00.001-08:00</published><updated>2011-02-24T15:40:48.024-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>On Feb 24, 2011, at 1:55 PM, David Mintz wrote:&lt;p&gt;&amp;gt; Thanks for the helpful observations. The trouble with NULL is that  &lt;br&gt;&amp;gt; it&amp;#39;s too vague. I have cases where I need something that means &amp;quot;not  &lt;br&gt;&amp;gt; applicable,&amp;quot; &amp;quot;unknown,&amp;quot; or most often, &amp;quot;we don&amp;#39;t care&amp;quot; because the  &lt;br&gt;&amp;gt; proceeding took place before the generic duty magistrate whose  &lt;br&gt;&amp;gt; actual identity really isn&amp;#39;t important, and users don&amp;#39;t want to be  &lt;br&gt;&amp;gt; forced to identify her/him by name.&lt;p&gt;Fair enough.  For what it&amp;#39;s worth, it has been a subject of debate  &lt;br&gt;over many years among relational theorists whether NULL should be a  &lt;br&gt;single value or should there be multiple &amp;quot;types&amp;quot; of NULL for different  &lt;br&gt;purposes.  E.g. &amp;quot;applicable but unknown at this time&amp;quot; is different  &lt;br&gt;from &amp;quot;inapplicable&amp;quot;.  There have been proposals for up to four  &lt;br&gt;different types of NULL-like value.&lt;p&gt;On the other extreme, people like C. J. Date argue strongly that any  &lt;br&gt;kind of NULL is inappropriate in the relational model.&lt;p&gt;In your case, I&amp;#39;d still recommend using NULL for the foreign key,  &lt;br&gt;simply because it solves your issue with -1.  The worst solution in my  &lt;br&gt;view is to use a non-null value to do what NULL is meant to do.  Once  &lt;br&gt;you start saying, &amp;quot;we can&amp;#39;t use DRI constraints because...&amp;quot; then IMHO  &lt;br&gt;it doesn&amp;#39;t matter how you finish that sentence, because you&amp;#39;ve already  &lt;br&gt;broken your logical database design.&lt;p&gt;If you still need to distinguish between &amp;quot;n/a&amp;quot;, &amp;quot;unknown&amp;quot; or &amp;quot;we don&amp;#39;t  &lt;br&gt;care&amp;quot; then add another column called `why_no_judge` or something.&lt;p&gt;Regards,&lt;br&gt;Bill Karwin&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4375578455981906293?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4375578455981906293/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4375578455981906293' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4375578455981906293'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4375578455981906293'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_3022.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-927844437220536458</id><published>2011-02-24T13:55:00.001-08:00</published><updated>2011-02-24T13:55:40.973-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>On Thu, Feb 24, 2011 at 1:41 PM, Bill Karwin &amp;lt;&lt;a href="mailto:bill@karwin.com"&gt;bill@karwin.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; On Feb 24, 2011, at 8:52 AM, David Mintz wrote:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;  In&lt;br&gt;&amp;gt;&amp;gt; `events`, my judge_id is signed, and a negative value like -1 means &amp;#39;not&lt;br&gt;&amp;gt;&amp;gt; applicable&amp;#39; (to the application) and so forth.  At event insertion/update&lt;br&gt;&amp;gt;&amp;gt; time I will go to great pains to enforce RI, e.g., by locking tables and&lt;br&gt;&amp;gt;&amp;gt; making sure nobody has deleted judge so-and-so out from under me.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; What solution would you suggest?&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Right -- you can&amp;#39;t use -1 if you want DRI, because there is no judge whose&lt;br&gt;&amp;gt; primary key value is -1.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; You should make the judge_id column nullable, and use NULL to mean &amp;#39;not&lt;br&gt;&amp;gt; applicable&amp;#39; or &amp;#39;not assigned&amp;#39;.  Then you can declare a foreign key&lt;br&gt;&amp;gt; constraint to the judges table.  A NULL in the foreign key column doesn&amp;#39;t&lt;br&gt;&amp;gt; have to match any row in the referenced table.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; You can read more about using NULL in my book &amp;quot;SQL Antipatterns&amp;quot; (&lt;br&gt;&amp;gt; &lt;a href="http://www.pragprog.com/titles/bksqla/"&gt;http://www.pragprog.com/titles/bksqla/&lt;/a&gt;), in the chapter &amp;quot;Fear of the&lt;br&gt;&amp;gt; Unknown.&amp;quot;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; That said, I think it&amp;#39;s weird to delete a row from the judges table&lt;br&gt;&amp;gt; regardless.  Does that mean when a judge retires, you delete his row, and&lt;br&gt;&amp;gt; the delete cascades to any events that he or she participated in?  Doesn&amp;#39;t&lt;br&gt;&amp;gt; that mean destroying a lot of useful historical data?  Not to mention&lt;br&gt;&amp;gt; erasing the legacy of a respectable career in public service?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I would think that in an app like this, you would never actually DELETE a&lt;br&gt;&amp;gt; row from judges.  Instead, you set a `status` attribute for that judge, to&lt;br&gt;&amp;gt; mark him or her as &amp;#39;retired&amp;#39; or &amp;#39;voted out of office&amp;#39; or something.  Or else&lt;br&gt;&amp;gt; set a date field for `end_active_term`.  Then code your application logic to&lt;br&gt;&amp;gt; create new events only for active judges, e.g. those whose `status` is&lt;br&gt;&amp;gt; &amp;#39;active&amp;#39;, or whose `end_active_term` is either NULL or in the future.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; If you don&amp;#39;t delete, then you don&amp;#39;t need to cascade deletes.  :-)&lt;br&gt;&amp;gt;&lt;p&gt;&lt;br&gt;Thanks for the helpful observations. The trouble with NULL is that it&amp;#39;s too&lt;br&gt;vague. I have cases where I need something that means &amp;quot;not applicable,&amp;quot;&lt;br&gt;&amp;quot;unknown,&amp;quot; or most often, &amp;quot;we don&amp;#39;t care&amp;quot; because the proceeding took place&lt;br&gt;before the generic duty magistrate whose actual identity really isn&amp;#39;t&lt;br&gt;important, and users don&amp;#39;t want to be forced to identify her/him by name.&lt;p&gt;And you&amp;#39;re quite right: deletion will be a rarity in my judges table as well&lt;br&gt;as most others. But it could happen that one user half-assedly puts in an&lt;br&gt;inexact duplicate of another row, or otherwise made some mistake, and&lt;br&gt;someone else comes along and corrects the mistake by deleting it before the&lt;br&gt;row acquires children, but too late for its id not to appear as a value in&lt;br&gt;some SELECT menu.&lt;p&gt;And I do have a de facto boolean &amp;#39;active&amp;#39; column in this table (it&amp;#39;s MySQL)&lt;br&gt;where 1 means active and 0 means inactive -- retired, deceased, resigned,&lt;br&gt;etc. Indeed when someone who is known to the app changes hats -- and it&lt;br&gt;happens -- say from law clerk to prosecutor, prosecutor to judge, they will&lt;br&gt;not be deleted but made inactive and then they&amp;#39;ll be reborn in another row.&lt;br&gt;I call it reincarnation. Otherwise, yeah, you would trash or falsify your&lt;br&gt;historical data.&lt;p&gt;It&amp;#39;s really reassuring when someone who knows what he&amp;#39;s talking about&lt;br&gt;suggests you do what you&amp;#39;re already doing, so thanks!&lt;p&gt;Getting back to the first point about NULL, I suppose I could make the data&lt;br&gt;model even more complicated but I&amp;#39;d of course prefer to keep it as simple as&lt;br&gt;possible, no more complex than necessary. I&amp;#39;m of course open to more&lt;br&gt;suggestions, but I think it may be that it&amp;#39;s just the challenge of modeling&lt;br&gt;uncooperative reality in a set of rectangular tables.&lt;p&gt;&lt;br&gt;-- &lt;br&gt;David Mintz&lt;br&gt;&lt;a href="http://davidmintz.org/"&gt;http://davidmintz.org/&lt;/a&gt;&lt;br&gt;It ain&amp;#39;t over:&lt;br&gt;&lt;a href="http://www.healthcare-now.org/"&gt;http://www.healthcare-now.org/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-927844437220536458?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/927844437220536458/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=927844437220536458' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/927844437220536458'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/927844437220536458'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_7150.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6978769191502556684</id><published>2011-02-24T10:41:00.000-08:00</published><updated>2011-02-24T10:42:11.238-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>On Feb 24, 2011, at 8:52 AM, David Mintz wrote:&lt;p&gt;&amp;gt; In&lt;br&gt;&amp;gt; `events`, my judge_id is signed, and a negative value like -1 means  &lt;br&gt;&amp;gt; &amp;#39;not&lt;br&gt;&amp;gt; applicable&amp;#39; (to the application) and so forth.  At event insertion/ &lt;br&gt;&amp;gt; update&lt;br&gt;&amp;gt; time I will go to great pains to enforce RI, e.g., by locking tables  &lt;br&gt;&amp;gt; and&lt;br&gt;&amp;gt; making sure nobody has deleted judge so-and-so out from under me.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; What solution would you suggest?&lt;p&gt;Right -- you can&amp;#39;t use -1 if you want DRI, because there is no judge  &lt;br&gt;whose primary key value is -1.&lt;p&gt;You should make the judge_id column nullable, and use NULL to mean  &lt;br&gt;&amp;#39;not applicable&amp;#39; or &amp;#39;not assigned&amp;#39;.  Then you can declare a foreign  &lt;br&gt;key constraint to the judges table.  A NULL in the foreign key column  &lt;br&gt;doesn&amp;#39;t have to match any row in the referenced table.&lt;p&gt;You can read more about using NULL in my book &amp;quot;SQL Antipatterns&amp;quot; (&lt;a href="http://www.pragprog.com/titles/bksqla/"&gt;http://www.pragprog.com/titles/bksqla/&lt;/a&gt; &lt;br&gt;), in the chapter &amp;quot;Fear of the Unknown.&amp;quot;&lt;p&gt;That said, I think it&amp;#39;s weird to delete a row from the judges table  &lt;br&gt;regardless.  Does that mean when a judge retires, you delete his row,  &lt;br&gt;and the delete cascades to any events that he or she participated in?   &lt;br&gt;Doesn&amp;#39;t that mean destroying a lot of useful historical data?  Not to  &lt;br&gt;mention erasing the legacy of a respectable career in public service?&lt;p&gt;I would think that in an app like this, you would never actually  &lt;br&gt;DELETE a row from judges.  Instead, you set a `status` attribute for  &lt;br&gt;that judge, to mark him or her as &amp;#39;retired&amp;#39; or &amp;#39;voted out of office&amp;#39;  &lt;br&gt;or something.  Or else set a date field for `end_active_term`.  Then  &lt;br&gt;code your application logic to create new events only for active  &lt;br&gt;judges, e.g. those whose `status` is &amp;#39;active&amp;#39;, or whose  &lt;br&gt;`end_active_term` is either NULL or in the future.&lt;p&gt;If you don&amp;#39;t delete, then you don&amp;#39;t need to cascade deletes.  :-)&lt;p&gt;Regards,&lt;br&gt;Bill Karwin&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6978769191502556684?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6978769191502556684/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6978769191502556684' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6978769191502556684'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6978769191502556684'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_3280.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-9052631078070909332</id><published>2011-02-24T10:40:00.001-08:00</published><updated>2011-02-24T10:40:33.145-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Would it not work if you made judge_id NULL instead of -1?&lt;p&gt;&lt;br&gt;On 24/02/2011 16:52, David Mintz wrote:&lt;br&gt;&amp;gt; On Mon, Feb 21, 2011 at 6:44 PM, Bill Karwin&amp;lt;&lt;a href="mailto:bill@karwin.com"&gt;bill@karwin.com&lt;/a&gt;&amp;gt;  wrote:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t recommend&lt;br&gt;&amp;gt;&amp;gt; using it for any RDBMS, whether the RDBMS supports DRI or not.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; It is not possible to implement cascading referential integrity in a safe&lt;br&gt;&amp;gt;&amp;gt; manner in any application-space code.  It&amp;#39;s not a matter of the PHP code in&lt;br&gt;&amp;gt;&amp;gt; Zend_Db_Table being good enough, it&amp;#39;s simply not a task that can work&lt;br&gt;&amp;gt;&amp;gt; outside the database engine.  You need to enforce consistency through the&lt;br&gt;&amp;gt;&amp;gt; RDBMS engine.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; If that&amp;#39;s so, I would love to pick your brains about the following.&lt;br&gt;&amp;gt; (Coincidentally, the application is for tracking things that take place in a&lt;br&gt;&amp;gt; judicial system, as Rafael&amp;#39;s seems to be.) My apologies if this is getting&lt;br&gt;&amp;gt; OT.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I have a table called events:  things that happen in and around court that&lt;br&gt;&amp;gt; involve language interpreters. Every event has attributes like language_id,&lt;br&gt;&amp;gt; date, etc, and has has a related judge entity in ALMOST but not quite every&lt;br&gt;&amp;gt; instance! So there&amp;#39;s a table called judges. I am using DRI where I can in my&lt;br&gt;&amp;gt; events table, e.g:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;    CONSTRAINT `events_ibfk_2` FOREIGN KEY (`event_type_id`) REFERENCES&lt;br&gt;&amp;gt; `event_types` (`id`),&lt;br&gt;&amp;gt;    CONSTRAINT `events_ibfk_5` FOREIGN KEY (`location_id`) REFERENCES&lt;br&gt;&amp;gt; `locations` (`id`),&lt;br&gt;&amp;gt;    CONSTRAINT `events_ibfk_6` FOREIGN KEY (`language_id`) REFERENCES&lt;br&gt;&amp;gt; `languages` (`id`)&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; but I can&amp;#39;t do something like&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; CONSTRAINT `events_ibfk_7` FOREIGN KEY (`judge_id`) REFERENCES `judges`&lt;br&gt;&amp;gt; (`id`)&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; because there are some exceptional cases, as noted. My solution is to forgo&lt;br&gt;&amp;gt; DRI and try to enforce referential integrity at the application level. In&lt;br&gt;&amp;gt; `events`, my judge_id is signed, and a negative value like -1 means &amp;#39;not&lt;br&gt;&amp;gt; applicable&amp;#39; (to the application) and so forth.  At event insertion/update&lt;br&gt;&amp;gt; time I will go to great pains to enforce RI, e.g., by locking tables and&lt;br&gt;&amp;gt; making sure nobody has deleted judge so-and-so out from under me.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; What solution would you suggest?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Thanks!&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-9052631078070909332?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/9052631078070909332/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=9052631078070909332' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9052631078070909332'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9052631078070909332'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_8211.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6807390190278556853</id><published>2011-02-24T08:52:00.000-08:00</published><updated>2011-02-24T08:53:29.527-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>On Mon, Feb 21, 2011 at 6:44 PM, Bill Karwin &amp;lt;&lt;a href="mailto:bill@karwin.com"&gt;bill@karwin.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt; I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t recommend&lt;br&gt;&amp;gt; using it for any RDBMS, whether the RDBMS supports DRI or not.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; It is not possible to implement cascading referential integrity in a safe&lt;br&gt;&amp;gt; manner in any application-space code.  It&amp;#39;s not a matter of the PHP code in&lt;br&gt;&amp;gt; Zend_Db_Table being good enough, it&amp;#39;s simply not a task that can work&lt;br&gt;&amp;gt; outside the database engine.  You need to enforce consistency through the&lt;br&gt;&amp;gt; RDBMS engine.&lt;br&gt;&amp;gt;&lt;p&gt;If that&amp;#39;s so, I would love to pick your brains about the following.&lt;br&gt;(Coincidentally, the application is for tracking things that take place in a&lt;br&gt;judicial system, as Rafael&amp;#39;s seems to be.) My apologies if this is getting&lt;br&gt;OT.&lt;p&gt;I have a table called events:  things that happen in and around court that&lt;br&gt;involve language interpreters. Every event has attributes like language_id,&lt;br&gt;date, etc, and has has a related judge entity in ALMOST but not quite every&lt;br&gt;instance! So there&amp;#39;s a table called judges. I am using DRI where I can in my&lt;br&gt;events table, e.g:&lt;p&gt;  CONSTRAINT `events_ibfk_2` FOREIGN KEY (`event_type_id`) REFERENCES&lt;br&gt;`event_types` (`id`),&lt;br&gt;  CONSTRAINT `events_ibfk_5` FOREIGN KEY (`location_id`) REFERENCES&lt;br&gt;`locations` (`id`),&lt;br&gt;  CONSTRAINT `events_ibfk_6` FOREIGN KEY (`language_id`) REFERENCES&lt;br&gt;`languages` (`id`)&lt;p&gt;but I can&amp;#39;t do something like&lt;p&gt;CONSTRAINT `events_ibfk_7` FOREIGN KEY (`judge_id`) REFERENCES `judges`&lt;br&gt;(`id`)&lt;p&gt;because there are some exceptional cases, as noted. My solution is to forgo&lt;br&gt;DRI and try to enforce referential integrity at the application level. In&lt;br&gt;`events`, my judge_id is signed, and a negative value like -1 means &amp;#39;not&lt;br&gt;applicable&amp;#39; (to the application) and so forth.  At event insertion/update&lt;br&gt;time I will go to great pains to enforce RI, e.g., by locking tables and&lt;br&gt;making sure nobody has deleted judge so-and-so out from under me.&lt;p&gt;What solution would you suggest?&lt;p&gt;Thanks!&lt;p&gt;-- &lt;br&gt;David Mintz&lt;br&gt;&lt;a href="http://davidmintz.org/"&gt;http://davidmintz.org/&lt;/a&gt;&lt;br&gt;It ain&amp;#39;t over:&lt;br&gt;&lt;a href="http://www.healthcare-now.org/"&gt;http://www.healthcare-now.org/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6807390190278556853?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6807390190278556853/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6807390190278556853' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6807390190278556853'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6807390190278556853'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_24.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5465960793894540354</id><published>2011-02-24T02:53:00.000-08:00</published><updated>2011-02-24T02:54:02.972-08:00</updated><title type='text'>[fw-gdata] Bad request</title><content type='html'>Please advi&lt;br&gt;ce...&lt;br&gt;This code below returns&lt;p&gt;[code:protected] =&amp;gt; 400&lt;br&gt;[message:protected] =&amp;gt; Bad Request&lt;p&gt;Cannot figure out how to do it, xxx is correct in my code :)&lt;p&gt;$client = Zend_Gdata_ClientLogin::getHttpClient($email, $password,&lt;br&gt;Zend_Gdata_Gapps::AUTH_SERVICE_NAME);&lt;br&gt;$service = new Zend_Gdata_Gapps($client, $domain);&lt;br&gt;	&lt;br&gt;$get =&lt;br&gt;&amp;quot;&lt;a href="https://apps-apis.google.com/a/feeds/emailsettings/2.0/xxx.com/xxx/"&gt;https://apps-apis.google.com/a/feeds/emailsettings/2.0/xxx.com/xxx/&lt;/a&gt;&amp;quot;;&lt;br&gt;	&lt;br&gt;$client-&amp;gt;setUri($get);&lt;br&gt;$client-&amp;gt;request(&amp;#39;GET&amp;#39;);&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Bad-request-tp3322408p3322408.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Bad-request-tp3322408p3322408.html&lt;/a&gt;&lt;br&gt;Sent from the Zend gdata mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5465960793894540354?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5465960793894540354/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5465960793894540354' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5465960793894540354'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5465960793894540354'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-gdata-bad-request.html' title='[fw-gdata] Bad request'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5588199562837607186</id><published>2011-02-22T13:57:00.001-08:00</published><updated>2011-02-22T13:57:53.173-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Good thought Hector, but I do acknowledge the value to clean up  &lt;br&gt;promptly, if not online during a PHP request.  I wouldn&amp;#39;t let it go a  &lt;br&gt;month.&lt;p&gt;Another option is that as you delete database rows that reference  &lt;br&gt;associated files, add the filenames to a queue table of  &lt;br&gt;&amp;quot;files_to_delete&amp;quot;.  If you roll back, these rows are un-inserted, so  &lt;br&gt;it supports ACID.&lt;p&gt;Then write a script to be invoked by cron, which processes the queue  &lt;br&gt;and removes both the files and the rows from the queue table.&lt;p&gt;Usually I fall into the camp of &amp;quot;the database is not a queue,&amp;quot; but  &lt;br&gt;it&amp;#39;s more likely to work if you only have one client (the cron script)  &lt;br&gt;reading this queue.&lt;p&gt;Regards,&lt;br&gt;Bill Karwin&lt;p&gt;On Feb 22, 2011, at 12:17 PM, Hector Virgen wrote:&lt;p&gt;&amp;gt; Another way to look at it: space is cheap, your time is not. I  &lt;br&gt;&amp;gt; wouldn&amp;#39;t&lt;br&gt;&amp;gt; worry too much about cascading deletes leaving dangling files/rows.  &lt;br&gt;&amp;gt; You may&lt;br&gt;&amp;gt; be trying to solve a problem that really isn&amp;#39;t a problem in the  &lt;br&gt;&amp;gt; first place.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; But if you do find that your servers are running out of disk space  &lt;br&gt;&amp;gt; or your&lt;br&gt;&amp;gt; indexes are becoming too large, write a cron script that does clean  &lt;br&gt;&amp;gt; up once&lt;br&gt;&amp;gt; a month.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; *Hector Virgen*&lt;br&gt;&amp;gt; Sr. Web Developer&lt;br&gt;&amp;gt; &lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On Tue, Feb 22, 2011 at 12:11 PM, Bill Karwin &amp;lt;&lt;a href="mailto:bill@karwin.com"&gt;bill@karwin.com&lt;/a&gt;&amp;gt; wrote:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; On Feb 22, 2011, at 8:23 AM, Simone Cosci wrote:&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Il 22/02/2011 0.44, Bill Karwin ha scritto:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; recommend&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; using it for any RDBMS, whether the RDBMS supports DRI or not.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; How can a RDBMS cascading delete unlink files on the filesystem (eg.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; images of a product) ?&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; The correct solution is to unlink the files using application code,  &lt;br&gt;&amp;gt;&amp;gt; but not&lt;br&gt;&amp;gt;&amp;gt; in a handler for the delete() method of the ORM.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; What if you unlink files as part of the delete() method, but then  &lt;br&gt;&amp;gt;&amp;gt; you roll&lt;br&gt;&amp;gt;&amp;gt; back the transaction?  You don&amp;#39;t get the files back.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; You should unlink files *only* after you can confirm that the  &lt;br&gt;&amp;gt;&amp;gt; corresponding&lt;br&gt;&amp;gt;&amp;gt; SQL delete operations have succeeded, and you have committed the  &lt;br&gt;&amp;gt;&amp;gt; transaction&lt;br&gt;&amp;gt;&amp;gt; for those SQL operations.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; An alternative is to store files in BLOB columns in the database,  &lt;br&gt;&amp;gt;&amp;gt; instead&lt;br&gt;&amp;gt;&amp;gt; of on the filesystem.  Then you can use DRI to cascade deletes to  &lt;br&gt;&amp;gt;&amp;gt; them, and&lt;br&gt;&amp;gt;&amp;gt; you can roll back deletes if necessary.  It may make your database  &lt;br&gt;&amp;gt;&amp;gt; larger,&lt;br&gt;&amp;gt;&amp;gt; and make it less convenient to access the files.  But you asked for a&lt;br&gt;&amp;gt;&amp;gt; solution of cascading deletes to files.  Storing files in BLOBs  &lt;br&gt;&amp;gt;&amp;gt; works for&lt;br&gt;&amp;gt;&amp;gt; this requirement.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&amp;gt; Bill Karwin&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5588199562837607186?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5588199562837607186/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5588199562837607186' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5588199562837607186'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5588199562837607186'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_2390.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2179600832489298830</id><published>2011-02-22T12:17:00.000-08:00</published><updated>2011-02-22T12:18:09.526-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Another way to look at it: space is cheap, your time is not. I wouldn&amp;#39;t&lt;br&gt;worry too much about cascading deletes leaving dangling files/rows. You may&lt;br&gt;be trying to solve a problem that really isn&amp;#39;t a problem in the first place.&lt;p&gt;But if you do find that your servers are running out of disk space or your&lt;br&gt;indexes are becoming too large, write a cron script that does clean up once&lt;br&gt;a month.&lt;p&gt;--&lt;br&gt;*Hector Virgen*&lt;br&gt;Sr. Web Developer&lt;br&gt;&lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;p&gt;&lt;p&gt;On Tue, Feb 22, 2011 at 12:11 PM, Bill Karwin &amp;lt;&lt;a href="mailto:bill@karwin.com"&gt;bill@karwin.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; On Feb 22, 2011, at 8:23 AM, Simone Cosci wrote:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;  Il 22/02/2011 0.44, Bill Karwin ha scritto:&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t recommend&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; using it for any RDBMS, whether the RDBMS supports DRI or not.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; How can a RDBMS cascading delete unlink files on the filesystem (eg.&lt;br&gt;&amp;gt;&amp;gt; images of a product) ?&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; The correct solution is to unlink the files using application code, but not&lt;br&gt;&amp;gt; in a handler for the delete() method of the ORM.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; What if you unlink files as part of the delete() method, but then you roll&lt;br&gt;&amp;gt; back the transaction?  You don&amp;#39;t get the files back.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; You should unlink files *only* after you can confirm that the corresponding&lt;br&gt;&amp;gt; SQL delete operations have succeeded, and you have committed the transaction&lt;br&gt;&amp;gt; for those SQL operations.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; An alternative is to store files in BLOB columns in the database, instead&lt;br&gt;&amp;gt; of on the filesystem.  Then you can use DRI to cascade deletes to them, and&lt;br&gt;&amp;gt; you can roll back deletes if necessary.  It may make your database larger,&lt;br&gt;&amp;gt; and make it less convenient to access the files.  But you asked for a&lt;br&gt;&amp;gt; solution of cascading deletes to files.  Storing files in BLOBs works for&lt;br&gt;&amp;gt; this requirement.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Regards,&lt;br&gt;&amp;gt; Bill Karwin&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2179600832489298830?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2179600832489298830/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2179600832489298830' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2179600832489298830'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2179600832489298830'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_2475.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2729443240003999954</id><published>2011-02-22T12:11:00.001-08:00</published><updated>2011-02-22T12:11:34.740-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>On Feb 22, 2011, at 8:23 AM, Simone Cosci wrote:&lt;p&gt;&amp;gt; Il 22/02/2011 0.44, Bill Karwin ha scritto:&lt;br&gt;&amp;gt;&amp;gt; I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t  &lt;br&gt;&amp;gt;&amp;gt; recommend using it for any RDBMS, whether the RDBMS supports DRI or  &lt;br&gt;&amp;gt;&amp;gt; not.&lt;br&gt;&amp;gt; How can a RDBMS cascading delete unlink files on the filesystem (eg.  &lt;br&gt;&amp;gt; images of a product) ?&lt;p&gt;The correct solution is to unlink the files using application code,  &lt;br&gt;but not in a handler for the delete() method of the ORM.&lt;p&gt;What if you unlink files as part of the delete() method, but then you  &lt;br&gt;roll back the transaction?  You don&amp;#39;t get the files back.&lt;p&gt;You should unlink files *only* after you can confirm that the  &lt;br&gt;corresponding SQL delete operations have succeeded, and you have  &lt;br&gt;committed the transaction for those SQL operations.&lt;p&gt;An alternative is to store files in BLOB columns in the database,  &lt;br&gt;instead of on the filesystem.  Then you can use DRI to cascade deletes  &lt;br&gt;to them, and you can roll back deletes if necessary.  It may make your  &lt;br&gt;database larger, and make it less convenient to access the files.  But  &lt;br&gt;you asked for a solution of cascading deletes to files.  Storing files  &lt;br&gt;in BLOBs works for this requirement.&lt;p&gt;Regards,&lt;br&gt;Bill Karwin&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2729443240003999954?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2729443240003999954/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2729443240003999954' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2729443240003999954'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2729443240003999954'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_4785.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1151215942453866751</id><published>2011-02-22T08:23:00.001-08:00</published><updated>2011-02-22T08:23:33.709-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Il 22/02/2011 0.44, Bill Karwin ha scritto:&lt;br&gt;&amp;gt; I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t &lt;br&gt;&amp;gt; recommend using it for any RDBMS, whether the RDBMS supports DRI or not.&lt;br&gt;How can a RDBMS cascading delete unlink files on the filesystem (eg. &lt;br&gt;images of a product) ?&lt;br&gt;in some case you should consider to implement your own cascading &lt;br&gt;operation in your models (imho)&lt;br&gt;eg.&lt;p&gt;             $depTables = $this-&amp;gt;getTable()-&amp;gt;getDependentTables();&lt;br&gt;             if (!empty($depTables))&lt;br&gt;             {&lt;br&gt;                 /**&lt;br&gt;                  * Foreach dependent table instantiate the model&lt;br&gt;                  * and call -&amp;gt;delete() on each of them&lt;br&gt;                  */&lt;br&gt;                 foreach($depTables as $tableName)&lt;br&gt;                 {&lt;br&gt;                     $modelName = str_replace(&amp;#39;DbTable_&amp;#39;, &amp;#39;&amp;#39;, $tableName);&lt;br&gt;                     $depModel = new $modelName();&lt;br&gt;                     $depTable = $depModel-&amp;gt;getTable();&lt;br&gt;                     $reference = &lt;br&gt;$depTable-&amp;gt;getReference(get_class($table));&lt;p&gt;                     switch ($reference[&amp;#39;onDelete&amp;#39;])&lt;br&gt;                     {&lt;br&gt;                         case Zend_Db_Table::CASCADE:&lt;br&gt;                             &lt;br&gt;if(count($depTable-&amp;gt;info(Zend_Db_Table::PRIMARY)) &amp;gt; 1)&lt;br&gt;                             {&lt;br&gt;                                 $depTable-&amp;gt;delete(&lt;br&gt;                                     &lt;br&gt;$depTable-&amp;gt;getAdapter()-&amp;gt;quoteInto($reference[&amp;#39;columns&amp;#39;][0] . &amp;#39; = ?&amp;#39;, $id)&lt;br&gt;                                 );&lt;br&gt;                                 break;&lt;br&gt;                             }&lt;br&gt;                             $select = $depTable-&amp;gt;getAdapter()&lt;br&gt;                                                -&amp;gt;select()&lt;br&gt;                                                -&amp;gt;distinct()&lt;br&gt;                                                &lt;br&gt;-&amp;gt;from($depTable-&amp;gt;info(Zend_Db_Table::NAME), &lt;br&gt;array($reference[&amp;#39;refColumns&amp;#39;][0]))&lt;br&gt;                                                &lt;br&gt;-&amp;gt;where($reference[&amp;#39;columns&amp;#39;][0] . &amp;#39; = ?&amp;#39;, $id);&lt;p&gt;                             $toBeDeleted = &lt;br&gt;$depTable-&amp;gt;getAdapter()-&amp;gt;fetchCol($select);&lt;p&gt;                             foreach($toBeDeleted as $idToDelete)&lt;br&gt;                                 $depModel-&amp;gt;delete($idToDelete);&lt;p&gt;                             break;&lt;p&gt;                         case Zend_Db_Table::RESTRICT:&lt;br&gt;                             $select = $depTable-&amp;gt;getAdapter()&lt;br&gt;                                                -&amp;gt;select()&lt;br&gt;                                                -&amp;gt;distinct()&lt;br&gt;                                                &lt;br&gt;-&amp;gt;from($depTable-&amp;gt;info(Zend_Db_Table::NAME), &lt;br&gt;array($reference[&amp;#39;refColumns&amp;#39;][0]))&lt;br&gt;                                                &lt;br&gt;-&amp;gt;where($reference[&amp;#39;columns&amp;#39;][0] . &amp;#39; = ?&amp;#39;, $id);&lt;p&gt;                             $toBeDeleted = &lt;br&gt;$depTable-&amp;gt;getAdapter()-&amp;gt;fetchCol($select);&lt;p&gt;                             if (count($toBeDeleted) &amp;gt; 0)&lt;br&gt;                                 throw new Planet_Exception(&amp;#39;Can\&amp;#39;t &lt;br&gt;delete restricted reference in &amp;#39;.get_class($depTable));&lt;p&gt;                             break;&lt;p&gt;                         default:&lt;br&gt;                             continue;&lt;br&gt;                     }&lt;br&gt;                 }&lt;br&gt;             }&lt;br&gt;             $n += $row-&amp;gt;delete();&lt;br&gt;             $this-&amp;gt;notify(__METHOD__, array($primaryKey =&amp;gt; $id));&lt;p&gt;-- &lt;br&gt;________________________________________&lt;br&gt;Simone Cosci - NextIdea&lt;br&gt;Software engineering&lt;br&gt;Planet S.r.l. Sistemi informatici&lt;br&gt;Via Giorgio Ambrosoli, 39&lt;br&gt;50018, Scandicci, Firenze, Italy&lt;br&gt;WEB     &lt;a href="http://www.planetweb.it"&gt;http://www.planetweb.it&lt;/a&gt;&lt;br&gt;E-Mail  &lt;a href="mailto:s.cosci@nextidea.it"&gt;s.cosci@nextidea.it&lt;/a&gt;&lt;br&gt;Tel.    +39 055 7350271 / 4630416&lt;br&gt;Fax.    +39 055 7351109&lt;br&gt;Cell.    +39 339 8672146&lt;br&gt;Voip.    +39 055 5357896&lt;br&gt;________________________________________&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1151215942453866751?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1151215942453866751/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1151215942453866751' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1151215942453866751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1151215942453866751'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_22.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1923691038220416980</id><published>2011-02-22T07:24:00.001-08:00</published><updated>2011-02-22T07:24:54.198-08:00</updated><title type='text'>[fw-mvc] Exceptions in resources</title><content type='html'>Hi,&lt;p&gt;Always wondered why not all exceptions caught automatically.&lt;br&gt;I used to wrap app run call in try{} but I&amp;#39;m not sure if it&amp;#39;s good.&lt;br&gt;So basically, what&amp;#39;s the best way to catch all exceptions in ZF and/or&lt;br&gt;exceptions in custom application resources (which I&amp;#39;m trying to refactor&lt;br&gt;right now)?&lt;p&gt;Regards,&lt;br&gt;Kostia&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1923691038220416980?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1923691038220416980/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1923691038220416980' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1923691038220416980'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1923691038220416980'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-exceptions-in-resources.html' title='[fw-mvc] Exceptions in resources'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6090151253308395693</id><published>2011-02-21T15:44:00.001-08:00</published><updated>2011-02-21T15:44:50.364-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>I coded the cascading functionality in Zend_Db_Table.  I don&amp;#39;t  &lt;br&gt;recommend using it for any RDBMS, whether the RDBMS supports DRI or not.&lt;p&gt;It is not possible to implement cascading referential integrity in a  &lt;br&gt;safe manner in any application-space code.  It&amp;#39;s not a matter of the  &lt;br&gt;PHP code in Zend_Db_Table being good enough, it&amp;#39;s simply not a task  &lt;br&gt;that can work outside the database engine.  You need to enforce  &lt;br&gt;consistency through the RDBMS engine.&lt;p&gt;If your application requires cascading referential integrity, use a  &lt;br&gt;storage engine that supports it, such as InnoDB, and declare RDBMS  &lt;br&gt;constraints.&lt;p&gt;If you use a database engine that doesn&amp;#39;t support DRI constraints,  &lt;br&gt;then you can&amp;#39;t rely on referential integrity and cannot use cascading  &lt;br&gt;RI operations.  Don&amp;#39;t try to use application-space cascading DRI.  It  &lt;br&gt;doesn&amp;#39;t work.&lt;p&gt;If I have not stated my recommendation plainly enough, feel free to  &lt;br&gt;ask for clarification.  :-)&lt;p&gt;Regards,&lt;br&gt;Bill Karwin&lt;p&gt;On Feb 21, 2011, at 8:39 AM, Rafael wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; I have read but it says clearly &amp;quot;it is intended&amp;quot; it doesn&amp;#39;t says it  &lt;br&gt;&amp;gt; won&amp;#39;t work. So I will test with MyISAM engine.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Thanks&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Em 21/02/2011 13:27, Christian Proske escreveu:&lt;br&gt;&amp;gt;&amp;gt; Hy Rafael,&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; have u read this:&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; &amp;quot;Declaring cascading operations in Zend_Db_Table is intended only  &lt;br&gt;&amp;gt;&amp;gt; for RDBMS brands that do not support declarative referential  &lt;br&gt;&amp;gt;&amp;gt; integrity (DRI).&amp;quot;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Source:&lt;a href="http://framework.zend.com/manual/en/zend.db.table.relationships.html"&gt;http://framework.zend.com/manual/en/zend.db.table.relationships.html&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; So I think that means it is NOT possible to implement DRI in ZF  &lt;br&gt;&amp;gt;&amp;gt; with InnoDB, because InnoDB supportes DRI.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Please correct me if I&amp;#39;m wrong.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; For more information on how to InnoDB&amp;amp;  Foreign Key Constraints:&lt;a href="http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html"&gt;http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&amp;gt; Chris&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Am 21.02.2011 um 17:12 schrieb Rafael:&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;  &amp;gt;  Well, It doesn&amp;#39;t thorows a exception but give that notice,  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; my code to delete the row is below&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;  &amp;gt;  function deletarID($id) {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;  &amp;gt;          $processo = $this-&amp;gt;find($id);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;  &amp;gt;          $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;  &amp;gt;          return $result;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;      }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;  &amp;gt;  &amp;gt;  Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  Hi,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &amp;gt;&amp;gt;  Can you please provide an actual code used by you to  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; delete row, that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  throws mentioned error?&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &amp;gt;&amp;gt;  Regards,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  Joseph Chereshnovsky&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &amp;gt;&amp;gt;  On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  Hello,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  I don&amp;#39;t know if it is the right to ask however i have  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; one issue that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  nobody else managed to solve it.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; configured with&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  InnoDB engine. I&amp;#39;m trying to make a relationship between  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; two tables&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  to apply cascade deletion but deletes only parental row and  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; return me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; line 1197&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  It happens when i try to delete one row from the model&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  Application_Model_ProcessosJudicial , I really can&amp;#39;t see  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; anything wrong&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  in the code or...&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  I would be thankful if anyone check it for me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  class Application_Model_ProcessosJudicial extends  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;        protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        protected $_dependentTables =  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;        protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refTableClass&amp;#39; =&amp;gt;    &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  class Application_Model_Andamentos extends  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;        protected $_name =  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;        protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refTableClass&amp;#39; =&amp;gt;    &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  My table structure&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  CREATE TABLE IF NOT EXISTS  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `andamento` varchar(60) CHARACTER SET latin1 DEFAULT  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `complemento` varchar(60) CHARACTER SET latin1 DEFAULT  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `tipo_processo` varchar(45) CHARACTER SET latin1  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `numero_antigo` varchar(30) CHARACTER SET latin1  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `circunscricao` varchar(30) CHARACTER SET latin1  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `encerrado_motivo` varchar(45) CHARACTER SET latin1  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `percentual` varchar(30) CHARACTER SET latin1 DEFAULT  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;  &amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &amp;gt;&amp;gt;  &amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6090151253308395693?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6090151253308395693/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6090151253308395693' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6090151253308395693'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6090151253308395693'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_8100.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1479801936281338520</id><published>2011-02-21T14:01:00.000-08:00</published><updated>2011-02-21T14:03:17.899-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>The problem was resolved by adding keys to the model&lt;p&gt;  $_primary = array(&amp;#39;id&amp;#39;,&amp;#39;numero_atual&amp;#39;);&lt;p&gt;Anyway&lt;p&gt;Thank you&lt;p&gt;&lt;br&gt;Em 21/02/2011 19:00, Joseph007 escreveu:&lt;br&gt;&amp;gt; It looks like an error.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; If you could implement a simplest code to reproduce this issue and file&lt;br&gt;&amp;gt; a ticket on bug-tracker.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Or just attach ZIP with that code to you message here, that will allow&lt;br&gt;&amp;gt; anyone to run that code and easy reproduce the error on its development&lt;br&gt;&amp;gt; machine.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Joseph Chereshnovsky&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On Mon, 2011-02-21 at 14:09 -0300, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt; It doesn&amp;#39;t works with MyISAM also, So the problem is not with the&lt;br&gt;&amp;gt;&amp;gt; database engine.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Anyway thanks,&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Rafael&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Em 21/02/2011 13:27, Christian Proske escreveu:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Hy Rafael,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; have u read this:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;quot;Declaring cascading operations in Zend_Db_Table is intended only for RDBMS brands that do not support declarative referential integrity (DRI).&amp;quot;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Source: &lt;a href="http://framework.zend.com/manual/en/zend.db.table.relationships.html"&gt;http://framework.zend.com/manual/en/zend.db.table.relationships.html&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; So I think that means it is NOT possible to implement DRI in ZF with InnoDB, because InnoDB supportes DRI.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Please correct me if I&amp;#39;m wrong.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; For more information on how to InnoDB&amp;amp;   Foreign Key Constraints: &lt;a href="http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html"&gt;http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Chris&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Am 21.02.2011 um 17:12 schrieb Rafael:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Well, It doesn&amp;#39;t thorows a exception but give that notice, my code to delete the row is below&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; function deletarID($id) {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;          $processo = $this-&amp;gt;find($id);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;          $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;          return $result;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Hi,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Can you please provide an actual code used by you to delete row, that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; throws mentioned error?&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Joseph Chereshnovsky&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Hello,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I don&amp;#39;t know if it is the right to ask however i have one issue that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; nobody else managed to solve it.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; It happens when i try to delete one row from the model&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; in the code or...&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I would be thankful if anyone check it for me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;            &amp;#39;Andamento&amp;#39; =&amp;gt;    array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;columns&amp;#39; =&amp;gt;    array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;refColumns&amp;#39; =&amp;gt;    array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;refTableClass&amp;#39; =&amp;gt;    &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;onDelete&amp;#39; =&amp;gt;    self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;onUpdate&amp;#39; =&amp;gt;    self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;            )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;            &amp;#39;Andamento&amp;#39; =&amp;gt;    array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;refTableClass&amp;#39; =&amp;gt;    &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;refColumns&amp;#39; =&amp;gt;    array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;columns&amp;#39; =&amp;gt;    array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;onDelete&amp;#39; =&amp;gt;    self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;                &amp;#39;onUpdate&amp;#39; =&amp;gt;    self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;            )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;        );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; My table structure&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;      KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1479801936281338520?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1479801936281338520/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1479801936281338520' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1479801936281338520'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1479801936281338520'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_2581.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4247798713908374581</id><published>2011-02-21T14:00:00.001-08:00</published><updated>2011-02-21T14:00:42.330-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>It looks like an error. &lt;p&gt;If you could implement a simplest code to reproduce this issue and file&lt;br&gt;a ticket on bug-tracker.&lt;p&gt;Or just attach ZIP with that code to you message here, that will allow&lt;br&gt;anyone to run that code and easy reproduce the error on its development&lt;br&gt;machine.&lt;p&gt;Joseph Chereshnovsky&lt;p&gt;On Mon, 2011-02-21 at 14:09 -0300, Rafael wrote: &lt;br&gt;&amp;gt; It doesn&amp;#39;t works with MyISAM also, So the problem is not with the &lt;br&gt;&amp;gt; database engine.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Anyway thanks,&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Rafael&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Em 21/02/2011 13:27, Christian Proske escreveu:&lt;br&gt;&amp;gt; &amp;gt; Hy Rafael,&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; have u read this:&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; &amp;quot;Declaring cascading operations in Zend_Db_Table is intended only for RDBMS brands that do not support declarative referential integrity (DRI).&amp;quot;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Source: &lt;a href="http://framework.zend.com/manual/en/zend.db.table.relationships.html"&gt;http://framework.zend.com/manual/en/zend.db.table.relationships.html&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; So I think that means it is NOT possible to implement DRI in ZF with InnoDB, because InnoDB supportes DRI.&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Please correct me if I&amp;#39;m wrong.&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; For more information on how to InnoDB&amp;amp;  Foreign Key Constraints: &lt;a href="http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html"&gt;http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Regards,&lt;br&gt;&amp;gt; &amp;gt; Chris&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Am 21.02.2011 um 17:12 schrieb Rafael:&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt; Well, It doesn&amp;#39;t thorows a exception but give that notice, my code to delete the row is below&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt; function deletarID($id) {&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;         $processo = $this-&amp;gt;find($id);&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;         $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;         return $result;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;     }&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt; Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt; Hi,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt; Can you please provide an actual code used by you to delete row, that&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt; throws mentioned error?&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt; Joseph Chereshnovsky&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt; On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; Hello,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; I don&amp;#39;t know if it is the right to ask however i have one issue that&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; nobody else managed to solve it.&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; It happens when i try to delete one row from the model&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; in the code or...&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; I would be thankful if anyone check it for me&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_referenceMap = array(&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;           &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refTableClass&amp;#39; =&amp;gt;   &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;           )&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       );&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_referenceMap = array(&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;           &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refTableClass&amp;#39; =&amp;gt;   &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;           )&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;       );&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; My table structure&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     PRIMARY KEY (`id`),&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     PRIMARY KEY (`id`),&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;     KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4247798713908374581?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4247798713908374581/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4247798713908374581' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4247798713908374581'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4247798713908374581'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_3058.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3055807692003413486</id><published>2011-02-21T13:03:00.000-08:00</published><updated>2011-02-22T07:47:34.739-08:00</updated><title type='text'>[fw-db] plugging oracle in to my zend app</title><content type='html'>Hello all,&lt;p&gt;I have written my application to speak with a mySql database. My&lt;br&gt;understanding of the framework is that it conveniently wraps all the backend&lt;br&gt;calls and should allow me to simply change some configuration settings in&lt;br&gt;order to change databases.&lt;p&gt;I presume this is done in the application.ini file where I previously had&lt;br&gt;(currently commented out)&lt;p&gt;;resources.db.adapter = PDO_MYSQL&lt;br&gt;;resources.db.isDefaultTableAdapter = true&lt;br&gt;;resources.db.params.charset = &amp;quot;utf8&amp;quot;&lt;br&gt;;resources.db.params.host = &amp;quot;localhost&amp;quot;&lt;br&gt;;resources.db.params.username = &amp;quot;root&amp;quot;	&lt;br&gt;;resources.db.params.password = &amp;quot;&amp;quot;&lt;br&gt;;resources.db.params.dbname = &amp;quot;taw&amp;quot; &lt;p&gt;I have used this as a guide to pointing to my newly installed Oracle&lt;br&gt;database (with a new user &amp;quot;myUser&amp;quot;)&lt;p&gt;resources.db.adapter = PDO_OCI&lt;br&gt;resources.db.params.port = &amp;quot;8081&amp;quot;&lt;br&gt;resources.db.isDefaultTableAdapter = true&lt;br&gt;resources.db.params.charset = &amp;quot;utf8&amp;quot;&lt;br&gt;resources.db.params.host = &amp;quot;localhost&amp;quot;&lt;br&gt;resources.db.params.username = &amp;quot;myUser&amp;quot;	&lt;br&gt;resources.db.params.password = &amp;quot;myPassword&amp;quot;&lt;br&gt;resources.db.params.dbname = &amp;quot;xe&amp;quot;&lt;p&gt;I have also uncommented the following line in my php config file:&lt;br&gt;extension=php_pdo_oci.dll&lt;p&gt;As soon as I log in to my application I get the error:&lt;p&gt;Uncaught exception &amp;#39;PDOException&amp;#39; with message &amp;#39;SQLSTATE[HY000]:&lt;br&gt;pdo_oci_handle_factory: ORA-12537: TNS:connection closed&lt;br&gt;(ext\pdo_oci\oci_driver.c:579)&amp;#39; in&lt;br&gt;C:\xampp\htdocs\TAW\library\Zend\Db\Adapter\Pdo\Abstract.php:129 &lt;p&gt;I understand that this could be an Oracle configuration issue, I just want&lt;br&gt;to rule out the possibility of the problem being on the application side.&lt;p&gt;Note that my application works fine when connecting to the mySql database.&lt;br&gt;All params seem to be correct, as well.&lt;p&gt;Does anyone have any suggestions?&lt;p&gt;Thanks!&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/plugging-oracle-in-to-my-zend-app-tp3318114p3318114.html"&gt;http://zend-framework-community.634137.n4.nabble.com/plugging-oracle-in-to-my-zend-app-tp3318114p3318114.html&lt;/a&gt;&lt;br&gt;Sent from the Zend DB mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3055807692003413486?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3055807692003413486/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3055807692003413486' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3055807692003413486'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3055807692003413486'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-db-plugging-oracle-in-to-my-zend-app.html' title='[fw-db] plugging oracle in to my zend app'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-509746387647147432</id><published>2011-02-21T09:09:00.000-08:00</published><updated>2011-02-21T09:11:26.042-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>It doesn&amp;#39;t works with MyISAM also, So the problem is not with the &lt;br&gt;database engine.&lt;p&gt;Anyway thanks,&lt;p&gt;Rafael&lt;p&gt;Em 21/02/2011 13:27, Christian Proske escreveu:&lt;br&gt;&amp;gt; Hy Rafael,&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; have u read this:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;quot;Declaring cascading operations in Zend_Db_Table is intended only for RDBMS brands that do not support declarative referential integrity (DRI).&amp;quot;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Source: &lt;a href="http://framework.zend.com/manual/en/zend.db.table.relationships.html"&gt;http://framework.zend.com/manual/en/zend.db.table.relationships.html&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; So I think that means it is NOT possible to implement DRI in ZF with InnoDB, because InnoDB supportes DRI.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Please correct me if I&amp;#39;m wrong.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; For more information on how to InnoDB&amp;amp;  Foreign Key Constraints: &lt;a href="http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html"&gt;http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Regards,&lt;br&gt;&amp;gt; Chris&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Am 21.02.2011 um 17:12 schrieb Rafael:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Well, It doesn&amp;#39;t thorows a exception but give that notice, my code to delete the row is below&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; function deletarID($id) {&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;         $processo = $this-&amp;gt;find($id);&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;         $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;         return $result;&lt;br&gt;&amp;gt;&amp;gt;     }&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Hi,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Can you please provide an actual code used by you to delete row, that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; throws mentioned error?&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Joseph Chereshnovsky&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Hello,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I don&amp;#39;t know if it is the right to ask however i have one issue that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; nobody else managed to solve it.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; It happens when i try to delete one row from the model&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; in the code or...&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I would be thankful if anyone check it for me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;           &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refTableClass&amp;#39; =&amp;gt;   &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;           )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;           &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refTableClass&amp;#39; =&amp;gt;   &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;               &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;           )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;       );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; My table structure&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;     KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-509746387647147432?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/509746387647147432/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=509746387647147432' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/509746387647147432'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/509746387647147432'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_3876.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8880330425802937751</id><published>2011-02-21T08:39:00.000-08:00</published><updated>2011-02-21T08:41:46.907-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>I have read but it says clearly &amp;quot;it is intended&amp;quot; it doesn&amp;#39;t says it &lt;br&gt;won&amp;#39;t work. So I will test with MyISAM engine.&lt;p&gt;Thanks&lt;p&gt;Em 21/02/2011 13:27, Christian Proske escreveu:&lt;br&gt;&amp;gt; Hy Rafael,&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; have u read this:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;quot;Declaring cascading operations in Zend_Db_Table is intended only for RDBMS brands that do not support declarative referential integrity (DRI).&amp;quot;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Source:&lt;a href="http://framework.zend.com/manual/en/zend.db.table.relationships.html"&gt;http://framework.zend.com/manual/en/zend.db.table.relationships.html&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; So I think that means it is NOT possible to implement DRI in ZF with InnoDB, because InnoDB supportes DRI.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Please correct me if I&amp;#39;m wrong.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; For more information on how to InnoDB&amp;amp;  Foreign Key Constraints:&lt;a href="http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html"&gt;http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Regards,&lt;br&gt;&amp;gt; Chris&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Am 21.02.2011 um 17:12 schrieb Rafael:&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  Well, It doesn&amp;#39;t thorows a exception but give that notice, my code to delete the row is below&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  function deletarID($id) {&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;          $processo = $this-&amp;gt;find($id);&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;          $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;          return $result;&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;      }&lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;  Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  Hi,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  Can you please provide an actual code used by you to delete row, that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  throws mentioned error?&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  Regards,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  Joseph Chereshnovsky&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  Hello,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  I don&amp;#39;t know if it is the right to ask however i have one issue that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  nobody else managed to solve it.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  It happens when i try to delete one row from the model&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  in the code or...&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  I would be thankful if anyone check it for me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refTableClass&amp;#39; =&amp;gt;   &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            &amp;#39;Andamento&amp;#39; =&amp;gt;   array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refTableClass&amp;#39; =&amp;gt;   &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;refColumns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;columns&amp;#39; =&amp;gt;   array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onDelete&amp;#39; =&amp;gt;   self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;                &amp;#39;onUpdate&amp;#39; =&amp;gt;   self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;            )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;        );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  My table structure&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;      KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;gt;&amp;gt;  &lt;br&gt;&amp;gt;&amp;gt; &amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8880330425802937751?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8880330425802937751/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8880330425802937751' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8880330425802937751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8880330425802937751'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_4180.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-546194400819114843</id><published>2011-02-21T08:27:00.000-08:00</published><updated>2011-02-21T08:28:13.350-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Hy Rafael,&lt;p&gt;have u read this:&lt;p&gt;&amp;quot;Declaring cascading operations in Zend_Db_Table is intended only for RDBMS brands that do not support declarative referential integrity (DRI). &amp;quot;&lt;p&gt;Source: &lt;a href="http://framework.zend.com/manual/en/zend.db.table.relationships.html"&gt;http://framework.zend.com/manual/en/zend.db.table.relationships.html&lt;/a&gt;&lt;p&gt;So I think that means it is NOT possible to implement DRI in ZF with InnoDB, because InnoDB supportes DRI.&lt;p&gt;Please correct me if I&amp;#39;m wrong.&lt;p&gt;For more information on how to InnoDB &amp;amp; Foreign Key Constraints: &lt;a href="http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html"&gt;http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html&lt;/a&gt;&lt;p&gt;Regards, &lt;br&gt;Chris&lt;p&gt;Am 21.02.2011 um 17:12 schrieb Rafael:&lt;p&gt;&amp;gt; &lt;br&gt;&amp;gt; Well, It doesn&amp;#39;t thorows a exception but give that notice, my code to delete the row is below&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; function deletarID($id) {&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;        $processo = $this-&amp;gt;find($id);&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;        $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;        return $result;&lt;br&gt;&amp;gt;    }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt;&amp;gt; Hi,&lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; Can you please provide an actual code used by you to delete row, that&lt;br&gt;&amp;gt;&amp;gt; throws mentioned error?&lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&amp;gt; Joseph Chereshnovsky&lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Hello,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; I don&amp;#39;t know if it is the right to ask however i have one issue that&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; nobody else managed to solve it.&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; It happens when i try to delete one row from the model&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; in the code or...&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; I would be thankful if anyone check it for me&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;          &amp;#39;Andamento&amp;#39; =&amp;gt;  array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;columns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;refColumns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;refTableClass&amp;#39; =&amp;gt;  &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;onDelete&amp;#39; =&amp;gt;  self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;onUpdate&amp;#39; =&amp;gt;  self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;          )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;          &amp;#39;Andamento&amp;#39; =&amp;gt;  array(&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;refTableClass&amp;#39; =&amp;gt;  &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;refColumns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;columns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;onDelete&amp;#39; =&amp;gt;  self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;              &amp;#39;onUpdate&amp;#39; =&amp;gt;  self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;          )&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;      );&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; My table structure&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;    KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-546194400819114843?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/546194400819114843/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=546194400819114843' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/546194400819114843'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/546194400819114843'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_7742.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2925215155831813781</id><published>2011-02-21T08:12:00.000-08:00</published><updated>2011-02-21T08:14:14.782-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Well, It doesn&amp;#39;t thorows a exception but give that notice, my code to &lt;br&gt;delete the row is below&lt;p&gt;function deletarID($id) {&lt;p&gt;         $processo = $this-&amp;gt;find($id);&lt;p&gt;         $result = $processo-&amp;gt;current()-&amp;gt;delete();&lt;p&gt;         return $result;&lt;br&gt;     }&lt;p&gt;&lt;br&gt;Em 21/02/2011 06:43, Joseph007 escreveu:&lt;br&gt;&amp;gt; Hi,&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Can you please provide an actual code used by you to delete row, that&lt;br&gt;&amp;gt; throws mentioned error?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Regards,&lt;br&gt;&amp;gt; Joseph Chereshnovsky&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote:&lt;br&gt;&amp;gt;&amp;gt; Hello,&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; I don&amp;#39;t know if it is the right to ask however i have one issue that&lt;br&gt;&amp;gt;&amp;gt; nobody else managed to solve it.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with&lt;br&gt;&amp;gt;&amp;gt; InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt;&amp;gt; to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Notice: Undefined index: numero_atual in&lt;br&gt;&amp;gt;&amp;gt; C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; It happens when i try to delete one row from the model&lt;br&gt;&amp;gt;&amp;gt; Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong&lt;br&gt;&amp;gt;&amp;gt; in the code or...&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; I would be thankful if anyone check it for me&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;       protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;       protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;       protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;           &amp;#39;Andamento&amp;#39; =&amp;gt;  array(&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;columns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;refColumns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;refTableClass&amp;#39; =&amp;gt;  &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;onDelete&amp;#39; =&amp;gt;  self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;onUpdate&amp;#39; =&amp;gt;  self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;           )&lt;br&gt;&amp;gt;&amp;gt;       );&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;       protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;       protected $_referenceMap = array(&lt;br&gt;&amp;gt;&amp;gt;           &amp;#39;Andamento&amp;#39; =&amp;gt;  array(&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;refTableClass&amp;#39; =&amp;gt;  &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;refColumns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;columns&amp;#39; =&amp;gt;  array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;onDelete&amp;#39; =&amp;gt;  self::CASCADE,&lt;br&gt;&amp;gt;&amp;gt;               &amp;#39;onUpdate&amp;#39; =&amp;gt;  self::RESTRICT&lt;br&gt;&amp;gt;&amp;gt;           )&lt;br&gt;&amp;gt;&amp;gt;       );&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; }&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; My table structure&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;     `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;     `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;&amp;gt;     `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;     KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;&amp;gt;     `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;&amp;gt;     `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;&amp;gt;     `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;&amp;gt;     PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;&amp;gt;     KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2925215155831813781?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2925215155831813781/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2925215155831813781' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2925215155831813781'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2925215155831813781'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue_21.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2654086542776639099</id><published>2011-02-21T02:32:00.001-08:00</published><updated>2011-02-21T02:32:50.356-08:00</updated><title type='text'>[fw-mvc] Re: Zend_translate in Form</title><content type='html'>Hi Thomas,&lt;p&gt;&lt;br&gt;Thomas Weidner wrote:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Additionally, when you already set a default translator, you don&amp;#39;t need to &lt;br&gt;&amp;gt; add translation to the element again. Only when you use a textparser to &lt;br&gt;&amp;gt; extract these strings when you don&amp;#39;t have them anywhere else.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;p&gt;Are there any examples of these textparsers anywhere? I can&amp;#39;t seem to find a&lt;br&gt;lot of information about it anywhere, but it must be a big problem for&lt;br&gt;anyone with a large international code base. Are there any ZF components&lt;br&gt;that do this, or is there scope for such a component? Possibly part of&lt;br&gt;Zend_Tool? &lt;p&gt;-Johanna&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Zend-translate-in-Form-tp671453p3317118.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Zend-translate-in-Form-tp671453p3317118.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2654086542776639099?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2654086542776639099/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2654086542776639099' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2654086542776639099'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2654086542776639099'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-zendtranslate-in-form.html' title='[fw-mvc] Re: Zend_translate in Form'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-702099765535142764</id><published>2011-02-21T01:43:00.000-08:00</published><updated>2011-02-21T02:22:39.220-08:00</updated><title type='text'>Re: [fw-db] Zend_Db_Table Issue</title><content type='html'>Hi, &lt;p&gt;Can you please provide an actual code used by you to delete row, that&lt;br&gt;throws mentioned error?&lt;p&gt;Regards,&lt;br&gt;Joseph Chereshnovsky&lt;p&gt;On Wed, 2011-02-16 at 01:53 -0200, Rafael wrote: &lt;br&gt;&amp;gt; Hello,&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I don&amp;#39;t know if it is the right to ask however i have one issue that &lt;br&gt;&amp;gt; nobody else managed to solve it.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with &lt;br&gt;&amp;gt; InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;&amp;gt; to apply cascade deletion but deletes only parental row and return me&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Notice: Undefined index: numero_atual in &lt;br&gt;&amp;gt; C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; It happens when i try to delete one row from the model &lt;br&gt;&amp;gt; Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong &lt;br&gt;&amp;gt; in the code or...&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I would be thankful if anyone check it for me&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;      protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;&amp;gt;      protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;, &lt;br&gt;&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;);&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;      protected $_referenceMap = array(&lt;br&gt;&amp;gt;          &amp;#39;Andamento&amp;#39; =&amp;gt; array(&lt;br&gt;&amp;gt;              &amp;#39;columns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;              &amp;#39;refColumns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;              &amp;#39;refTableClass&amp;#39; =&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;&amp;gt;              &amp;#39;onDelete&amp;#39; =&amp;gt; self::CASCADE,&lt;br&gt;&amp;gt;              &amp;#39;onUpdate&amp;#39; =&amp;gt; self::RESTRICT&lt;br&gt;&amp;gt;          )&lt;br&gt;&amp;gt;      );&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; class Application_Model_Andamentos extends Zend_Db_table {&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;      protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;      protected $_referenceMap = array(&lt;br&gt;&amp;gt;          &amp;#39;Andamento&amp;#39; =&amp;gt; array(&lt;br&gt;&amp;gt;              &amp;#39;refTableClass&amp;#39; =&amp;gt; &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;&amp;gt;              &amp;#39;refColumns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;              &amp;#39;columns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;&amp;gt;              &amp;#39;onDelete&amp;#39; =&amp;gt; self::CASCADE,&lt;br&gt;&amp;gt;              &amp;#39;onUpdate&amp;#39; =&amp;gt; self::RESTRICT&lt;br&gt;&amp;gt;          )&lt;br&gt;&amp;gt;      );&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; My table structure&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;&amp;gt;    `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;    `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `data` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;    `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `observacao` longtext CHARACTER SET latin1,&lt;br&gt;&amp;gt;    `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;    KEY `numero` (`numero_atual`)&lt;br&gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;&amp;gt;    `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;&amp;gt;    `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;&amp;gt;    `data_distribuicao` date DEFAULT NULL,&lt;br&gt;&amp;gt;    `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;    `encerrado_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;    `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;    `suspenso_data` date DEFAULT NULL,&lt;br&gt;&amp;gt;    `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;&amp;gt;    `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;&amp;gt;    `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;    `criacao` datetime DEFAULT NULL,&lt;br&gt;&amp;gt;    PRIMARY KEY (`id`),&lt;br&gt;&amp;gt;    KEY `numero_atual` (`numero_atual`)&lt;br&gt;&amp;gt; ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-702099765535142764?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/702099765535142764/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=702099765535142764' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/702099765535142764'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/702099765535142764'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-db-zenddbtable-issue.html' title='Re: [fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5632675879830074526</id><published>2011-02-20T09:13:00.001-08:00</published><updated>2011-02-20T09:13:47.129-08:00</updated><title type='text'>[fw-gdata] Re: Retrieve a Link from event</title><content type='html'>For those who have the same question, I&amp;#39;ve found the solution:&lt;p&gt;This is done using:&lt;p&gt;$event-&amp;gt;getLink(&amp;#39;alternate&amp;#39;)-&amp;gt;getHref()&lt;p&gt;Solved!&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Retrieve-a-Link-from-event-tp3314259p3315282.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Retrieve-a-Link-from-event-tp3314259p3315282.html&lt;/a&gt;&lt;br&gt;Sent from the Zend gdata mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5632675879830074526?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5632675879830074526/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5632675879830074526' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5632675879830074526'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5632675879830074526'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-gdata-re-retrieve-link-from-event.html' title='[fw-gdata] Re: Retrieve a Link from event'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-7583703841087460820</id><published>2011-02-19T14:54:00.001-08:00</published><updated>2011-02-19T14:54:15.340-08:00</updated><title type='text'>Re: [fw-auth] Re: returning after calling Zend_Acl's isAllowed</title><content type='html'>On Saturday 19 Feb 2011 11:46:55 jordi wrote:&lt;br&gt;&amp;gt; Thank you both for these answers!&lt;br&gt;&amp;gt; I indeed didn&amp;#39;t turn on errors (which i now did in config.ini)&lt;br&gt;&amp;gt; And i also did&amp;#39;nt caught the exception, which i now solved.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; So : problem solved&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Would you people advise to always deal with every possible exception in&lt;br&gt;&amp;gt; Zend, this is often not done in the tutorials?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Ow and btw: i am a beginner zend programmer, but have Qt(C++) en Java&lt;br&gt;&amp;gt; experience.&lt;p&gt;If you use a Zend_Application instance, you automatically wrap all dispatch &lt;br&gt;calls and its hooks inside a try/catch. Every exception is then forwarded to &lt;br&gt;the errorController to display a user friendly error message.&lt;p&gt;Only if you use the Zend_Acl component as standalone, you need to take care of &lt;br&gt;the exceptions yourself.&lt;p&gt;Regards, Jurian&lt;br&gt;-- &lt;br&gt;Jurian Sluiman&lt;br&gt;Soflomo - &lt;a href="http://soflomo.com"&gt;http://soflomo.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-7583703841087460820?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/7583703841087460820/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=7583703841087460820' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7583703841087460820'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7583703841087460820'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-auth-re-returning-after-calling.html' title='Re: [fw-auth] Re: returning after calling Zend_Acl&apos;s isAllowed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5666516450239234127</id><published>2011-02-19T07:10:00.001-08:00</published><updated>2011-02-19T07:10:22.493-08:00</updated><title type='text'>[fw-gdata] Retrieve a Link from event</title><content type='html'>Hello!&lt;p&gt;I&amp;#39;m using Zend Gdata to access to a public calendar but I have a question:&lt;p&gt;Now I retieving only the name of the event (using $event-&amp;gt;title-&amp;gt;text) but I&lt;br&gt;want to retrieve a link to the event (similar to:&lt;br&gt;&lt;a href="http://www.google.com/calendar/event?eid=cXBvZGE3YWw5MHU3ZThpY3ZkNzF2dHVtc2tfMjAxMTAyMTlUMTcwMDAwWiBsdWlzZnJhbmNpc2NvbWFycXVlc0Bt&amp;amp;ctz=Europe/Lisbon"&gt;http://www.google.com/calendar/event?eid=cXBvZGE3YWw5MHU3ZThpY3ZkNzF2dHVtc2tfMjAxMTAyMTlUMTcwMDAwWiBsdWlzZnJhbmNpc2NvbWFycXVlc0Bt&amp;amp;ctz=Europe/Lisbon&lt;/a&gt;).&lt;p&gt;How can I do this?&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Retrieve-a-Link-from-event-tp3314259p3314259.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Retrieve-a-Link-from-event-tp3314259p3314259.html&lt;/a&gt;&lt;br&gt;Sent from the Zend gdata mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5666516450239234127?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5666516450239234127/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5666516450239234127' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5666516450239234127'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5666516450239234127'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-gdata-retrieve-link-from-event.html' title='[fw-gdata] Retrieve a Link from event'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4067619501024806268</id><published>2011-02-19T02:46:00.000-08:00</published><updated>2011-02-19T14:32:46.469-08:00</updated><title type='text'>[fw-auth] Re: returning after calling Zend_Acl's isAllowed</title><content type='html'>Thank you both for these answers!&lt;br&gt;I indeed didn&amp;#39;t turn on errors (which i now did in config.ini)&lt;br&gt;And i also did&amp;#39;nt caught the exception, which i now solved.&lt;p&gt;So : problem solved&lt;p&gt;Would you people advise to always deal with every possible exception in&lt;br&gt;Zend, this is often not done in the tutorials?&lt;p&gt;Ow and btw: i am a beginner zend programmer, but have Qt(C++) en Java&lt;br&gt;experience.&lt;p&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/returning-after-calling-Zend-Acl-s-isAllowed-tp3313453p3314055.html"&gt;http://zend-framework-community.634137.n4.nabble.com/returning-after-calling-Zend-Acl-s-isAllowed-tp3313453p3314055.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Auth mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4067619501024806268?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4067619501024806268/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4067619501024806268' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4067619501024806268'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4067619501024806268'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-auth-re-returning-after-calling.html' title='[fw-auth] Re: returning after calling Zend_Acl&apos;s isAllowed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-7627808492383797682</id><published>2011-02-19T01:19:00.001-08:00</published><updated>2011-02-19T01:19:44.831-08:00</updated><title type='text'>Re: [fw-auth] returning after calling Zend_Acl's isAllowed</title><content type='html'>On Friday 18 Feb 2011 21:01:54 jordi wrote:&lt;br&gt;&amp;gt; when I call Zend_Acl&amp;#39;s isAllowed(..) method with a role, resource, or&lt;br&gt;&amp;gt; privilege that is not specified I would say it would return false, but that&lt;br&gt;&amp;gt; does not seem to happen. It does not seem to return at all, or am I doing&lt;br&gt;&amp;gt; something wrong?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; my code:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; echo &amp;#39;one&amp;#39;;&lt;br&gt;&amp;gt; if(!$this-&amp;gt;_acl-&amp;gt;isAllowed(&amp;#39;blabla&amp;#39; ,&amp;#39;auth&amp;#39;, &amp;#39;login&amp;#39;)){&lt;br&gt;&amp;gt;      echo &amp;#39;two&amp;#39;;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; $request-&amp;gt;setControllerName(&amp;#39;authentication&amp;#39;)-&amp;gt;setActionName(&amp;#39;unauthorized&amp;#39;&lt;br&gt;&amp;gt; ); }&lt;br&gt;&amp;gt; echo &amp;#39;three&amp;#39;;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; // one is shown, two and three not&lt;p&gt;Afaik throws Zend_Acl an exception when you&amp;#39;re trying to get allowance for a &lt;br&gt;role and/or resource that is not set. The proper flag whether you can continue &lt;br&gt;is this:&lt;p&gt;($acl-&amp;gt;hasRole($role) &amp;amp;&amp;amp; $acl-&amp;gt;has($resource) &amp;amp;&amp;amp; $acl-&amp;gt;isAllowed($role, &lt;br&gt;$resource, $permission))&lt;p&gt;The combined check of role, resource and isAllowed gives the final true/false.&lt;p&gt;In this case you got an exception and probably saw nothing because you do not &lt;br&gt;catch this exception properly.&lt;p&gt;Regards, Jurian&lt;br&gt;-- &lt;br&gt;Jurian Sluiman&lt;br&gt;Soflomo - &lt;a href="http://soflomo.com"&gt;http://soflomo.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-7627808492383797682?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/7627808492383797682/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=7627808492383797682' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7627808492383797682'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/7627808492383797682'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-auth-returning-after-calling_19.html' title='Re: [fw-auth] returning after calling Zend_Acl&apos;s isAllowed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1002111223859818005</id><published>2011-02-18T14:50:00.001-08:00</published><updated>2011-02-18T14:50:42.505-08:00</updated><title type='text'>Re: [fw-auth] returning after calling Zend_Acl's isAllowed</title><content type='html'>hi,&lt;p&gt;do u have error reporting turned on?&lt;p&gt;Try:&lt;p&gt;error_reporting(E_ALL);&lt;br&gt;ini_set(&amp;#39;display_errors&amp;#39;,&amp;#39;On&amp;#39;);&lt;p&gt;before my code;&lt;p&gt;ciao&lt;p&gt;Am 18.02.2011 um 21:01 schrieb jordi:&lt;p&gt;&amp;gt; &lt;br&gt;&amp;gt; when I call Zend_Acl&amp;#39;s isAllowed(..) method with a role, resource, or&lt;br&gt;&amp;gt; privilege that is not specified I would say it would return false, but that&lt;br&gt;&amp;gt; does not seem to happen. It does not seem to return at all, or am I doing&lt;br&gt;&amp;gt; something wrong? &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; my code:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; echo &amp;#39;one&amp;#39;;&lt;br&gt;&amp;gt; if(!$this-&amp;gt;_acl-&amp;gt;isAllowed(&amp;#39;blabla&amp;#39; ,&amp;#39;auth&amp;#39;, &amp;#39;login&amp;#39;)){&lt;br&gt;&amp;gt;     echo &amp;#39;two&amp;#39;;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; $request-&amp;gt;setControllerName(&amp;#39;authentication&amp;#39;)-&amp;gt;setActionName(&amp;#39;unauthorized&amp;#39;);&lt;br&gt;&amp;gt; }&lt;br&gt;&amp;gt; echo &amp;#39;three&amp;#39;;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; // one is shown, two and three not&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; -- &lt;br&gt;&amp;gt; View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/returning-after-calling-Zend-Acl-s-isAllowed-tp3313453p3313453.html"&gt;http://zend-framework-community.634137.n4.nabble.com/returning-after-calling-Zend-Acl-s-isAllowed-tp3313453p3313453.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend Auth mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1002111223859818005?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1002111223859818005/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1002111223859818005' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1002111223859818005'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1002111223859818005'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-auth-returning-after-calling.html' title='Re: [fw-auth] returning after calling Zend_Acl&apos;s isAllowed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1455905843440309585</id><published>2011-02-18T12:01:00.000-08:00</published><updated>2011-02-18T14:28:09.999-08:00</updated><title type='text'>[fw-auth] returning after calling Zend_Acl's isAllowed</title><content type='html'>when I call Zend_Acl&amp;#39;s isAllowed(..) method with a role, resource, or&lt;br&gt;privilege that is not specified I would say it would return false, but that&lt;br&gt;does not seem to happen. It does not seem to return at all, or am I doing&lt;br&gt;something wrong? &lt;p&gt;my code:&lt;p&gt;echo &amp;#39;one&amp;#39;;&lt;br&gt;if(!$this-&amp;gt;_acl-&amp;gt;isAllowed(&amp;#39;blabla&amp;#39; ,&amp;#39;auth&amp;#39;, &amp;#39;login&amp;#39;)){&lt;br&gt;     echo &amp;#39;two&amp;#39;;&lt;br&gt;    &lt;br&gt;$request-&amp;gt;setControllerName(&amp;#39;authentication&amp;#39;)-&amp;gt;setActionName(&amp;#39;unauthorized&amp;#39;);&lt;br&gt;}&lt;br&gt;echo &amp;#39;three&amp;#39;;&lt;p&gt;// one is shown, two and three not&lt;p&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/returning-after-calling-Zend-Acl-s-isAllowed-tp3313453p3313453.html"&gt;http://zend-framework-community.634137.n4.nabble.com/returning-after-calling-Zend-Acl-s-isAllowed-tp3313453p3313453.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Auth mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1455905843440309585?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1455905843440309585/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1455905843440309585' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1455905843440309585'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1455905843440309585'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-auth-returning-after-calling.html' title='[fw-auth] returning after calling Zend_Acl&apos;s isAllowed'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6143873140016501000</id><published>2011-02-17T01:11:00.000-08:00</published><updated>2011-02-17T01:12:16.740-08:00</updated><title type='text'>Re: [fw-mvc] Sessions and passing them between websites</title><content type='html'>Hi Thomas,&lt;p&gt;If you really want to transfer form data between web sites, why you don&amp;#39;t&lt;br&gt;use something like a small soap server. I think that will be easy to make a&lt;br&gt;services that will have one request that will receive your data in json&lt;br&gt;format and then the soap event will continue your script .&lt;p&gt;If you want to use session, try Zend Sessions saved into the database. I&lt;br&gt;think that you can make both websites to use the same session table from the&lt;br&gt;same database. Also this method is protected against most of the session&lt;br&gt;hijacking attempts.&lt;p&gt;Many greetings,&lt;br&gt;Manuel&lt;p&gt;On Thu, Feb 17, 2011 at 3:19 AM, Peter Warnock &amp;lt;&lt;a href="mailto:petewarnock@gmail.com"&gt;petewarnock@gmail.com&lt;/a&gt;&amp;gt;wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;gt;&amp;gt; I believe that I need to save the form in a session variable and&lt;br&gt;&amp;gt; redirect the user to the Action Controller, I&amp;#39;m just not that sure how to go&lt;br&gt;&amp;gt;  about it. I haven&amp;#39;t done much work with Sessions, or forms which will post&lt;br&gt;&amp;gt; the entered information into a session variable.&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; Are you trying to generate some forms on a website and them processed&lt;br&gt;&amp;gt; them on ZF based website? And then need information about inputs to validate&lt;br&gt;&amp;gt; and filter them? If you do you could maybe serialize your form object either&lt;br&gt;&amp;gt; in a database or in a session (depending on your use) and then unserialize&lt;br&gt;&amp;gt; your form object to get full informations about how to process it.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Don&amp;#39;t pass sessions between servers unless you understand the security&lt;br&gt;&amp;gt; implications.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Post the data over SSL from a form served on Server A to the action on&lt;br&gt;&amp;gt; Server B.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On Server B&amp;#39;s controller, get the data from the request object and pass it&lt;br&gt;&amp;gt; to the model to validate/sanitize it using Zend_Form or Zend_Filter_Input.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;p&gt;&lt;br&gt;-- &lt;br&gt;Galiu Manuel&lt;br&gt;+40 741.060.684&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6143873140016501000?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6143873140016501000/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6143873140016501000' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6143873140016501000'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6143873140016501000'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-sessions-and-passing-them_17.html' title='Re: [fw-mvc] Sessions and passing them between websites'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-9020219719845933050</id><published>2011-02-16T18:19:00.000-08:00</published><updated>2011-02-16T18:20:30.765-08:00</updated><title type='text'>Re: [fw-mvc] Sessions and passing them between websites</title><content type='html'>&amp;gt;&amp;gt; I believe that I need to save the form in a session variable and redirect the user to the Action Controller, I&amp;#39;m just not that sure how to go  about it. I haven&amp;#39;t done much work with Sessions, or forms which will post the entered information into a session variable.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Are you trying to generate some forms on a website and them processed them on ZF based website? And then need information about inputs to validate and filter them? If you do you could maybe serialize your form object either in a database or in a session (depending on your use) and then unserialize your form object to get full informations about how to process it.&lt;p&gt;Don&amp;#39;t pass sessions between servers unless you understand the security implications.&lt;p&gt;Post the data over SSL from a form served on Server A to the action on Server B. &lt;p&gt;On Server B&amp;#39;s controller, get the data from the request object and pass it to the model to validate/sanitize it using Zend_Form or Zend_Filter_Input.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-9020219719845933050?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/9020219719845933050/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=9020219719845933050' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9020219719845933050'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/9020219719845933050'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-sessions-and-passing-them_16.html' title='Re: [fw-mvc] Sessions and passing them between websites'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6995411375910590638</id><published>2011-02-16T14:14:00.001-08:00</published><updated>2011-02-16T14:14:36.016-08:00</updated><title type='text'>Re: [fw-mvc] zend_mm_heap corrupted</title><content type='html'>Hi,&lt;p&gt;As a possible workaround increase the output_buffering in php.ini.&lt;p&gt;&lt;a href="http://stackoverflow.com/questions/2247977/what-does-zend-mm-heap-corrupted-mean"&gt;http://stackoverflow.com/questions/2247977/what-does-zend-mm-heap-corrupted-mean&lt;/a&gt;&lt;p&gt;&lt;br&gt;Am 16.02.2011 um 13:03 schrieb Darryle Steplight:&lt;p&gt;&amp;gt; Hi Everyone,&lt;br&gt;&amp;gt;     I was trying to initiate an ACL object in my app and everything went&lt;br&gt;&amp;gt; blank. All I see is white. When I comment out the line that creates my ACL&lt;br&gt;&amp;gt; object, the site comes back up. I checked my error logs and I noticed my&lt;br&gt;&amp;gt; code is producing this error &amp;quot;zend_mm_heap corrupted&amp;quot; . I&amp;#39;m developing on a&lt;br&gt;&amp;gt; MacBook and running ZendServer (if that helps). All the forums suggest I&lt;br&gt;&amp;gt; upgrade to the latest stable PHP release, preferably 5.2.9  . I&amp;#39;m currently&lt;br&gt;&amp;gt; using  PHP 5.2.14. Does anyone have any other suggestions that don&amp;#39;t involve&lt;br&gt;&amp;gt; upgrading PHP?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; -- &lt;br&gt;&amp;gt; ----------------------------------------------&lt;br&gt;&amp;gt; &amp;quot;May the Source be with you.&amp;quot;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6995411375910590638?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6995411375910590638/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6995411375910590638' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6995411375910590638'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6995411375910590638'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-zendmmheap-corrupted.html' title='Re: [fw-mvc] zend_mm_heap corrupted'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1647678412113090574</id><published>2011-02-16T04:03:00.001-08:00</published><updated>2011-02-16T04:03:16.337-08:00</updated><title type='text'>[fw-mvc] zend_mm_heap corrupted</title><content type='html'>Hi Everyone,&lt;br&gt;     I was trying to initiate an ACL object in my app and everything went&lt;br&gt;blank. All I see is white. When I comment out the line that creates my ACL&lt;br&gt;object, the site comes back up. I checked my error logs and I noticed my&lt;br&gt;code is producing this error &amp;quot;zend_mm_heap corrupted&amp;quot; . I&amp;#39;m developing on a&lt;br&gt;MacBook and running ZendServer (if that helps). All the forums suggest I&lt;br&gt;upgrade to the latest stable PHP release, preferably 5.2.9  . I&amp;#39;m currently&lt;br&gt;using  PHP 5.2.14. Does anyone have any other suggestions that don&amp;#39;t involve&lt;br&gt;upgrading PHP?&lt;p&gt;-- &lt;br&gt;----------------------------------------------&lt;br&gt;&amp;quot;May the Source be with you.&amp;quot;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1647678412113090574?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1647678412113090574/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1647678412113090574' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1647678412113090574'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1647678412113090574'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-zendmmheap-corrupted.html' title='[fw-mvc] zend_mm_heap corrupted'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5991871139057318595</id><published>2011-02-15T23:02:00.001-08:00</published><updated>2011-02-15T23:02:19.998-08:00</updated><title type='text'>[fw-mvc] Re: Application.ini / Arrays</title><content type='html'>Lionel,&lt;p&gt;Unless you&amp;#39;re on PHP5.3, strings in ini files need to be wrapped in double&lt;br&gt;quotes.&lt;br&gt;That probably explains why it works on your dev box, but not on your server.&lt;p&gt;Cheers,&lt;br&gt;David&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Application-ini-Arrays-tp3307850p3308270.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Application-ini-Arrays-tp3307850p3308270.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5991871139057318595?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5991871139057318595/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5991871139057318595' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5991871139057318595'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5991871139057318595'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-applicationini-arrays.html' title='[fw-mvc] Re: Application.ini / Arrays'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2826268671400732987</id><published>2011-02-15T19:53:00.000-08:00</published><updated>2011-02-15T19:54:53.751-08:00</updated><title type='text'>[fw-db] Zend_Db_Table Issue</title><content type='html'>Hello,&lt;p&gt;I don&amp;#39;t know if it is the right to ask however i have one issue that &lt;br&gt;nobody else managed to solve it.&lt;p&gt;I&amp;#39;m using zend framework 1.11.3, PHP 5.3 and MySQL 5.1 configured with &lt;br&gt;InnoDB engine. I&amp;#39;m trying to make a relationship between two tables&lt;br&gt;to apply cascade deletion but deletes only parental row and return me&lt;p&gt;Notice: Undefined index: numero_atual in &lt;br&gt;C:\htdocs\Advocacia\library\Zend\Db\Table\Abstract.php on line 1197&lt;p&gt;It happens when i try to delete one row from the model &lt;br&gt;Application_Model_ProcessosJudicial , I really can&amp;#39;t see anything wrong &lt;br&gt;in the code or...&lt;p&gt;I would be thankful if anyone check it for me&lt;p&gt;class Application_Model_ProcessosJudicial extends Zend_Db_table {&lt;p&gt;     protected $_name = &amp;quot;processos_judicial&amp;quot;;&lt;br&gt;     protected $_dependentTables = array(&amp;#39;Application_Model_Partes&amp;#39;, &lt;br&gt;&amp;#39;Application_Model_Andamentos&amp;#39;);&lt;p&gt;     protected $_referenceMap = array(&lt;br&gt;         &amp;#39;Andamento&amp;#39; =&amp;gt; array(&lt;br&gt;             &amp;#39;columns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;             &amp;#39;refColumns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;             &amp;#39;refTableClass&amp;#39; =&amp;gt; &amp;#39;Application_Model_Andamentos&amp;#39;,&lt;br&gt;             &amp;#39;onDelete&amp;#39; =&amp;gt; self::CASCADE,&lt;br&gt;             &amp;#39;onUpdate&amp;#39; =&amp;gt; self::RESTRICT&lt;br&gt;         )&lt;br&gt;     );&lt;p&gt;}&lt;p&gt;&lt;br&gt;class Application_Model_Andamentos extends Zend_Db_table {&lt;p&gt;     protected $_name = &amp;quot;processos_andamentos_judicial&amp;quot;;&lt;p&gt;     protected $_referenceMap = array(&lt;br&gt;         &amp;#39;Andamento&amp;#39; =&amp;gt; array(&lt;br&gt;             &amp;#39;refTableClass&amp;#39; =&amp;gt; &amp;#39;Application_Model_ProcessosJudicial&amp;#39;,&lt;br&gt;             &amp;#39;refColumns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;             &amp;#39;columns&amp;#39; =&amp;gt; array(&amp;#39;numero_atual&amp;#39;),&lt;br&gt;             &amp;#39;onDelete&amp;#39; =&amp;gt; self::CASCADE,&lt;br&gt;             &amp;#39;onUpdate&amp;#39; =&amp;gt; self::RESTRICT&lt;br&gt;         )&lt;br&gt;     );&lt;p&gt;}&lt;p&gt;My table structure&lt;p&gt;&lt;br&gt;CREATE TABLE IF NOT EXISTS `processos_andamentos_judicial` (&lt;br&gt;   `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;   `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `data` datetime DEFAULT NULL,&lt;br&gt;   `andamento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `complemento` varchar(60) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `observacao` longtext CHARACTER SET latin1,&lt;br&gt;   `tipo_processo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   PRIMARY KEY (`id`),&lt;br&gt;   KEY `numero` (`numero_atual`)&lt;br&gt;) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=12 ;&lt;p&gt;CREATE TABLE IF NOT EXISTS `processos_judicial` (&lt;br&gt;   `id` int(11) NOT NULL AUTO_INCREMENT,&lt;br&gt;   `numero_atual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `numero_antigo` varchar(30) CHARACTER SET latin1 DEFAULT &amp;#39;&amp;#39;,&lt;br&gt;   `data_distribuicao` date DEFAULT NULL,&lt;br&gt;   `orgao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `circunscricao` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `local` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `feito` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `rito` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `fase` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `encerrado` tinyint(1) DEFAULT NULL,&lt;br&gt;   `encerrado_data` date DEFAULT NULL,&lt;br&gt;   `encerrado_motivo` varchar(45) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `suspenso` tinyint(1) DEFAULT NULL,&lt;br&gt;   `suspenso_data` date DEFAULT NULL,&lt;br&gt;   `valor_causa` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `assistencia_gratuita` tinyint(1) DEFAULT NULL,&lt;br&gt;   `percentual` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `resumo` varchar(30) CHARACTER SET latin1 DEFAULT NULL,&lt;br&gt;   `ultima_modificao` datetime DEFAULT NULL,&lt;br&gt;   `criacao` datetime DEFAULT NULL,&lt;br&gt;   PRIMARY KEY (`id`),&lt;br&gt;   KEY `numero_atual` (`numero_atual`)&lt;br&gt;) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=43 ;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2826268671400732987?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2826268671400732987/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2826268671400732987' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2826268671400732987'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2826268671400732987'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-db-zenddbtable-issue.html' title='[fw-db] Zend_Db_Table Issue'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8233726547413863284</id><published>2011-02-15T15:26:00.001-08:00</published><updated>2011-02-15T15:26:32.136-08:00</updated><title type='text'>Re: [fw-mvc] Application.ini / Arrays</title><content type='html'>Good question,&lt;p&gt;When you call $bootstrap-&amp;gt;getOption(&amp;#39;recaptcha&amp;#39;); it returns an array. &lt;br&gt;So that give you the flexibility so it seems.&lt;p&gt;I&amp;#39;m fairly new to the Zend Framework so I&amp;#39;m just trying to feel my way &lt;br&gt;around and the application.ini seemed to be something that a book on &lt;br&gt;Zend showed and it seemed to make sense for keeping all your global &lt;br&gt;stuff like DB config, mail config etc all in one place. I decided that &lt;br&gt;it might be a good place to keep the content for my email massages as &lt;br&gt;well. A single location that&amp;#39;s that easy to access.&lt;p&gt;I&amp;#39;ll give the .x a try and see how that works out. Never occurred to me &lt;br&gt;to try something so simple.&lt;p&gt;&lt;br&gt;Thanks&lt;br&gt;Lionel&lt;p&gt;&lt;br&gt;On 2/15/11 6:18 PM, Dolf Schimmel wrote:&lt;br&gt;&amp;gt; Try:&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten.1 = &amp;#39;Email: [toemail /]&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten.2 = &amp;#39;Password: [password /]&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten.3 = &amp;#39;&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten.4 = &amp;#39;To change your password please open [domain /]&lt;br&gt;&amp;gt; Can I also ask you why you use .ini, and not something much more&lt;br&gt;&amp;gt; performant and flexible like php arrays?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Regards,&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Dolf&lt;br&gt;&amp;gt; -- Freeaqingme&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; On Wed, Feb 16, 2011 at 12:11 AM, Lionel Morrison&lt;br&gt;&amp;gt; &amp;lt;&lt;a href="mailto:lionel@morrison101.com"&gt;lionel@morrison101.com&lt;/a&gt;&amp;gt;  wrote:&lt;br&gt;&amp;gt;&amp;gt; What is the correct way to specify text array within the application.ini&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; This is what I currently have:&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten[] = &amp;#39;Email: [toemail /]&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten[] = &amp;#39;Password: [password /]&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten[] = &amp;#39;&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; mail.message.forgotten[] = &amp;#39;To change your password please open [domain /]&lt;br&gt;&amp;gt;&amp;gt; in your browser, login and use the form provided.&amp;#39;&lt;br&gt;&amp;gt;&amp;gt; recaptcha.pubKey   = 6LeqYcESAAAAAIa3LKABz7CxmyLu2N_gm1oIt74W&lt;br&gt;&amp;gt;&amp;gt; recaptcha.privKey  = ???&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Is this correct or is they a &amp;#39;preferred&amp;#39; method. I ask because on my local&lt;br&gt;&amp;gt;&amp;gt; server running 1.11 the application.ini works as expected. On my production&lt;br&gt;&amp;gt;&amp;gt; server running 1.10 (I think) it works but any thing that I specify after&lt;br&gt;&amp;gt;&amp;gt; the array element displays as NULL when called using the following method.&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; $bootstrap-&amp;gt;getOption(&amp;#39;recaptcha&amp;#39;);&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Thanks&lt;br&gt;&amp;gt;&amp;gt;&lt;br&gt;&amp;gt;&amp;gt; Lionel&lt;br&gt;&amp;gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8233726547413863284?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8233726547413863284/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8233726547413863284' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8233726547413863284'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8233726547413863284'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-applicationini-arrays.html' title='Re: [fw-mvc] Application.ini / Arrays'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1488445505735402816</id><published>2011-02-15T15:11:00.001-08:00</published><updated>2011-02-15T15:11:43.690-08:00</updated><title type='text'>[fw-mvc] Application.ini / Arrays</title><content type='html'>What is the correct way to specify text array within the application.ini&lt;p&gt;&lt;br&gt;This is what I currently have:&lt;p&gt;mail.message.forgotten[] = &amp;#39;Email: [toemail /]&amp;#39;&lt;br&gt;mail.message.forgotten[] = &amp;#39;Password: [password /]&amp;#39;&lt;br&gt;mail.message.forgotten[] = &amp;#39;&amp;#39;&lt;br&gt;mail.message.forgotten[] = &amp;#39;To change your password please open [domain &lt;br&gt;/] in your browser, login and use the form provided.&amp;#39;&lt;br&gt;recaptcha.pubKey   = 6LeqYcESAAAAAIa3LKABz7CxmyLu2N_gm1oIt74W&lt;br&gt;recaptcha.privKey  = ???&lt;p&gt;&lt;br&gt;Is this correct or is they a &amp;#39;preferred&amp;#39; method. I ask because on my &lt;br&gt;local server running 1.11 the application.ini works as expected. On my &lt;br&gt;production server running 1.10 (I think) it works but any thing that I &lt;br&gt;specify after the array element displays as NULL when called using the &lt;br&gt;following method.&lt;p&gt;$bootstrap-&amp;gt;getOption(&amp;#39;recaptcha&amp;#39;);&lt;p&gt;Thanks&lt;p&gt;Lionel&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1488445505735402816?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1488445505735402816/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1488445505735402816' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1488445505735402816'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1488445505735402816'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-applicationini-arrays.html' title='[fw-mvc] Application.ini / Arrays'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8684388371807066032</id><published>2011-02-15T14:32:00.000-08:00</published><updated>2011-02-15T14:52:04.592-08:00</updated><title type='text'>Re: [fw-mvc] Re: CSS/JS Includes</title><content type='html'>Hi,&lt;p&gt;I wrote an article about how i manage css files for my website, perhaps &lt;br&gt;you want to read it ;)&lt;p&gt;&lt;a href="http://www.chris.lu/en/news/show/4d5af902e7fbd/"&gt;http://www.chris.lu/en/news/show/4d5af902e7fbd/&lt;/a&gt;&lt;p&gt;chris&lt;p&gt;&lt;br&gt;Am 12.02.2011 01:06, schrieb Joe Balancio:&lt;br&gt;&amp;gt; Thanks for the links. I&amp;#39;ll definitely add the minify stuff.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; About this page: &lt;a href="http://devzone.zend.com/article/11760"&gt;http://devzone.zend.com/article/11760&lt;/a&gt;&lt;br&gt;&amp;gt; I like how simple and elegant the solution is to include js/css by&lt;br&gt;&amp;gt; controller and action. However, what if I have the same js that needs to be&lt;br&gt;&amp;gt; included in two different actions or two different controllers?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; In the comments of the above page, I found:&lt;br&gt;&amp;gt; &lt;a href="http://www.devpatch.com/2010/02/view-plugin/"&gt;http://www.devpatch.com/2010/02/view-plugin/&lt;/a&gt;&lt;br&gt;&amp;gt; I like what this person is saying, &amp;quot;In my approach loading up different&lt;br&gt;&amp;gt; CSS/JS files per controller is the exception not the rule.&amp;quot; Basically, have&lt;br&gt;&amp;gt; your global stuff, but treat it controller-specific and action-specific&lt;br&gt;&amp;gt; CSS/JS on a per-case basis (as needed). This is the solution my project is&lt;br&gt;&amp;gt; using, but if I&amp;#39;m managing several controllers and several actions, it will&lt;br&gt;&amp;gt; start to get messy and difficult to manage how all the different files are&lt;br&gt;&amp;gt; included.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; The idea I had in mind:&lt;br&gt;&amp;gt; CSS/JS will be managed through configuration (XML). CSS/JS will be targeted&lt;br&gt;&amp;gt; through routes and it will follow the same layout as the route&lt;br&gt;&amp;gt; configuration. Create a concept of bundles which are groups of CSS/JS that&lt;br&gt;&amp;gt; can be assigned to a route. Create concept of a global which will be&lt;br&gt;&amp;gt; included on every page. Create concept of templates from which routes will&lt;br&gt;&amp;gt; be allowed to inherit. A plugin will be responsible for including (and&lt;br&gt;&amp;gt; minifying) js/css based on the configuration.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Sample XML:&lt;br&gt;&amp;gt; &amp;lt;global&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;js&amp;gt;&lt;br&gt;&amp;gt;      &amp;lt;jquery&amp;gt;/js/jquery.js&amp;lt;/jquery&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;/js&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;css&amp;gt;&lt;br&gt;&amp;gt;     &amp;lt;main&amp;gt;/css/main.css&amp;lt;/main&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;/css&lt;br&gt;&amp;gt; &amp;lt;/global&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;about-route&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;css&amp;gt;&lt;br&gt;&amp;gt;      &amp;lt;about&amp;gt;/css/about.css&amp;lt;/about&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;/css&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;js&amp;gt;&lt;br&gt;&amp;gt;      &amp;lt;about&amp;gt;/js/about.js&amp;lt;/about&amp;gt;&lt;br&gt;&amp;gt; &amp;lt;/js&lt;br&gt;&amp;gt; &amp;lt;/about-route&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; -----&lt;br&gt;&amp;gt; - Joe&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8684388371807066032?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8684388371807066032/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8684388371807066032' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8684388371807066032'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8684388371807066032'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-re-cssjs-includes_15.html' title='Re: [fw-mvc] Re: CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8541329450802165742</id><published>2011-02-11T16:06:00.000-08:00</published><updated>2011-02-11T16:07:05.514-08:00</updated><title type='text'>[fw-mvc] Re: CSS/JS Includes</title><content type='html'>Thanks for the links. I&amp;#39;ll definitely add the minify stuff.&lt;p&gt;About this page: &lt;a href="http://devzone.zend.com/article/11760"&gt;http://devzone.zend.com/article/11760&lt;/a&gt;&lt;br&gt;I like how simple and elegant the solution is to include js/css by&lt;br&gt;controller and action. However, what if I have the same js that needs to be&lt;br&gt;included in two different actions or two different controllers?&lt;p&gt;In the comments of the above page, I found:&lt;br&gt;&lt;a href="http://www.devpatch.com/2010/02/view-plugin/"&gt;http://www.devpatch.com/2010/02/view-plugin/&lt;/a&gt;&lt;br&gt;I like what this person is saying, &amp;quot;In my approach loading up different&lt;br&gt;CSS/JS files per controller is the exception not the rule.&amp;quot; Basically, have&lt;br&gt;your global stuff, but treat it controller-specific and action-specific&lt;br&gt;CSS/JS on a per-case basis (as needed). This is the solution my project is&lt;br&gt;using, but if I&amp;#39;m managing several controllers and several actions, it will&lt;br&gt;start to get messy and difficult to manage how all the different files are&lt;br&gt;included.&lt;p&gt;The idea I had in mind:&lt;br&gt;CSS/JS will be managed through configuration (XML). CSS/JS will be targeted&lt;br&gt;through routes and it will follow the same layout as the route&lt;br&gt;configuration. Create a concept of bundles which are groups of CSS/JS that&lt;br&gt;can be assigned to a route. Create concept of a global which will be&lt;br&gt;included on every page. Create concept of templates from which routes will&lt;br&gt;be allowed to inherit. A plugin will be responsible for including (and&lt;br&gt;minifying) js/css based on the configuration.&lt;p&gt;Sample XML:&lt;br&gt;&amp;lt;global&amp;gt;&lt;br&gt;&amp;lt;js&amp;gt;&lt;br&gt;    &amp;lt;jquery&amp;gt;/js/jquery.js&amp;lt;/jquery&amp;gt;&lt;br&gt;&amp;lt;/js&amp;gt;&lt;br&gt;&amp;lt;css&amp;gt;&lt;br&gt;   &amp;lt;main&amp;gt;/css/main.css&amp;lt;/main&amp;gt;&lt;br&gt;&amp;lt;/css&lt;br&gt;&amp;lt;/global&amp;gt;&lt;p&gt;&amp;lt;about-route&amp;gt;&lt;br&gt;&amp;lt;css&amp;gt;&lt;br&gt;    &amp;lt;about&amp;gt;/css/about.css&amp;lt;/about&amp;gt;&lt;br&gt;&amp;lt;/css&amp;gt;&lt;br&gt;&amp;lt;js&amp;gt;&lt;br&gt;    &amp;lt;about&amp;gt;/js/about.js&amp;lt;/about&amp;gt;&lt;br&gt;&amp;lt;/js&lt;br&gt;&amp;lt;/about-route&amp;gt;&lt;p&gt;-----&lt;br&gt;- Joe&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3302244.html"&gt;http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3302244.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8541329450802165742?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8541329450802165742/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8541329450802165742' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8541329450802165742'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8541329450802165742'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-cssjs-includes_11.html' title='[fw-mvc] Re: CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8580258440119424098</id><published>2011-02-11T12:29:00.000-08:00</published><updated>2011-02-11T12:30:12.344-08:00</updated><title type='text'>[fw-db] Un minuto de su tiempo</title><content type='html'>*URGENTE CIRCULEN*&lt;p&gt;L&amp;#233;elo porfa:&lt;p&gt;Hola, me llamo *Oscar Alberto Gonzalez Jasso y s&amp;#237; existo*. Estudio en el Tec&lt;br&gt;Milenio Campus San Luis Potosi en 3&amp;#176; tetramestre y estoy pasando por este&lt;br&gt;mal momento. Mis datos completos est&amp;#225;n al final de este mail. Realmente&lt;br&gt;tengo ganas de vivir, tengo 20 a&amp;#241;os y si puedes ayudarme, estoy a tus&lt;br&gt;&amp;#243;rdenes, por favor, s&amp;#243;lo comun&amp;#237;cate conmigo. Mi padre me inspiro para&lt;br&gt;escribir este email y a creer en la gente y a tener esperanza en los dem&amp;#225;s y&lt;br&gt;a tener un d&amp;#237;a mas....un ma&amp;#241;ana. No se,  pero hoy estoy dando mi 100% y lo&lt;br&gt;&amp;#250;nico que pido es que mi mensaje se retransmita. Te quito 1 minuto, ay&amp;#250;dame&lt;br&gt;a salvar mi vida. Es muy f&amp;#225;cil, solo te pido tres favores:&lt;p&gt;El primero, por favor no borres este e-mail, cons&amp;#233;rvalo, y pregunta entre&lt;br&gt;tus familiares y amigos, el mundo da muchas vueltas y tal vez tu o alguien a&lt;br&gt;qui&amp;#233;n tu conoces me pueda ayudar.&lt;p&gt;2.-Si sabes de alguien que ya no tenga esperanzas de un nuevo d&amp;#237;a y que&lt;br&gt;quisiera donar un ri&amp;#241;&amp;#243;n, por favor, h&amp;#225;blame. &amp;#161;Yo s&amp;#243;lo necesito! uno, ninguno&lt;br&gt;de los m&amp;#237;os funciona. No quiero morir tengo toda una vida por delante.&lt;br&gt;      3.- Si me haces el favor de enviar este mensaje por la red, tengo&lt;br&gt;oportunidad de llegar a m&amp;#225;s personas y as&amp;#237; tengo m&amp;#225;s posibilidad de&lt;br&gt;encontrar un donador.&lt;p&gt;&lt;p&gt;Que Dios te colme de bendiciones por tu tiempo en estas&lt;br&gt;l&amp;#237;neas y disculpa las molestias.&lt;p&gt; *Oscar Alberto GOnzalez Jasso&lt;br&gt; *TEL.                     01-44-48-22-60-45           01-44-48-22-60-45&lt;br&gt;(San Luis Potosi San Luis Potosi)&lt;br&gt;Cel. 044-44-42-25-77-20&lt;br&gt;Tipo de sangre: &amp;#39;O&amp;#39; RH Positivo&lt;p&gt;NADA LES CUESTA MANDARLO, GRACIAS. Un abrazo...r&amp;#225;pido, pero&lt;br&gt;grande!!!!!!!!Borra la cola para no recargar la red y as&amp;#237; te das cuenta que&lt;br&gt;no es cadena de correos&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8580258440119424098?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8580258440119424098/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8580258440119424098' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8580258440119424098'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8580258440119424098'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-db-un-minuto-de-su-tiempo.html' title='[fw-db] Un minuto de su tiempo'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5771930252168578814</id><published>2011-02-11T12:06:00.000-08:00</published><updated>2011-02-11T12:07:11.163-08:00</updated><title type='text'>[fw-mvc] From using Zend_Dojo_Form causes javascript error</title><content type='html'>I have a form that extends Zend_Dojo_Form. When an Editor dijit is&lt;br&gt;used, some generated addOnLoad code is output by ZF. This bit of code&lt;br&gt;keeps erroring out and stops javascript execution.&lt;p&gt;According to firebug, the error is:&lt;p&gt;elementNode is null&lt;br&gt;[Break On This Error] while (elementNode.nodeName.toLowerCase() != &amp;#39;form&amp;#39;) {&lt;p&gt;&lt;br&gt;The html source of the editors with plugins list removed for clarity:&lt;p&gt;&amp;lt;input id=&amp;quot;summary&amp;quot; name=&amp;quot;summary&amp;quot; value=&amp;quot;&amp;quot; type=&amp;quot;hidden&amp;quot; /&amp;gt;&amp;lt;div&lt;br&gt;trim=&amp;quot;1&amp;quot; jsId=&amp;quot;summaryEditor&amp;quot; id=&amp;quot;summary-Editor&amp;quot; inheritWidth=&amp;quot;1&amp;quot;&lt;br&gt;height=&amp;quot;100px&amp;quot; required=&amp;quot;true&amp;quot; dojoType=&amp;quot;dijit.Editor&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br&gt;&amp;lt;noscript&amp;gt;&amp;lt;textarea name=&amp;quot;summary&amp;quot; id=&amp;quot;summary-Editor&amp;quot; trim=&amp;quot;1&amp;quot;&lt;br&gt;jsId=&amp;quot;summaryEditor&amp;quot; inheritWidth=&amp;quot;1&amp;quot; height=&amp;quot;100px&amp;quot; plugins=&amp;quot;&lt;br&gt;required=&amp;quot;true&amp;quot; dojoType=&amp;quot;dijit.Editor&amp;quot; rows=&amp;quot;24&amp;quot;&lt;br&gt;cols=&amp;quot;80&amp;quot;&amp;gt;&amp;lt;/textarea&amp;gt;&amp;lt;/noscript&amp;gt;&lt;p&gt;&amp;lt;input id=&amp;quot;content&amp;quot; name=&amp;quot;content&amp;quot; value=&amp;quot;&amp;quot; type=&amp;quot;hidden&amp;quot; /&amp;gt;&amp;lt;div&lt;br&gt;trim=&amp;quot;1&amp;quot; jsId=&amp;quot;contentEditor&amp;quot; id=&amp;quot;content-Editor&amp;quot; inheritWidth=&amp;quot;1&amp;quot;&lt;br&gt;height=&amp;quot;500px&amp;quot; required=&amp;quot;true&amp;quot; dojoType=&amp;quot;dijit.Editor&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br&gt;&amp;lt;noscript&amp;gt;&amp;lt;textarea name=&amp;quot;content&amp;quot; id=&amp;quot;content-Editor&amp;quot; trim=&amp;quot;1&amp;quot;&lt;br&gt;jsId=&amp;quot;contentEditor&amp;quot; inheritWidth=&amp;quot;1&amp;quot; height=&amp;quot;500px&amp;quot; required=&amp;quot;true&amp;quot;&lt;br&gt;dojoType=&amp;quot;dijit.Editor&amp;quot; rows=&amp;quot;24&amp;quot; cols=&amp;quot;80&amp;quot;&amp;gt;&amp;lt;/textarea&amp;gt;&amp;lt;/noscript&amp;gt;&lt;p&gt;The addOnLoad code:&lt;p&gt; dojo.addOnLoad(function() {&lt;br&gt;    var form = zend.findParentForm(dojo.byId(&amp;#39;summary&amp;#39;));&lt;br&gt;    dojo.connect(form, &amp;#39;submit&amp;#39;, function(e) {&lt;br&gt;        dojo.byId(&amp;#39;summary&amp;#39;).value =&lt;br&gt;dijit.byId(&amp;#39;summary-Editor&amp;#39;).getValue(false);&lt;br&gt;    });&lt;br&gt;});&lt;br&gt;    dojo.addOnLoad(function() {&lt;br&gt;    var form = zend.findParentForm(dojo.byId(&amp;#39;content&amp;#39;));&lt;br&gt;    dojo.connect(form, &amp;#39;submit&amp;#39;, function(e) {&lt;br&gt;        dojo.byId(&amp;#39;content&amp;#39;).value =&lt;br&gt;dijit.byId(&amp;#39;content-Editor&amp;#39;).getValue(false);&lt;br&gt;    });&lt;br&gt;});&lt;br&gt;if (zend == undefined) {&lt;br&gt;    var zend = {};&lt;br&gt;}&lt;br&gt;zend.findParentForm = function(elementNode) {&lt;br&gt;    while (elementNode.nodeName.toLowerCase() != &amp;#39;form&amp;#39;) {&lt;br&gt;        elementNode = elementNode.parentNode;&lt;br&gt;    }&lt;br&gt;    return elementNode;&lt;br&gt;};&lt;p&gt;All of this seems to me to look good. In fact, this is so puzzling&lt;br&gt;because this is the first time I&amp;#39;ve ever encountered this error. I&lt;br&gt;can&amp;#39;t find any namespace collisions or anything that would prevent&lt;br&gt;this code from executing properly. Any ideas on what could be causing&lt;br&gt;this error?&lt;p&gt;--regards,&lt;br&gt;nathan&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5771930252168578814?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5771930252168578814/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5771930252168578814' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5771930252168578814'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5771930252168578814'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-from-using-zenddojoform-causes.html' title='[fw-mvc] From using Zend_Dojo_Form causes javascript error'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5827562814941172160</id><published>2011-02-11T05:11:00.001-08:00</published><updated>2011-02-11T05:11:23.361-08:00</updated><title type='text'>Re: [fw-mvc] Re: CSS/JS Includes</title><content type='html'>On 2/11/11 3:57 AM, Joe Balancio wrote:&lt;br&gt;&amp;gt; Yes, you can include all the styles your site will need in one CSS, but you&lt;br&gt;&amp;gt; get the overhead of including styles that some pages will not need. Same&lt;br&gt;&amp;gt; thing with JS.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; So, if I&amp;#39;m creating a complex site with many pages with many styles, I need&lt;br&gt;&amp;gt; a way to manage all of that.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; -----&lt;br&gt;&amp;gt; - Joe&lt;br&gt;You can try the 80/20 approach.  I tend to gather most of the common css &lt;br&gt;/ js into single files included on every page. (minified when we do a &lt;br&gt;production build)&lt;br&gt;Then, for the specialty stuff, try something like this:&lt;br&gt;&lt;a href="http://devzone.zend.com/article/11760"&gt;http://devzone.zend.com/article/11760&lt;/a&gt;&lt;br&gt;You can even extend that concept to produce a css / js file per &lt;br&gt;controller, or per module.&lt;br&gt;With some experimentation, I am sure you can find a comfortable balance &lt;br&gt;between managing lots of files, and only making a few cache-able requests.&lt;p&gt;-Matt&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5827562814941172160?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5827562814941172160/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5827562814941172160' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5827562814941172160'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5827562814941172160'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-re-cssjs-includes_5641.html' title='Re: [fw-mvc] Re: CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8060715305920656125</id><published>2011-02-11T04:07:00.001-08:00</published><updated>2011-02-11T04:07:28.897-08:00</updated><title type='text'>Re: [fw-mvc] Re: Theming Idea</title><content type='html'>Le 11/02/11 04:01, Joe Balancio a &amp;#233;crit :&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Ok that&amp;#39;s understandable that the Controllers are application logic. My&lt;br&gt;&amp;gt; models, however, are not and can be reused across different projects. The&lt;br&gt;&amp;gt; models are associated with a web service class. Would it still make sense to&lt;br&gt;&amp;gt; keep them in the library?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I would ideally want to keep the themes in separate folders. This means I&lt;br&gt;&amp;gt; would use one module and have a themes folder containing the desktop theme&lt;br&gt;&amp;gt; or mobile theme. Then I can detect the platform in a frontcontroller plugin&lt;br&gt;&amp;gt; and stack a theme path.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; -----&lt;br&gt;&amp;gt; - Joe&lt;p&gt; From a file system &amp;amp; use perspective, it looks like you wrote kind of &lt;br&gt;an extension.&lt;p&gt;Maybe an extensions/ folder will be the place for you files as you could &lt;br&gt;pack them under a given namespace to wrap your models, skins, etc.&lt;p&gt;Magento uses this kind of design for its modules.&lt;p&gt;Just write the according plugin to handle your extension and load them &lt;br&gt;wherever you are.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8060715305920656125?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8060715305920656125/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8060715305920656125' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8060715305920656125'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8060715305920656125'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-re-theming-idea.html' title='Re: [fw-mvc] Re: Theming Idea'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5390578952768223349</id><published>2011-02-11T04:04:00.001-08:00</published><updated>2011-02-11T04:04:41.453-08:00</updated><title type='text'>Re: [fw-mvc] Re: CSS/JS Includes</title><content type='html'>Le 11/02/11 09:57, Joe Balancio a &amp;#233;crit :&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Yes, you can include all the styles your site will need in one CSS, but you&lt;br&gt;&amp;gt; get the overhead of including styles that some pages will not need. Same&lt;br&gt;&amp;gt; thing with JS.&lt;br&gt;&amp;gt;&lt;p&gt;As Saša Stamenković stated you should minify your css/js for the reason &lt;br&gt;he mentioned.&lt;p&gt;It&amp;#39;s not good practice to multiply the request to fetch the CSS and JS.&lt;p&gt;Take a look here for an implemtation of minify embed in a View Helper:&lt;p&gt;&lt;a href="http://www.gsdesign.ro/blog/minify-css-in-zendframework/"&gt;http://www.gsdesign.ro/blog/minify-css-in-zendframework/&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5390578952768223349?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5390578952768223349/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5390578952768223349' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5390578952768223349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5390578952768223349'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-re-cssjs-includes_11.html' title='Re: [fw-mvc] Re: CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2933519809082152270</id><published>2011-02-11T01:15:00.000-08:00</published><updated>2011-02-11T01:17:32.427-08:00</updated><title type='text'>Re: [fw-mvc] Re: CSS/JS Includes</title><content type='html'>I suggest you to minify it all and servi in one file. Remember that js and&lt;br&gt;css are cached by the browser, so they will be loaded only the first time&lt;br&gt;user visits the site.&lt;br&gt;---&lt;br&gt;Regards,&lt;br&gt;Saša Stamenković&lt;p&gt;&lt;br&gt;On Fri, Feb 11, 2011 at 9:57 AM, Joe Balancio &amp;lt;&lt;a href="mailto:jlbalancio@gmail.com"&gt;jlbalancio@gmail.com&lt;/a&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; Yes, you can include all the styles your site will need in one CSS, but you&lt;br&gt;&amp;gt; get the overhead of including styles that some pages will not need. Same&lt;br&gt;&amp;gt; thing with JS.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; So, if I&amp;#39;m creating a complex site with many pages with many styles, I need&lt;br&gt;&amp;gt; a way to manage all of that.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; -----&lt;br&gt;&amp;gt; - Joe&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; View this message in context:&lt;br&gt;&amp;gt; &lt;a href="http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300959.html"&gt;http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300959.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend MVC mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2933519809082152270?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2933519809082152270/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2933519809082152270' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2933519809082152270'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2933519809082152270'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-re-cssjs-includes.html' title='Re: [fw-mvc] Re: CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6921879524593154184</id><published>2011-02-11T00:57:00.000-08:00</published><updated>2011-02-11T00:58:08.629-08:00</updated><title type='text'>[fw-mvc] Re: CSS/JS Includes</title><content type='html'>Yes, you can include all the styles your site will need in one CSS, but you&lt;br&gt;get the overhead of including styles that some pages will not need. Same&lt;br&gt;thing with JS.&lt;p&gt;So, if I&amp;#39;m creating a complex site with many pages with many styles, I need&lt;br&gt;a way to manage all of that.&lt;p&gt;-----&lt;br&gt;- Joe&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300959.html"&gt;http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300959.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6921879524593154184?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6921879524593154184/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6921879524593154184' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6921879524593154184'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6921879524593154184'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-cssjs-includes.html' title='[fw-mvc] Re: CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8355710243952679024</id><published>2011-02-10T19:18:00.001-08:00</published><updated>2011-02-10T19:18:48.184-08:00</updated><title type='text'>Re: [fw-mvc] CSS/JS Includes</title><content type='html'>I just include mine in the master layout so my entire app calls the same CSS&lt;br&gt;and JS file.&lt;p&gt;2011/2/10 Joe Balancio &amp;lt;&lt;a href="mailto:jlbalancio@gmail.com"&gt;jlbalancio@gmail.com&lt;/a&gt;&amp;gt;&lt;p&gt;&amp;gt;&lt;br&gt;&amp;gt; There are several ways that you can include CSS or JS into the views. You&lt;br&gt;&amp;gt; can&lt;br&gt;&amp;gt; either include them via the view helpers like HeadLink/HeadScript in the&lt;br&gt;&amp;gt; controllers or in the views.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; What happens when I have many controllers/actions and many templates? Would&lt;br&gt;&amp;gt; it be reasonable to manage your CSS/JS includes in this way (controller or&lt;br&gt;&amp;gt; view)?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Have you encountered this problem and what are some ways that you have&lt;br&gt;&amp;gt; solved it?&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; -----&lt;br&gt;&amp;gt; - Joe&lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; View this message in context:&lt;br&gt;&amp;gt; &lt;a href="http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300692.html"&gt;http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300692.html&lt;/a&gt;&lt;br&gt;&amp;gt; Sent from the Zend MVC mailing list archive at Nabble.com.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;p&gt;&lt;br&gt;-- &lt;br&gt;----------------------------------------------&lt;br&gt;&amp;quot;May the Source be with you.&amp;quot;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8355710243952679024?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8355710243952679024/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8355710243952679024' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8355710243952679024'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8355710243952679024'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-cssjs-includes.html' title='Re: [fw-mvc] CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-189722519107345769</id><published>2011-02-10T19:08:00.001-08:00</published><updated>2011-02-10T19:08:49.803-08:00</updated><title type='text'>[fw-mvc] CSS/JS Includes</title><content type='html'>There are several ways that you can include CSS or JS into the views. You can&lt;br&gt;either include them via the view helpers like HeadLink/HeadScript in the&lt;br&gt;controllers or in the views.&lt;p&gt;What happens when I have many controllers/actions and many templates? Would&lt;br&gt;it be reasonable to manage your CSS/JS includes in this way (controller or&lt;br&gt;view)?&lt;p&gt;Have you encountered this problem and what are some ways that you have&lt;br&gt;solved it?&lt;p&gt;-----&lt;br&gt;- Joe&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300692.html"&gt;http://zend-framework-community.634137.n4.nabble.com/CSS-JS-Includes-tp3300692p3300692.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-189722519107345769?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/189722519107345769/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=189722519107345769' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/189722519107345769'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/189722519107345769'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-cssjs-includes.html' title='[fw-mvc] CSS/JS Includes'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2496537863356857702</id><published>2011-02-10T19:01:00.001-08:00</published><updated>2011-02-10T19:01:20.952-08:00</updated><title type='text'>[fw-mvc] Re: Theming Idea</title><content type='html'>Ok that&amp;#39;s understandable that the Controllers are application logic. My&lt;br&gt;models, however, are not and can be reused across different projects. The&lt;br&gt;models are associated with a web service class. Would it still make sense to&lt;br&gt;keep them in the library?&lt;p&gt;I would ideally want to keep the themes in separate folders. This means I&lt;br&gt;would use one module and have a themes folder containing the desktop theme&lt;br&gt;or mobile theme. Then I can detect the platform in a frontcontroller plugin&lt;br&gt;and stack a theme path.&lt;p&gt;-----&lt;br&gt;- Joe&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Theming-Idea-tp3298511p3300688.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Theming-Idea-tp3298511p3300688.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2496537863356857702?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2496537863356857702/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2496537863356857702' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2496537863356857702'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2496537863356857702'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-theming-idea.html' title='[fw-mvc] Re: Theming Idea'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3041763284476363098</id><published>2011-02-10T17:58:00.000-08:00</published><updated>2011-02-10T17:59:07.793-08:00</updated><title type='text'>[fw-mvc] Re: (v1.7.2)</title><content type='html'>weierophinney wrote:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; -- nphilliy &amp;lt;&lt;a href="mailto:nathaniel.phillips@photobox.com"&gt;nathaniel.phillips@photobox.com&lt;/a&gt;&amp;gt; wrote&lt;br&gt;&amp;gt; (on Thursday, 10 February 2011, 06:14 AM -0800):&lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; I am currently forced to use zend framework 1.7.2&lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; I have a problem with the partial function&lt;br&gt;&amp;gt;&amp;gt; &lt;br&gt;&amp;gt;&amp;gt; $this-&amp;gt;partial(&amp;#39;template.html&amp;#39;, array(&amp;#39;arg1&amp;#39; =&amp;gt; &amp;#39;value1&amp;#39;));&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;  * Use render(), and make sure the variables are already in the view&lt;br&gt;&amp;gt;    script scope, or assigned to the view. In terms of having them in the&lt;br&gt;&amp;gt;    view script scope:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;    &amp;lt;?php&lt;br&gt;&amp;gt;    $arg1 = &amp;#39;value1&amp;#39;;&lt;br&gt;&amp;gt;    echo $this-&amp;gt;render(&amp;#39;template1.phtml&amp;#39;); // template can now refer to&lt;br&gt;&amp;gt; $arg1&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;p&gt;Don&amp;#39;t you mean:&lt;p&gt;&amp;lt;?php&lt;br&gt;$this-&amp;gt;arg1 = &amp;#39;value1&amp;#39;;&lt;br&gt;$this-&amp;gt;render(&amp;#39;template1.phtml&amp;#39;);&lt;br&gt;?&amp;gt;&lt;p&gt;Render is a bit faster than partial, so if the scope bleed isn&amp;#39;t a problem,&lt;br&gt;I&amp;#39;d use render().&lt;p&gt;Cheers,&lt;br&gt;David&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/partial-and-render-parameters-v1-7-2-tp3299188p3300635.html"&gt;http://zend-framework-community.634137.n4.nabble.com/partial-and-render-parameters-v1-7-2-tp3299188p3300635.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3041763284476363098?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3041763284476363098/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3041763284476363098' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3041763284476363098'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3041763284476363098'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-v172.html' title='[fw-mvc] Re: (v1.7.2)'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3967213270623453684</id><published>2011-02-10T14:36:00.001-08:00</published><updated>2011-02-10T14:36:44.747-08:00</updated><title type='text'>Re: [fw-mvc] Theming Idea</title><content type='html'>On Thursday 10 Feb 2011 20:01:22 Hector Virgen wrote:&lt;br&gt;&amp;gt; On Thu, Feb 10, 2011 at 12:38 AM, Jurian Sluiman&lt;br&gt;&amp;gt; &amp;lt;&lt;a href="mailto:subscribe@juriansluiman.nl"&gt;subscribe@juriansluiman.nl&lt;/a&gt;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &amp;gt; wrote:&lt;br&gt;&amp;gt; &amp;gt; &lt;br&gt;&amp;gt; &amp;gt; Create a frontController plugin which hooks at an early stage and&lt;br&gt;&amp;gt; &amp;gt; use WURFL (eg the Zend Http browseragent component) to look is a mobile&lt;br&gt;&amp;gt; &amp;gt; switch&lt;br&gt;&amp;gt; &amp;gt; should be set.&lt;br&gt;&amp;gt; &amp;gt; If so, change your view extension from .phtml to .mobile.phtml. Then you&lt;br&gt;&amp;gt; &amp;gt; can&lt;br&gt;&amp;gt; &amp;gt; use your normal layout.phtml and layout.mobile.phtml and as well for the&lt;br&gt;&amp;gt; &amp;gt; views: instead of index.phtml it would become index.mobile.phtml.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I second Jurian&amp;#39;s idea but it could probably be improved by extending the&lt;br&gt;&amp;gt; ContextSwitch action helper to support switching to a mobile context using&lt;br&gt;&amp;gt; the same logic that his plugin would use. However the action helper would&lt;br&gt;&amp;gt; let you control which actions will support a mobile view in case you are&lt;br&gt;&amp;gt; not theming the entire site.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; --&lt;br&gt;&amp;gt; *Hector Virgen*&lt;br&gt;&amp;gt; Sr. Web Developer&lt;br&gt;&amp;gt; &lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;p&gt;We use indeed this approach as wel at our company. The frontController plugin &lt;br&gt;checks if we have a mobile device and if so, we can switch to a mobile layout. &lt;br&gt;An extension of the contextSwitch lets us determine on controller/action base &lt;br&gt;if we want a special view in case we have a mobile request.&lt;p&gt;Regards, Jurian&lt;br&gt;-- &lt;br&gt;Jurian Sluiman&lt;br&gt;Soflomo - &lt;a href="http://soflomo.com"&gt;http://soflomo.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3967213270623453684?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3967213270623453684/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3967213270623453684' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3967213270623453684'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3967213270623453684'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-theming-idea_6643.html' title='Re: [fw-mvc] Theming Idea'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5263792176692865026</id><published>2011-02-10T12:56:00.000-08:00</published><updated>2011-02-10T12:57:05.111-08:00</updated><title type='text'>Re: [fw-mvc] (v1.7.2)</title><content type='html'>-- nphilliy &amp;lt;&lt;a href="mailto:nathaniel.phillips@photobox.com"&gt;nathaniel.phillips@photobox.com&lt;/a&gt;&amp;gt; wrote&lt;br&gt;(on Thursday, 10 February 2011, 06:14 AM -0800):&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I am currently forced to use zend framework 1.7.2&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I have a problem with the partial function&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; $this-&amp;gt;partial(&amp;#39;template.html&amp;#39;, array(&amp;#39;arg1&amp;#39; =&amp;gt; &amp;#39;value1&amp;#39;));&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; This kind of does what i want as the variables that are available to the&lt;br&gt;&amp;gt; parent template are not in the partial template&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I know that $this-&amp;gt;render(&amp;#39;template.html&amp;#39;); allows the variables to be&lt;br&gt;&amp;gt; exposed to the template&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; but what about if i want the variables to be exposed to my partial template&lt;br&gt;&amp;gt; AND need parameters to be passed in? Did they actually not put something&lt;br&gt;&amp;gt; like this in?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; yeap i know the partial() method is meant to give a clean variable scope and&lt;br&gt;&amp;gt; blah blah blah, so if thats the case, how do I do what im asking?&lt;p&gt;Two ways:&lt;p&gt; * Use render(), and make sure the variables are already in the view&lt;br&gt;   script scope, or assigned to the view. In terms of having them in the&lt;br&gt;   view script scope:&lt;p&gt;   &amp;lt;?php&lt;br&gt;   $arg1 = &amp;#39;value1&amp;#39;;&lt;br&gt;   echo $this-&amp;gt;render(&amp;#39;template1.phtml&amp;#39;); // template can now refer to $arg1&lt;p&gt; * Pass in all view variables + locally scoped variables:&lt;p&gt;   &amp;lt;?php&lt;br&gt;   $vars = $this-&amp;gt;getVars();&lt;br&gt;   $vars[&amp;#39;arg1&amp;#39;] = &amp;#39;value1&amp;#39;;&lt;br&gt;   echo $this-&amp;gt;partial(&amp;#39;template1&amp;#39;, $vars);&lt;p&gt;-- &lt;br&gt;Matthew Weier O&amp;#39;Phinney&lt;br&gt;Project Lead            | &lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&lt;br&gt;Zend Framework          | &lt;a href="http://framework.zend.com/"&gt;http://framework.zend.com/&lt;/a&gt;&lt;br&gt;PGP key: &lt;a href="http://framework.zend.com/zf-matthew-pgp-key.asc"&gt;http://framework.zend.com/zf-matthew-pgp-key.asc&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5263792176692865026?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5263792176692865026/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5263792176692865026' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5263792176692865026'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5263792176692865026'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-v172.html' title='Re: [fw-mvc] (v1.7.2)'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4881320677539272043</id><published>2011-02-10T11:46:00.001-08:00</published><updated>2011-02-10T11:46:41.612-08:00</updated><title type='text'>Re: [fw-mvc] Sessions and passing them between websites</title><content type='html'>Le 10/02/11 16:37, Thomas List a &amp;#233;crit :&lt;br&gt;&amp;gt; Hello,&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I&amp;#39;m working on a part of a website where the idea is to be able to embed a form on another website, and then process that form  through Action controllers on a site built using the Zend Framework.&lt;br&gt;&amp;gt; I believe that I need to save the form in a session variable and redirect the user to the Action Controller, I&amp;#39;m just not that sure how to go  about it. I haven&amp;#39;t done much work with Sessions, or forms which will post the entered information into a session variable.  Any tips would really be appreciated.  I&amp;#39;m sort of in uncharted water with this.&lt;p&gt;What are you exactly trying to do?&lt;p&gt;Are you trying to generate some forms on a website and them processed &lt;br&gt;them on ZF based website? And then need information about inputs to &lt;br&gt;validate and filter them? If you do you could maybe serialize your form &lt;br&gt;object either in a database or in a session (depending on your use) and &lt;br&gt;then unserialize your form object to get full informations about how to &lt;br&gt;process it.&lt;p&gt;If you need to share sessions across several websites, you can use &lt;br&gt;memcache as a session handler and set up session.save_handler and &lt;br&gt;session.save_path, I did on portal where we had a lot of servers.&lt;p&gt;Maybe nfs or unionfs would do the trick too.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4881320677539272043?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4881320677539272043/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4881320677539272043' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4881320677539272043'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4881320677539272043'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-sessions-and-passing-them.html' title='Re: [fw-mvc] Sessions and passing them between websites'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4337558970739391985</id><published>2011-02-10T11:01:00.001-08:00</published><updated>2011-02-10T11:01:56.420-08:00</updated><title type='text'>Re: [fw-mvc] Theming Idea</title><content type='html'>On Thu, Feb 10, 2011 at 12:38 AM, Jurian Sluiman &amp;lt;&lt;a href="mailto:subscribe@juriansluiman.nl"&gt;subscribe@juriansluiman.nl&lt;/a&gt;&lt;br&gt;&amp;gt; wrote:&lt;p&gt;&amp;gt; Create a frontController plugin which hooks at an early stage and&lt;br&gt;&amp;gt; use WURFL (eg the Zend Http browseragent component) to look is a mobile&lt;br&gt;&amp;gt; switch&lt;br&gt;&amp;gt; should be set.&lt;br&gt;&amp;gt; If so, change your view extension from .phtml to .mobile.phtml. Then you&lt;br&gt;&amp;gt; can&lt;br&gt;&amp;gt; use your normal layout.phtml and layout.mobile.phtml and as well for the&lt;br&gt;&amp;gt; views: instead of index.phtml it would become index.mobile.phtml.&lt;p&gt;&lt;br&gt;I second Jurian&amp;#39;s idea but it could probably be improved by extending the&lt;br&gt;ContextSwitch action helper to support switching to a mobile context using&lt;br&gt;the same logic that his plugin would use. However the action helper would&lt;br&gt;let you control which actions will support a mobile view in case you are not&lt;br&gt;theming the entire site.&lt;p&gt;--&lt;br&gt;*Hector Virgen*&lt;br&gt;Sr. Web Developer&lt;br&gt;&lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4337558970739391985?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4337558970739391985/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4337558970739391985' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4337558970739391985'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4337558970739391985'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-theming-idea_10.html' title='Re: [fw-mvc] Theming Idea'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3612342903777584828</id><published>2011-02-10T07:37:00.001-08:00</published><updated>2011-02-10T07:37:43.366-08:00</updated><title type='text'>[fw-mvc] Sessions and passing them between websites</title><content type='html'>Hello, &lt;p&gt;I&amp;#39;m working on a part of a website where the idea is to be able to embed a form on another website, and then process that form  through Action controllers on a site built using the Zend Framework.  &lt;br&gt;I believe that I need to save the form in a session variable and redirect the user to the Action Controller, I&amp;#39;m just not that sure how to go  about it. I haven&amp;#39;t done much work with Sessions, or forms which will post the entered information into a session variable.  Any tips would really be appreciated.  I&amp;#39;m sort of in uncharted water with this.  &lt;p&gt;Regards, &lt;br&gt;Thomas&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3612342903777584828?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3612342903777584828/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3612342903777584828' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3612342903777584828'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3612342903777584828'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-sessions-and-passing-them.html' title='[fw-mvc] Sessions and passing them between websites'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2931641015604909807</id><published>2011-02-10T06:14:00.000-08:00</published><updated>2011-02-10T07:37:18.222-08:00</updated><title type='text'>[fw-mvc] (v1.7.2)</title><content type='html'>I am currently forced to use zend framework 1.7.2&lt;p&gt;I have a problem with the partial function&lt;p&gt;$this-&amp;gt;partial(&amp;#39;template.html&amp;#39;, array(&amp;#39;arg1&amp;#39; =&amp;gt; &amp;#39;value1&amp;#39;));&lt;p&gt;This kind of does what i want as the variables that are available to the&lt;br&gt;parent template are not in the partial template&lt;p&gt;I know that $this-&amp;gt;render(&amp;#39;template.html&amp;#39;); allows the variables to be&lt;br&gt;exposed to the template&lt;p&gt;but what about if i want the variables to be exposed to my partial template&lt;br&gt;AND need parameters to be passed in? Did they actually not put something&lt;br&gt;like this in?&lt;p&gt;yeap i know the partial() method is meant to give a clean variable scope and&lt;br&gt;blah blah blah, so if thats the case, how do I do what im asking?&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/v1-7-2-tp3299188p3299188.html"&gt;http://zend-framework-community.634137.n4.nabble.com/v1-7-2-tp3299188p3299188.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2931641015604909807?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2931641015604909807/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2931641015604909807' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2931641015604909807'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2931641015604909807'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-v172.html' title='[fw-mvc] (v1.7.2)'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1670807724823920450</id><published>2011-02-10T05:52:00.000-08:00</published><updated>2011-02-10T05:53:33.508-08:00</updated><title type='text'>Re: [fw-mvc] Dojo resource feature request</title><content type='html'>On Thu, Feb 10, 2011 at 6:01 AM, Matthew Weier O&amp;#39;Phinney&lt;br&gt;&amp;lt;&lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&amp;gt;wrote:&lt;p&gt;&amp;gt; This would then set a separate view object for the Dojo view helper than&lt;br&gt;&amp;gt; you use for the rest of the application. I&amp;#39;m not sure it makes any&lt;br&gt;&amp;gt; sense, to be honest.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Create an alternate View resource -- the code provided will use&lt;br&gt;&amp;gt; whatever view resource is registered, which I think is more in line with&lt;br&gt;&amp;gt; what you might want to achieve.&lt;br&gt;&amp;gt;&lt;p&gt;Thanks for the help Matthew! The use case I have is that there are three&lt;br&gt;virtual hosts that point to the same codebase, i.e. they all consume the&lt;br&gt;same resources. However, the view resource is slightly different for each&lt;br&gt;vhost. So I created a unique view resource for each host: MainView,&lt;br&gt;AdminView, StagingView. So I wanted to be able to tell a the Dojo resource&lt;br&gt;which view to use. However, in writing about this, I just realized I can use&lt;br&gt;the view resource that ships with ZF and do any other tweaking in the&lt;br&gt;Bootstrap. I didn&amp;#39;t think of this last night. (Was jacked up on coffee and&lt;br&gt;fatigue). So I&amp;#39;ll go with that. Thanks again for your input.&lt;p&gt;--regards,&lt;br&gt;nathan&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1670807724823920450?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1670807724823920450/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1670807724823920450' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1670807724823920450'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1670807724823920450'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-dojo-resource-feature-request_10.html' title='Re: [fw-mvc] Dojo resource feature request'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-8868976730593111815</id><published>2011-02-10T05:01:00.000-08:00</published><updated>2011-02-10T05:02:06.156-08:00</updated><title type='text'>Re: [fw-mvc] Dojo resource feature request</title><content type='html'>-- Nathan Garlington &amp;lt;&lt;a href="mailto:garlinto@gmail.com"&gt;garlinto@gmail.com&lt;/a&gt;&amp;gt; wrote&lt;br&gt;(on Wednesday, 09 February 2011, 09:14 PM -0700):&lt;br&gt;&amp;gt; In the class Zend_Application_Resource_Dojo that ships in dojo, the&lt;br&gt;&amp;gt; following public method is exposed:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;  public function getDojo()&lt;br&gt;&amp;gt;     {&lt;br&gt;&amp;gt;         if (null === $this-&amp;gt;_dojo) {&lt;br&gt;&amp;gt;             $this-&amp;gt;getBootstrap()-&amp;gt;bootstrap(&amp;#39;view&amp;#39;);&lt;br&gt;&amp;gt;             $view = $this-&amp;gt;getBootstrap()-&amp;gt;view;&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;             Zend_Dojo::enableView($view);&lt;br&gt;&amp;gt;             $view-&amp;gt;dojo()-&amp;gt;setOptions($this-&amp;gt;getOptions());&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;             $this-&amp;gt;_dojo = $view-&amp;gt;dojo();&lt;br&gt;&amp;gt;         }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;         return $this-&amp;gt;_dojo;&lt;br&gt;&amp;gt;     }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I know I can create my own dojo resource that can consume a custom view&lt;br&gt;&amp;gt; object, but I was wondering if this method could be changed to allow setting&lt;br&gt;&amp;gt; the view object to a custom view object in application.ini?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Something like:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; resources.dojo.enable = true&lt;br&gt;&amp;gt; resources.dojo.view = &amp;quot;myView&amp;quot;&lt;br&gt;&amp;gt; ; more config options.....&lt;p&gt;This would then set a separate view object for the Dojo view helper than&lt;br&gt;you use for the rest of the application. I&amp;#39;m not sure it makes any&lt;br&gt;sense, to be honest.&lt;p&gt;Create an alternate View resource -- the code provided will use&lt;br&gt;whatever view resource is registered, which I think is more in line with&lt;br&gt;what you might want to achieve.&lt;p&gt;&amp;gt; Then, in Zend_Application_Resource_Dojo, something like:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;  public function getDojo()&lt;br&gt;&amp;gt;     {&lt;br&gt;&amp;gt;         if (null === $this-&amp;gt;_dojo) {&lt;br&gt;&amp;gt;             $options = $this-&amp;gt;getOptions();&lt;br&gt;&amp;gt;             if ($options[&amp;#39;view&amp;#39;]) {&lt;br&gt;&amp;gt;                   $this-&amp;gt;getBootstrap()-&amp;gt;bootstrap($options[&amp;#39;view&amp;#39;]);&lt;br&gt;&amp;gt;                   $view = $this-&amp;gt;getBootstrap()-&amp;gt;$options[&amp;#39;view&amp;#39;];&lt;br&gt;&amp;gt;             } else {&lt;br&gt;&amp;gt;                   $this-&amp;gt;getBootstrap()-&amp;gt;bootstrap(&amp;#39;view&amp;#39;);&lt;br&gt;&amp;gt;                   $view = $this-&amp;gt;getBootstrap()-&amp;gt;view;&lt;br&gt;&amp;gt;             }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;            unset($options[&amp;#39;view&amp;#39;]);&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;            Zend_Dojo::enableView($view);&lt;br&gt;&amp;gt;            $view-&amp;gt;dojo()-&amp;gt;setOptions($options);&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;            $this-&amp;gt;_dojo = $view-&amp;gt;dojo();&lt;br&gt;&amp;gt;         }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt;         return $this-&amp;gt;_dojo;&lt;br&gt;&amp;gt;     }&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; The above is just an idea. Would a change like this be in keeping with the&lt;br&gt;&amp;gt; goals of the vanilla resources shipped with ZF, or should I just plan on&lt;br&gt;&amp;gt; creating my own dojo resource? If this is something the devs would approve,&lt;br&gt;&amp;gt; how do I go about submitting the idea?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; --regards,&lt;br&gt;&amp;gt; nathan&lt;p&gt;-- &lt;br&gt;Matthew Weier O&amp;#39;Phinney&lt;br&gt;Project Lead            | &lt;a href="mailto:matthew@zend.com"&gt;matthew@zend.com&lt;/a&gt;&lt;br&gt;Zend Framework          | &lt;a href="http://framework.zend.com/"&gt;http://framework.zend.com/&lt;/a&gt;&lt;br&gt;PGP key: &lt;a href="http://framework.zend.com/zf-matthew-pgp-key.asc"&gt;http://framework.zend.com/zf-matthew-pgp-key.asc&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-8868976730593111815?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/8868976730593111815/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=8868976730593111815' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8868976730593111815'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/8868976730593111815'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-dojo-resource-feature-request.html' title='Re: [fw-mvc] Dojo resource feature request'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4333690970758741488</id><published>2011-02-10T00:38:00.001-08:00</published><updated>2011-02-10T00:38:33.688-08:00</updated><title type='text'>Re: [fw-mvc] Theming Idea</title><content type='html'>On Thursday 10 Feb 2011 04:08:21 Joe Balancio wrote:&lt;br&gt;&amp;gt; I have an idea for theming, but I would like some feedback before&lt;br&gt;&amp;gt; implementing it.  By theme, I mean platform-specific views. Like if I want&lt;br&gt;&amp;gt; to display a mobile version of a site.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; I will only be using one set of controllers and one set of models.  The&lt;br&gt;&amp;gt; views will change depending on the theme.  Since my controllers and models&lt;br&gt;&amp;gt; will not change, I would like to put them in the library and reference them&lt;br&gt;&amp;gt; there. If I can successfully do that then my modules will only have views&lt;br&gt;&amp;gt; and layouts. So why not use modules as my theme container?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; If the user is viewing on a mobile device, then I can intercept in a&lt;br&gt;&amp;gt; controller plugin and change the module on the fly. Or I can set up routing&lt;br&gt;&amp;gt; to go to a hostname specific route and redirect.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Any feedback?&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; -----&lt;br&gt;&amp;gt; - Joe&lt;p&gt;I don&amp;#39;t think you should use the module directory as a theme directory. Your &lt;br&gt;models and controllers are application logic and should be in the app, not the &lt;br&gt;library.&lt;p&gt;If you only want to switch views for a mobile version, I&amp;#39;d do it somewhat &lt;br&gt;different. Create a frontController plugin which hooks at an early stage and &lt;br&gt;use WURFL (eg the Zend Http browseragent component) to look is a mobile switch &lt;br&gt;should be set. &lt;br&gt;If so, change your view extension from .phtml to .mobile.phtml. Then you can &lt;br&gt;use your normal layout.phtml and layout.mobile.phtml and as well for the &lt;br&gt;views: instead of index.phtml it would become index.mobile.phtml.&lt;p&gt;Then you keep all your views at the right place and is it much easier to &lt;br&gt;maintain.&lt;p&gt;Regards, Jurian&lt;br&gt;-- &lt;br&gt;Jurian Sluiman&lt;br&gt;Soflomo - &lt;a href="http://soflomo.com"&gt;http://soflomo.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4333690970758741488?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4333690970758741488/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4333690970758741488' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4333690970758741488'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4333690970758741488'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-theming-idea.html' title='Re: [fw-mvc] Theming Idea'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4466993316863873959</id><published>2011-02-09T20:14:00.000-08:00</published><updated>2011-02-09T20:15:35.995-08:00</updated><title type='text'>[fw-mvc] Dojo resource feature request</title><content type='html'>In the class Zend_Application_Resource_Dojo that ships in dojo, the&lt;br&gt;following public method is exposed:&lt;p&gt; public function getDojo()&lt;br&gt;    {&lt;br&gt;        if (null === $this-&amp;gt;_dojo) {&lt;br&gt;            $this-&amp;gt;getBootstrap()-&amp;gt;bootstrap(&amp;#39;view&amp;#39;);&lt;br&gt;            $view = $this-&amp;gt;getBootstrap()-&amp;gt;view;&lt;p&gt;            Zend_Dojo::enableView($view);&lt;br&gt;            $view-&amp;gt;dojo()-&amp;gt;setOptions($this-&amp;gt;getOptions());&lt;p&gt;            $this-&amp;gt;_dojo = $view-&amp;gt;dojo();&lt;br&gt;        }&lt;p&gt;        return $this-&amp;gt;_dojo;&lt;br&gt;    }&lt;p&gt;I know I can create my own dojo resource that can consume a custom view&lt;br&gt;object, but I was wondering if this method could be changed to allow setting&lt;br&gt;the view object to a custom view object in application.ini?&lt;p&gt;Something like:&lt;p&gt;resources.dojo.enable = true&lt;br&gt;resources.dojo.view = &amp;quot;myView&amp;quot;&lt;br&gt;; more config options.....&lt;p&gt;Then, in Zend_Application_Resource_Dojo, something like:&lt;p&gt; public function getDojo()&lt;br&gt;    {&lt;br&gt;        if (null === $this-&amp;gt;_dojo) {&lt;br&gt;            $options = $this-&amp;gt;getOptions();&lt;br&gt;            if ($options[&amp;#39;view&amp;#39;]) {&lt;br&gt;                  $this-&amp;gt;getBootstrap()-&amp;gt;bootstrap($options[&amp;#39;view&amp;#39;]);&lt;br&gt;                  $view = $this-&amp;gt;getBootstrap()-&amp;gt;$options[&amp;#39;view&amp;#39;];&lt;br&gt;            } else {&lt;br&gt;                  $this-&amp;gt;getBootstrap()-&amp;gt;bootstrap(&amp;#39;view&amp;#39;);&lt;br&gt;                  $view = $this-&amp;gt;getBootstrap()-&amp;gt;view;&lt;br&gt;            }&lt;p&gt;           unset($options[&amp;#39;view&amp;#39;]);&lt;p&gt;           Zend_Dojo::enableView($view);&lt;br&gt;           $view-&amp;gt;dojo()-&amp;gt;setOptions($options);&lt;p&gt;           $this-&amp;gt;_dojo = $view-&amp;gt;dojo();&lt;br&gt;        }&lt;p&gt;        return $this-&amp;gt;_dojo;&lt;br&gt;    }&lt;p&gt;The above is just an idea. Would a change like this be in keeping with the&lt;br&gt;goals of the vanilla resources shipped with ZF, or should I just plan on&lt;br&gt;creating my own dojo resource? If this is something the devs would approve,&lt;br&gt;how do I go about submitting the idea?&lt;p&gt;--regards,&lt;br&gt;nathan&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4466993316863873959?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4466993316863873959/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4466993316863873959' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4466993316863873959'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4466993316863873959'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-dojo-resource-feature-request.html' title='[fw-mvc] Dojo resource feature request'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5468748815154996434</id><published>2011-02-09T19:08:00.001-08:00</published><updated>2011-02-09T19:08:36.214-08:00</updated><title type='text'>[fw-mvc] Theming Idea</title><content type='html'>I have an idea for theming, but I would like some feedback before&lt;br&gt;implementing it.  By theme, I mean platform-specific views. Like if I want&lt;br&gt;to display a mobile version of a site.&lt;p&gt;I will only be using one set of controllers and one set of models.  The&lt;br&gt;views will change depending on the theme.  Since my controllers and models&lt;br&gt;will not change, I would like to put them in the library and reference them&lt;br&gt;there. If I can successfully do that then my modules will only have views&lt;br&gt;and layouts. So why not use modules as my theme container?&lt;p&gt;If the user is viewing on a mobile device, then I can intercept in a&lt;br&gt;controller plugin and change the module on the fly. Or I can set up routing&lt;br&gt;to go to a hostname specific route and redirect.&lt;p&gt;Any feedback?&lt;p&gt;-----&lt;br&gt;- Joe&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Theming-Idea-tp3298511p3298511.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Theming-Idea-tp3298511p3298511.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5468748815154996434?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5468748815154996434/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5468748815154996434' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5468748815154996434'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5468748815154996434'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-theming-idea.html' title='[fw-mvc] Theming Idea'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-4767559598059338800</id><published>2011-02-08T15:13:00.001-08:00</published><updated>2011-02-08T15:13:43.866-08:00</updated><title type='text'>Re: [fw-mvc] Custom Index Controller</title><content type='html'>Thanks all,&lt;p&gt;I&amp;#39;ll try the router and see how things go.&lt;p&gt;&lt;br&gt;Lionel&lt;p&gt;On 2/8/11 5:36 PM, Lionel Morrison wrote:&lt;br&gt;&amp;gt; Does anyone know how to tweek the default IndexController so that the &lt;br&gt;&amp;gt; following URL displays a users profile. Currently I get the undefined &lt;br&gt;&amp;gt; controller error.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; &lt;a href="http://www.mywebsite.com/123"&gt;http://www.mywebsite.com/123&lt;/a&gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I can get it to work if do the following &lt;br&gt;&amp;gt; &lt;a href="http://www.mywebsite.com/profile/123"&gt;http://www.mywebsite.com/profile/123&lt;/a&gt; but the current website displays &lt;br&gt;&amp;gt; the profiles of its users using the first URL.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Anyone got any suggestions on how to best go about getting this working.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Thanks&lt;br&gt;&amp;gt; Lionel Morrison&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-4767559598059338800?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/4767559598059338800/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=4767559598059338800' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4767559598059338800'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/4767559598059338800'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-custom-index-controller.html' title='Re: [fw-mvc] Custom Index Controller'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-414649386517420517</id><published>2011-02-08T14:36:00.001-08:00</published><updated>2011-02-08T14:36:58.900-08:00</updated><title type='text'>[fw-mvc] Custom Index Controller</title><content type='html'>Does anyone know how to tweek the default IndexController so that the &lt;br&gt;following URL displays a users profile. Currently I get the undefined &lt;br&gt;controller error.&lt;p&gt;&lt;a href="http://www.mywebsite.com/123"&gt;http://www.mywebsite.com/123&lt;/a&gt;&lt;p&gt;&lt;br&gt;I can get it to work if do the following &lt;br&gt;&lt;a href="http://www.mywebsite.com/profile/123"&gt;http://www.mywebsite.com/profile/123&lt;/a&gt; but the current website displays &lt;br&gt;the profiles of its users using the first URL.&lt;p&gt;Anyone got any suggestions on how to best go about getting this working.&lt;p&gt;&lt;br&gt;Thanks&lt;br&gt;Lionel Morrison&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-414649386517420517?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/414649386517420517/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=414649386517420517' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/414649386517420517'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/414649386517420517'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-custom-index-controller.html' title='[fw-mvc] Custom Index Controller'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3915842160114934860</id><published>2011-02-07T07:41:00.000-08:00</published><updated>2011-02-07T08:39:13.495-08:00</updated><title type='text'>[fw-webservices] Re: PUT method doesn't work with Zend_Rest_Client</title><content type='html'>Actually, the error message was correct in telling you to use&lt;br&gt;Zend_Http_Client instead :)&lt;p&gt;-----&lt;br&gt;--&lt;br&gt;Wil Moore III&lt;p&gt;Why is Bottom-posting better than Top-posting:&lt;br&gt;&lt;a href="http://www.caliburn.nl/topposting.html"&gt;http://www.caliburn.nl/topposting.html&lt;/a&gt;&lt;p&gt;DO NOT TOP-POST and DO trim your replies:&lt;br&gt;&lt;a href="http://linux.sgms-centre.com/misc/netiquette.php#toppost"&gt;http://linux.sgms-centre.com/misc/netiquette.php#toppost&lt;/a&gt;&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/PUT-method-doesn-t-work-with-Zend-Rest-Client-tp3262800p3264364.html"&gt;http://zend-framework-community.634137.n4.nabble.com/PUT-method-doesn-t-work-with-Zend-Rest-Client-tp3262800p3264364.html&lt;/a&gt;&lt;br&gt;Sent from the Zend Web Services mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3915842160114934860?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3915842160114934860/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3915842160114934860' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3915842160114934860'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3915842160114934860'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-webservices-re-put-method-doesnt.html' title='[fw-webservices] Re: PUT method doesn&apos;t work with Zend_Rest_Client'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2246334742525754530</id><published>2011-02-07T03:02:00.000-08:00</published><updated>2011-02-07T02:46:11.346-08:00</updated><title type='text'>RE: [fw-mvc] Re: Widgets/Modules</title><content type='html'>&amp;gt; -----Original Message-----&lt;br&gt;&amp;gt; From: Wil Moore III [mailto:&lt;a href="mailto:wil.moore@wilmoore.com"&gt;wil.moore@wilmoore.com&lt;/a&gt;]&lt;br&gt;&amp;gt; Sent: Saturday, February 05, 2011 12:06 PM&lt;br&gt;&amp;gt; To: &lt;a href="mailto:fw-mvc@lists.zend.com"&gt;fw-mvc@lists.zend.com&lt;/a&gt;&lt;br&gt;&amp;gt; Subject: [fw-mvc] Re: Widgets/Modules&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Thomas List wrote:&lt;br&gt;&amp;gt; &amp;gt;&lt;br&gt;&amp;gt; &amp;gt; If anyone could point me towards a good tutorial or site which explains&lt;br&gt;&amp;gt; &amp;gt; the development of Widget/Module in Zend I would really appreciate it.&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; Wil Moore III wrote:&lt;br&gt;&amp;gt; I&amp;#39;ve not seen a tutorial on this particular subject (not there there isn&amp;#39;t&lt;br&gt;&amp;gt; one out there); however, may I suggest that you study the &amp;quot;ShareThis&amp;quot; code&lt;br&gt;&amp;gt; to get an idea of what is possible.&lt;br&gt;&amp;gt; &lt;br&gt;[Joey Adams]&lt;br&gt;I&amp;#39;ve not had to do this particularly, but if you are going to be adding&lt;br&gt;complex functionality to external resources you might want to think about&lt;br&gt;making a REST server exposing the functionality you have already built. &lt;p&gt;Then your implementation depends solely on the client code, if you are&lt;br&gt;deploying to zf applications, maybe using a module based widget with action&lt;br&gt;helpers as described by MWOP here&lt;br&gt;&lt;a href="http://bit.ly/aa9trp"&gt;http://bit.ly/aa9trp&lt;/a&gt; &amp;lt;preview &lt;a href="http://bit.ly/aa9trp+"&gt;http://bit.ly/aa9trp+&lt;/a&gt; &amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2246334742525754530?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2246334742525754530/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2246334742525754530' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2246334742525754530'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2246334742525754530'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-re-widgetsmodules.html' title='RE: [fw-mvc] Re: Widgets/Modules'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2914832207810946663</id><published>2011-02-06T05:53:00.001-08:00</published><updated>2011-02-06T05:53:51.559-08:00</updated><title type='text'>[fw-webservices] PUT method doesn't work with Zend_Rest_Client</title><content type='html'>Hello everyone!&lt;p&gt;I don&amp;#39;t really know how you are working here but I wanted to inform you that&lt;br&gt;I have posted a bug report on Jira :&lt;br&gt;&lt;a href="http://framework.zend.com/issues/browse/ZF-11030"&gt;http://framework.zend.com/issues/browse/ZF-11030&lt;/a&gt;&lt;p&gt;I really wanted to get your point on that.&lt;p&gt;Best,&lt;br&gt;Jawad&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2914832207810946663?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2914832207810946663/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2914832207810946663' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2914832207810946663'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2914832207810946663'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-webservices-put-method-doesnt-work.html' title='[fw-webservices] PUT method doesn&apos;t work with Zend_Rest_Client'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-5922916576536614652</id><published>2011-02-05T09:05:00.000-08:00</published><updated>2011-02-05T09:06:12.561-08:00</updated><title type='text'>[fw-mvc] Re: Widgets/Modules</title><content type='html'>Thomas List wrote:&lt;br&gt;&amp;gt; &lt;br&gt;&amp;gt; If anyone could point me towards a good tutorial or site which explains&lt;br&gt;&amp;gt; the development of Widget/Module in Zend I would really appreciate it. 		 	   		  &lt;br&gt;&amp;gt; &lt;br&gt;I&amp;#39;ve not seen a tutorial on this particular subject (not there there isn&amp;#39;t&lt;br&gt;one out there); however, may I suggest that you study the &amp;quot;ShareThis&amp;quot; code&lt;br&gt;to get an idea of what is possible.&lt;p&gt;-----&lt;br&gt;--&lt;br&gt;Wil Moore III&lt;p&gt;Why is Bottom-posting better than Top-posting:&lt;br&gt;&lt;a href="http://www.caliburn.nl/topposting.html"&gt;http://www.caliburn.nl/topposting.html&lt;/a&gt;&lt;p&gt;DO NOT TOP-POST and DO trim your replies:&lt;br&gt;&lt;a href="http://linux.sgms-centre.com/misc/netiquette.php#toppost"&gt;http://linux.sgms-centre.com/misc/netiquette.php#toppost&lt;/a&gt;&lt;br&gt;-- &lt;br&gt;View this message in context: &lt;a href="http://zend-framework-community.634137.n4.nabble.com/Widgets-Modules-tp3260964p3262026.html"&gt;http://zend-framework-community.634137.n4.nabble.com/Widgets-Modules-tp3260964p3262026.html&lt;/a&gt;&lt;br&gt;Sent from the Zend MVC mailing list archive at Nabble.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-5922916576536614652?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/5922916576536614652/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=5922916576536614652' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5922916576536614652'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/5922916576536614652'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-re-widgetsmodules.html' title='[fw-mvc] Re: Widgets/Modules'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-21921532646050919</id><published>2011-02-05T01:34:00.000-08:00</published><updated>2011-02-05T01:35:00.227-08:00</updated><title type='text'>Re: [fw-mvc] Cannot send headers</title><content type='html'>&amp;gt; What text editor are you using? It could be that your text editor is using utf with bom which inserts an invisible character before your starting &amp;lt;?php tag.&lt;br&gt;&amp;gt; &lt;p&gt;Try this:&lt;p&gt;&lt;a href="http://pastie.org/1530663"&gt;http://pastie.org/1530663&lt;/a&gt;&lt;p&gt;&lt;br&gt;Best regards,&lt;p&gt;Andreas&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-21921532646050919?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/21921532646050919/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=21921532646050919' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/21921532646050919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/21921532646050919'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-cannot-send-headers_05.html' title='Re: [fw-mvc] Cannot send headers'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-2646549740863305198</id><published>2011-02-04T17:42:00.001-08:00</published><updated>2011-02-04T17:42:45.087-08:00</updated><title type='text'>Re: [fw-mvc] Cannot send headers</title><content type='html'>What text editor are you using? It could be that your text editor is &lt;br&gt;using utf with bom which inserts an invisible character before your &lt;br&gt;starting &amp;lt;?php tag.&lt;p&gt;&lt;br&gt;On 04/02/2011 21:54, Lionel Morrison wrote:&lt;br&gt;&amp;gt; Running ZF 1.11.13 and getting the following execption on a &lt;br&gt;&amp;gt; $this-&amp;gt;_redirect();&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; I&amp;#39;ve checked for trash output and closing ?&amp;gt; tags but I find none. &lt;br&gt;&amp;gt; Anyone have any ideas as to why this might happen. I can render the &lt;br&gt;&amp;gt; pages just find on my local Zend CE server but not on my hosted solution.&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Also the pages render just fine if I call them directly. Get the below &lt;br&gt;&amp;gt; error on _redirect();&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; Thanks&lt;br&gt;&amp;gt; Lionel Morrison&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt;&lt;br&gt;&amp;gt; *&lt;br&gt;&amp;gt; Fatal error*: Uncaught exception &amp;#39;Zend_Controller_Response_Exception&amp;#39; &lt;br&gt;&amp;gt; with message &amp;#39;Cannot send headers; headers already sent in &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/application/controllers/AccountController.php, &lt;br&gt;&amp;gt; line 1&amp;#39; in &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php:321 &lt;br&gt;&amp;gt; Stack trace: #0 &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php(339): &lt;br&gt;&amp;gt; Zend_Controller_Response_Abstract-&amp;gt;canSendHeaders(true) #1 &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php(766): &lt;br&gt;&amp;gt; Zend_Controller_Response_Abstract-&amp;gt;sendHeaders() #2 &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/library/Zend/Controller/Front.php(992): &lt;br&gt;&amp;gt; Zend_Controller_Response_Abstract-&amp;gt;sendResponse() #3 &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/library/Zend/Application/Bootstrap/Bootstrap.php(97): &lt;br&gt;&amp;gt; Zend_Controller_Front-&amp;gt;dispatch() #4 &lt;br&gt;&amp;gt; /home/deadfish/public_html/gamebooks/library/Zend/Application.php(366): Zend_Application_Bootstrap_Bootstrap-&amp;gt;run() &lt;br&gt;&amp;gt; #5 /home/deadfish/public_html/gamebooks/public/i in &lt;br&gt;&amp;gt; */home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php* &lt;br&gt;&amp;gt; on line *321*&lt;br&gt;&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-2646549740863305198?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/2646549740863305198/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=2646549740863305198' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2646549740863305198'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/2646549740863305198'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-cannot-send-headers_04.html' title='Re: [fw-mvc] Cannot send headers'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-6196492411695577439</id><published>2011-02-04T14:48:00.001-08:00</published><updated>2011-02-04T14:48:35.627-08:00</updated><title type='text'>Re: [fw-mvc] Cannot send headers</title><content type='html'>Just a hunch, but have you looked at&lt;br&gt;/home/deadfish/public_html/gamebooks/application/controllers/AccountController.php,&lt;br&gt;line 1?&lt;p&gt;--&lt;br&gt;*Hector Virgen*&lt;br&gt;Sr. Web Developer&lt;br&gt;&lt;a href="http://www.virgentech.com"&gt;http://www.virgentech.com&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-6196492411695577439?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/6196492411695577439/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=6196492411695577439' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6196492411695577439'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/6196492411695577439'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/re-fw-mvc-cannot-send-headers.html' title='Re: [fw-mvc] Cannot send headers'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-3811605062077602479</id><published>2011-02-04T13:54:00.000-08:00</published><updated>2011-02-04T13:55:07.570-08:00</updated><title type='text'>[fw-mvc] Cannot send headers</title><content type='html'>Running ZF 1.11.13 and getting the following execption on a &lt;br&gt;$this-&amp;gt;_redirect();&lt;p&gt;I&amp;#39;ve checked for trash output and closing ?&amp;gt; tags but I find none. &lt;br&gt;Anyone have any ideas as to why this might happen. I can render the &lt;br&gt;pages just find on my local Zend CE server but not on my hosted solution.&lt;p&gt;Also the pages render just fine if I call them directly. Get the below &lt;br&gt;error on _redirect();&lt;p&gt;&lt;br&gt;Thanks&lt;br&gt;Lionel Morrison&lt;p&gt;&lt;br&gt;*&lt;br&gt;Fatal error*: Uncaught exception &amp;#39;Zend_Controller_Response_Exception&amp;#39; &lt;br&gt;with message &amp;#39;Cannot send headers; headers already sent in &lt;br&gt;/home/deadfish/public_html/gamebooks/application/controllers/AccountController.php, &lt;br&gt;line 1&amp;#39; in &lt;br&gt;/home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php:321 &lt;br&gt;Stack trace: #0 &lt;br&gt;/home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php(339): &lt;br&gt;Zend_Controller_Response_Abstract-&amp;gt;canSendHeaders(true) #1 &lt;br&gt;/home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php(766): &lt;br&gt;Zend_Controller_Response_Abstract-&amp;gt;sendHeaders() #2 &lt;br&gt;/home/deadfish/public_html/gamebooks/library/Zend/Controller/Front.php(992): &lt;br&gt;Zend_Controller_Response_Abstract-&amp;gt;sendResponse() #3 &lt;br&gt;/home/deadfish/public_html/gamebooks/library/Zend/Application/Bootstrap/Bootstrap.php(97): &lt;br&gt;Zend_Controller_Front-&amp;gt;dispatch() #4 &lt;br&gt;/home/deadfish/public_html/gamebooks/library/Zend/Application.php(366): &lt;br&gt;Zend_Application_Bootstrap_Bootstrap-&amp;gt;run() #5 &lt;br&gt;/home/deadfish/public_html/gamebooks/public/i in &lt;br&gt;*/home/deadfish/public_html/gamebooks/library/Zend/Controller/Response/Abstract.php* &lt;br&gt;on line *321*&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-3811605062077602479?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/3811605062077602479/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=3811605062077602479' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3811605062077602479'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/3811605062077602479'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-cannot-send-headers.html' title='[fw-mvc] Cannot send headers'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-2181687498608084775.post-1935708589706047718</id><published>2011-02-04T12:21:00.001-08:00</published><updated>2011-02-04T12:21:47.993-08:00</updated><title type='text'>[fw-mvc] Widgets/Modules</title><content type='html'>Hello, &lt;p&gt;I have just finished developing a website with a fairly large database where people can fill out a form and find out about energy incentives in their area.  Now my boss would like me to make a widget out of this form, and be able to embed it into other websites.  I&amp;#39;m looking for a good tutorial to follow before I start writing the code.  I&amp;#39;ve never built a widget/module before except an example login module.  I need to look at something more substantial since the database and business logic are fairly complex.  If anyone could point me towards a good tutorial or site which explains the development of Widget/Module in Zend I would really appreciate it.  &lt;p&gt;Regards, &lt;br&gt;Thomas&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/2181687498608084775-1935708589706047718?l=fcall.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fcall.blogspot.com/feeds/1935708589706047718/comments/default' title='帖子评论'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=2181687498608084775&amp;postID=1935708589706047718' title='0 条评论'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1935708589706047718'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2181687498608084775/posts/default/1935708589706047718'/><link rel='alternate' type='text/html' href='http://fcall.blogspot.com/2011/02/fw-mvc-widgetsmodules.html' title='[fw-mvc] Widgets/Modules'/><author><name>lazayworm</name><uri>http://www.blogger.com/profile/18405421187721389873</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
