The problem was setting locale with 2 different method in the same time. I
have just removed setlocale() line in bootstrap, all the mystery and
IteratorAggregate not found problem were gone... Strange but true.

Most beginners don't read Zend coding standards and even they do, they might
think that those standards are not obligated for our application file naming
and class naming. Whatsoever I learnt it is obligated in any case and do not
use setlocale() and Zend_Locale::setDefault() together.

2008/11/14 Matthew Ratzloff <[EMAIL PROTECTED]>

> I have finally solved the problem!!
>>
>
> So... what was the problem?  It wasn't clear from your e-mail.
>
> There was another issue as well which might be the trigger of
>> IteratorAggregate problem above, a view helper (i believe action helper
>> would react same) in layout which was named as "xUrl". Class name was
>> "Zend_View_Helper_xUrl" and file name was xUrl.php starting with lower case.
>> After I fix the first problem I've seen ZF was tring to include XURL.php
>> which doesn't exist in linux servers but exist in developer machine (XP).
>>
>
> There is no "Zend_View_Helper_xUrl" class.  Here is a list of all view
> helpers packaged with Zend Framework:
>
>
> http://framework.zend.com/svn/framework/standard/trunk/library/Zend/View/Helper/
>
> First of, please improve the documantation about action and view helpers at
>> least put with bigger header that *helper names must start with Capital
>> letter*.
>>
>
>
> http://framework.zend.com/manual/en/coding-standard.naming-conventions.html#coding-standard.naming-conventions.classes
>
> Perhaps most relevant for this case:
>
> See the class names in the standard and extras libraries for examples of
>> this classname convention.  IMPORTANT: Code that must be deployed
>> alongside ZF libraries but is not part of the standard or extras libraries
>> (e.g. application code or libraries that are not distributed by Zend) must
>> never start with "Zend_" or "ZendX_".
>
>
> The naming convention is established and clear.
>
> -Matt
>
> On Thu, Nov 13, 2008 at 4:17 PM, kirpit <[EMAIL PROTECTED]> wrote:
>
>> I have finally solved the problem!!
>>
>> I'm not sure but this might be a bug. There were 2 lines in bootstrap
>> setting up the current locale option like;
>>
>> setlocale(LC_ALL, 'tr_TR');
>> Zend_Locale::setDefault('tr_TR');
>>
>> When it comes either to HelperBroker or Zend_Layout::startMvc or
>> Zend_Controller_Front::getInstance line, it stops script execution without
>> any exception or php error and putting "Interface 'IteratorAggregate' not
>> found in ...Zend/Controller/Action/HelperBroker/PriorityStack.php on line
>> 29" into error log with http 500.
>>
>> Putting an exit() right after these 2 lines produce nothing in error log
>> and "echo" works fine as well.
>>
>> There was another issue as well which might be the trigger of
>> IteratorAggregate problem above, a view helper (i believe action helper
>> would react same) in layout which was named as "xUrl". Class name was
>> "Zend_View_Helper_xUrl" and file name was xUrl.php starting with lower case.
>> After I fix the first problem I've seen ZF was tring to include XURL.php
>> which doesn't exist in linux servers but exist in developer machine (XP).
>>
>> First of, please improve the documantation about action and view helpers
>> at least put with bigger header that *helper names must start with
>> Capital letter*. And second, I'm ready to give any part of this project
>> in order to understand what was it about and is it really a bug...
>>
>> Cheers,
>> kirpit.
>> 13 Kasım 2008 Perşembe 02:38 tarihinde kirpit <[EMAIL PROTECTED]> yazdı:
>>
>>> Development:
>>> ------------->
>>> PHP version 5.2.6
>>> SPL present
>>> IteratorAggregate present
>>>
>>> Production 1: (which gives "IteratorAggregate not found error" in error
>>> log)
>>> ------------->
>>> PHP version 5.2.6
>>> SPL present
>>> IteratorAggregate present
>>>
>>> Production 2: (which stops execution on action helperBroker::addPath
>>> line)
>>> ------------->
>>> PHP version 5.2.1-0.dotdeb.1
>>> SPL present
>>> IteratorAggregate present
>>>
>>>
>>> By the way I've installed a simple workshop ZF application with no helper
>>> and no db, which works fine on both servers.
>>>
>>> Thanks for helping both of you ppl.
>>>
>>>
>>> 2008/11/13 Matthew Ratzloff <[EMAIL PROTECTED]>
>>>
>>>> Run this on both your development machine and the production machine
>>>> that's having issues:
>>>>
>>>> #!/usr/bin/php
>>>> <?php
>>>> print 'PHP version ' . phpversion() . "\n";
>>>>
>>>> if (extension_loaded('SPL')) {
>>>>     print "SPL present\n";
>>>> } else {
>>>>     print "SPL NOT present\n";
>>>> }
>>>>
>>>> if (interface_exists('IteratorAggregate')) {
>>>>     print "IteratorAggregate present\n";
>>>> } else {
>>>>     print "IteratorAggregate NOT present\n";
>>>> }
>>>>
>>>> My results:
>>>>
>>>> $ ./test.php
>>>> PHP version 5.2.6
>>>> SPL present
>>>> IteratorAggregate present
>>>>
>>>> Incidentally, IteratorAggregate does NOT appear in my `php -i` results.
>>>>
>>>>  -Matt
>>>>
>>>> 2008/11/12 kirpit <[EMAIL PROTECTED]>
>>>>
>>>>> Hi Till,
>>>>>
>>>>> SPL is installed and enabled as default as Matthew mentioned. And all
>>>>> the extentions are fine. You may check by yourself;
>>>>> http://sergistan.com/server.php
>>>>>
>>>>> 13 Kasım 2008 Perşembe 01:20 tarihinde till <[EMAIL PROTECTED]> yazdı:
>>>>>
>>>>>> 2008/11/12 kirpit <[EMAIL PROTECTED]>:
>>>>>> > Hi Matthew,
>>>>>> >
>>>>>> > Thank you for the reply.I have tried on two different shared hosts.
>>>>>> Both
>>>>>> > stucks on action helper line in bootstrap. Both doesn't look like
>>>>>> > having Gentoo whatever, both is running PHP 5.2+ and both are SPL
>>>>>> enabled.
>>>>>> > I'm sorry to say that but i'm kind of pissed off with ZF here... I
>>>>>> don't
>>>>>> > know what to do that we spent like 3 months for this project. Sad.
>>>>>>
>>>>>> And the hosts can't install the *standard* PHP library?
>>>>>>
>>>>>> I'm sure they will do it on request.
>>>>>>
>>>>>> Also, just to make sure you know about the requirements, check this
>>>>>> link:
>>>>>> http://framework.zend.com/manual/en/requirements.html
>>>>>>
>>>>>> Till
>>>>>> >
>>>>>> > 2008/11/12 kirpit <[EMAIL PROTECTED]>
>>>>>> > ---------- Yönlendirilmiş ileti ----------
>>>>>> > From: Matthew Weier O'Phinney <[EMAIL PROTECTED]>
>>>>>> > To: fw-general@lists.zend.com
>>>>>> > Date: Wed, 12 Nov 2008 14:31:28 -0500
>>>>>> > Subject: Re: [fw-general] Bootstrap Action HelperBroker stops
>>>>>> execution on
>>>>>> > production server
>>>>>> > -- kirpit <[EMAIL PROTECTED]> wrote
>>>>>> > (on Wednesday, 12 November 2008, 07:05 PM +0200):
>>>>>> >> I'm trying to install my first ZF project to many production server
>>>>>> and it
>>>>>> >> looks like ZF is only for development enjoyment. No one had any
>>>>>> idea about
>>>>>> >> following issue;
>>>>>> >> http://www.nabble.com/
>>>>>> >>
>>>>>> >>
>>>>>> Interface-'IteratorAggregate'-not-found-error-in-production-server-td20431706.html
>>>>>> >
>>>>>> > IteratorAggregate is an interface from PHP's SPL (standard PHP
>>>>>> library)
>>>>>> > which is included in default installs of PHP since 5.0. Please check
>>>>>> the
>>>>>> > PHP version on your production server.
>>>>>> >
>>>>>> > BTW, Gentoo notoriously disables SPL in their defaults builds -- you
>>>>>> > have to add it as an emerge option.
>>>>>> >
>>>>>> >> So i'm trying to install to one another shared hosting service
>>>>>> again with
>>>>>> >> pain.
>>>>>> >> This time the problem is about nothing. Yes, nothing outputs. No
>>>>>> freaky
>>>>>> >> null
>>>>>> >> empty nothing response body with http code 200. After debugging
>>>>>> bootstrap
>>>>>> >> file
>>>>>> >> line by line i'm stucted at
>>>>>> >> Zend_Controller_Action_HelperBroker::addPath(...);
>>>>>> >>
>>>>>> >> try {
>>>>>> >> echo 'echo 1'; // echoes
>>>>>> >> Zend_Controller_Action_HelperBroker::addPath('./library/Helpers',
>>>>>> >> 'Helper');
>>>>>> >> echo 'echo 2'; // never echoes on production server
>>>>>> >> } catch(Exception $error) {
>>>>>> >> print_r($error); // and never catch any error
>>>>>> >> }
>>>>>> >>
>>>>>> >> I'm sure there are other issues coming up but i please ask for help
>>>>>> in
>>>>>> >> this one
>>>>>> >> for now.
>>>>>> >
>>>>>> > --
>>>>>> > Matthew Weier O'Phinney
>>>>>> > Software Architect | [EMAIL PROTECTED]
>>>>>> > Zend Framework | http://framework.zend.com/
>>>>>> >
>>>>>> >>
>>>>>> >> Hi,
>>>>>> >>
>>>>>> >> I'm trying to install my first ZF project to many production server
>>>>>> and it
>>>>>> >> looks like ZF is only for development enjoyment. No one had any
>>>>>> idea about
>>>>>> >> following issue;
>>>>>> >>
>>>>>> >>
>>>>>> http://www.nabble.com/Interface-'IteratorAggregate'-not-found-error-in-production-server-td20431706.html
>>>>>> >>
>>>>>> >> So i'm trying to install to one another shared hosting service
>>>>>> again with
>>>>>> >> pain. This time the problem is about nothing. Yes, nothing outputs.
>>>>>> No
>>>>>> >> freaky null empty nothing response body with http code 200. After
>>>>>> debugging
>>>>>> >> bootstrap file line by line i'm stucted at
>>>>>> >> Zend_Controller_Action_HelperBroker::addPath(...);
>>>>>> >>
>>>>>> >> try {
>>>>>> >>  echo 'echo 1'; // echoes
>>>>>> >>  Zend_Controller_Action_HelperBroker::addPath('./library/Helpers',
>>>>>> >> 'Helper');
>>>>>> >>  echo 'echo 2'; // never echoes on production server
>>>>>> >> } catch(Exception $error) {
>>>>>> >>  print_r($error); // and never catch any error
>>>>>> >> }
>>>>>> >>
>>>>>> >> I'm sure there are other issues coming up but i please ask for help
>>>>>> in
>>>>>> >> this one for now.
>>>>>> >>
>>>>>> >> Cheers.
>>>>>> >>
>>>>>> >
>>>>>> >
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
>

Reply via email to