Re: [fw-general] Zend_Locale

2009-10-29 Thread admirau
Ed Lazor-3 wrote: Hi, I'm trying to clean up my bootstrap. Is there a way to move these lines to application.ini? setlocale(LC_ALL, 'en_US.utf8'); Zend_Locale::setDefault('en'); I read through the manual and it looks like this is required in the bootstrap, but I'd like to double

Re: [fw-general] Autoload Doctrine Models

2009-10-19 Thread admirau
Svetlin Petrov wrote: Hi, Hope this will help: http://weierophinney.net/matthew/archives/220-Autoloading-Doctrine-and-Doctrine-entities-from-Zend-Framework.html http://weierophinney.net/matthew/archives/220-Autoloading-Doctrine-and-Doctrine-entities-from-Zend-Framework.html Regards,

[fw-general] Autoload Doctrine Models

2009-10-17 Thread admirau
How to autoload Doctrine models? My application structure looks like this: /application/ /application/models/ Booking.php /application/models/generated/ /application/models/generated/ BaseBooking.php These two model files are: // Bookind.php class Booking extends BaseBooking {} //

[fw-general] Auto escape all variables in View

2009-10-08 Thread admirau
Has anyone here already created custom View, which escapes all variables by default? Willing to share? -- regards takeshin -- View this message in context: http://www.nabble.com/Auto-escape-all-variables-in-View-tp25803270p25803270.html Sent from the Zend Framework mailing list archive at

[fw-general] Doctrine extensions and ZF

2009-09-27 Thread admirau
Did anyone managed to use Doctrine extensions (e.g. Taggable) with ZF? Where should I put Extension files? How to configure autoloader? Now I'm using dir structure like this: /library/ /library/Zend/ /library/Doctrine/ /library/Doctrine.php /library/Doctrine/Extensions/Taggable/

[fw-general] zend_feed: get n entries by getXpath

2009-09-26 Thread admirau
How to use Zend_Feed::getXpath() method, to limit feed entries just to five newest entries? -- regards takeshin -- View this message in context: http://www.nabble.com/zend_feed%3A-get-n-entries-by-getXpath-tp25623791p25623791.html Sent from the Zend Framework mailing list archive at

[fw-general] Zend_Navigation id attribute

2009-09-10 Thread admirau
How to set HTML ID attribute for first UL rendered with Zend_Navigation? (for menu view helper). I saw similar problem here, but no answers at all. http://www.nabble.com/Zend_Navigation-Menu-view-helper%2C-need-an-id-for-rendered-UL-td23498604.html -- regards takeshin -- View this message in

Re: [fw-general] Zend_Navigation id attribute

2009-09-10 Thread admirau
Daniel Latter-2 wrote: What about the params key? 'params' = array('id' = 'value') And where should I put this? As an option for renderMenu() does not work. -- regards takeshin -- View this message in context:

Re: [fw-general] sub-subForm not namespaced correctly?

2009-08-23 Thread admirau
admirau wrote: When I create a form, add subForm (1), and then a subForm to this subForm (2), id attribute of subForm (2) are not prepended with name of subForm(1). How to fix that? I saw there was a similar bug with display groups. -- regards takeshin Here is an example which

[fw-general] sub-subForm not namespaced correctly?

2009-08-22 Thread admirau
When I create a form, add subForm (1), and then a subForm to this subForm (2), id attribute of subForm (2) are not prepended with name of subForm(1). How to fix that? I saw there was a similar bug with display groups. -- regards takeshin -- View this message in context:

[fw-general] Zend_Form save to ini

2009-08-14 Thread admirau
Any chance to convert Zend_Form object to .ini format? How to achieve this? -- regards takeshin -- View this message in context: http://www.nabble.com/Zend_Form-save-to-ini-tp24979523p24979523.html Sent from the Zend Framework mailing list archive at Nabble.com.

Re: [fw-general] ZendX_JQuery regional

2009-08-13 Thread admirau
The best solution I have found so far: // detect language $locale = new Zend_Locale; $lang = $locale-getLanguage(); // change datepicker default language if ('en' !== $lang) { $this-view-JQuery()

Re: [fw-general] Zend Navigation - how to render submenus for only active item

2009-08-12 Thread admirau
AFAIK there is currently no option supporting this behavior. Custom helper is a good choice. The simplest solution is to hide items which you do not need with CSS. You can also use custom partial to display the menu. -- reagards takeshin u.kayani wrote: I`m trying to use Zend Navigation

Re: [fw-general] Zend Navigation - how to render submenus for only active item

2009-08-12 Thread admirau
AFAIK there is currently no option supporting this behavior. Custom helper is a good choice. The simplest solution is to hide items which you do not need with CSS. You can also use custom partial to display the menu. -- ragards takeshin u.kayani wrote: I`m trying to use Zend Navigation to

Re: [fw-general] framework.zend.com down??

2009-08-12 Thread admirau
keith Pope-4 wrote: Seems to be down for me Yes, I noticed the problems during last days too. For all the pages in *.zend.com domain. -- regards takeshin -- View this message in context: http://www.nabble.com/framework.zend.com-down---tp24934235p24937665.html Sent from the Zend

[fw-general] Zend Navigation renderSubmenu

2009-08-12 Thread admirau
I want to render a main menu (level zero), and then, submenu items if current page has subpages. I thought this should work: ?php echo $this-navigation()-menu()-setMaxDepth(0); ? ?php echo $this-navigation()-menu()-renderSubMenu(); ? but, if the current page has no sub-pages, submenu renders

Re: [fw-general] Zend Navigation - how to render submenus for only active item

2009-08-12 Thread admirau
u.kayani wrote: I`m surprised this behavior isn`t supported, it is a pretty common behavior for menus. Yea I agree CSS would be easiest just not very efficient. Maybe i`ll look into a customer view helper. According to the other poster there is a way to do it. If there is, could

Re: [fw-general] Zend Tool errors on Windows after upgrading to 1.9

2009-08-10 Thread admirau
Fix for this bug is described here: http://forums.zend.com/viewtopic.php?f=69t=1778 -- regards takeshin -- View this message in context: http://www.nabble.com/Zend-Tool-errors-on-Windows-after-upgrading-to-1.9-tp24889972p24895133.html Sent from the Zend Framework mailing list archive at

Re: [fw-general] Offline version of the documentation

2009-08-10 Thread admirau
mbneto wrote: You can download it from the http://framework.zend.com/download/latest Thanks, I have missed this version, found only docs for 1.6 version. -- regards takeshin -- View this message in context:

[fw-general] Offline version of the documentation

2009-08-09 Thread admirau
Is there any up to date offline version of the documentation to the ZF? How to obtain one? -- ragards takeshin -- View this message in context: http://www.nabble.com/Offline-version-of-the-documentation-tp24887234p24887234.html Sent from the Zend Framework mailing list archive at Nabble.com.

[fw-general] Zend Framework 2.0

2009-08-09 Thread admirau
Are there any known plans for ZF 2.0? It will be an 'regular' release? Are planned any 'breaktrough' features (e.g. application backend like in Symfony, ORM)? I'm sure, it will be backwards compatilble, but what can we expect? I've found only this roadmap for Zend_Controller:

[fw-general] Zend Tool errors on Windows after upgrading to 1.9

2009-08-09 Thread admirau
After upgrading to 1.9, zf.bat show version works fine, but all commands with 'create' throws errors like this: zf create action test An Error Has Occurred A project profile was not found. Zend Framework Command Line Console Tool v1.9.0 Details for action Create and

Re: [fw-general] Zend Tool errors on Windows after upgrading to 1.9

2009-08-09 Thread admirau
forgot to mention, that the project is created, and the profile exists. -- regards takeshin -- View this message in context: http://www.nabble.com/Zend-Tool-errors-on-Windows-after-upgrading-to-1.9-tp24889972p24889977.html Sent from the Zend Framework mailing list archive at Nabble.com.

RE: [fw-general] Zend Framework 2.0

2009-08-09 Thread admirau
There's a lot of questions… Will it be 5.3 only? Now PHP 5.3 is still unstable, there is no hostings for 5.3, so… when? I do not want to throw away my libraries which I will write till 2.0 since now, so it would be nice to know what is planned, e.g. previously mentioned stripping require_once's

[fw-general] List all modules, controllers or actions

2009-08-03 Thread admirau
Is there any chance to list all modules, controllers or actions used in project, or do I have to parse all the files with regex/reflection? -- regards takeshin -- View this message in context: http://www.nabble.com/List-all-modules%2C-controllers-or-actions-tp24802524p24802524.html Sent from

[fw-general] Switch application language

2009-08-01 Thread admirau
Which is the best way to switch between application languages? I set up translations in application.ini: resources.translate.data = APPLICATION_PATH/languages resources.translate.adapter = gettext resources.translate.options.scan = directory ;resources.translate.options.disableNotices = true

Re: [fw-general] Multiple containers in navigation application resource

2009-07-29 Thread admirau
tobis wrote: I would also like to know this. Is it possible You may have one navigation in app.ini, and render only part when needed, using something like this: $myMenuContainer = $nav-getOneByLabel('myLabel'); $this-navigation()-menu()-renderMenu($myMenuContainer); (*not tested)

Re: [fw-general] Zend_Navigation save to XML

2009-07-23 Thread admirau
DASPRiD wrote: It would be helpful when you could provide a dump of the generate Yes, this extend was wrong copy/paste. Here is the code: // action body $navigation = new Zend_Navigation(new Zend_Config_Xml(APPLICATION_PATH . '/configs/navigation/main.xml', 'main'));

[fw-general] Zend_Navigation save to XML

2009-07-22 Thread admirau
How to save Zend_Navigation to XML? I tried like this: $navigation = new Zend_Navigation(new Zend_Config_Xml(APPLICATION_PATH . '/configs/navigation/main.xml', 'main')); $config = new Zend_Config($navigation-toArray()); $config-setExtend('main'); $writer = new

[fw-general] Zend_Navigation custom rendering

2009-07-22 Thread admirau
I'm building navigation menu editor. When I display menu, I want to have additional links (edit, delete, addnew) after each navigation item. I suppose the best solution is to have custom view helper. My new helper My_View_Helper_Navigation_CustomMenu would be basically extension of

[fw-general] Re: Re[fw-general] moving Require_once

2009-07-05 Thread admirau
Matthew Ratzloff wrote: The complete command is therefore: % cd path/to/ZendFramework/library % find . -name '*.php' | grep -v './Loader/Autoloader.php' | \ xargs sed -E -i~ 's/(require_once)/\/\/ \1/g' % find . -name '*.php~' | xargs rm -f Shouldn't this script be part of the ZF

[fw-general] Re[fw-general] quest parameters from within view helper

2009-06-27 Thread admirau
I want my view helper to return unique string based on controller and action. Is it possible to get request parameters from within view helper? In the controller I would write $this-_getParams(); but I don't know how to obtain the same in my view helper. -- regards takeshin -- View this

Re: [fw-general] Internal Server Error using Zend_Feed

2009-06-14 Thread admirau
Customize wrote: I have found a tutorial on this http://www.alexatnet.com/node/11 and moved my logic in the controller accordingly instead of view. Now I am getting absolutely nothing. Looking at view source gives me !DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01

[fw-general] Get Zend_Form_Element validators as array

2009-06-14 Thread admirau
Is there any smart way to retrieve element validators as an array (like in .ini)? I'd like to return validator options as an JSON object to the JavaScript. Most of the properties of Zend_Validate are protected… -- regards takeshin -- View this message in context:

[fw-general] Zend_Form display groups from ini file

2009-06-04 Thread admirau
How to define group of form elements (displaygroups) when genering Zend_Form from .ini file? I define elements: ; username element elements.username.type = text elements.username.options.label = login elements.username.options.validators.alnum.validator = alnum

[fw-general] Multiple containers in navigation application resource

2009-06-02 Thread admirau
Is there a possibility to have multiple menus constructed via application.ini? Now I do: resources.view[] = resources.navigation.pages.indexFoo.label = Foo resources.navigation.pages.indexFoo.controller = index resources.navigation.pages.indexFoo.action = foo

Re: [fw-general] ZF CLI slow

2009-06-01 Thread admirau
Matthew Ratzloff wrote: So the obvious next step would be to post your PHP CLI include path. php -i | grep include_path include_path = c:\users\user\www\library;. = c:\users\user\www\library;. library/ Zend/ Doctrine/ PHPTAL/ I use SET

Re: [fw-general] ZF CLI slow

2009-05-31 Thread admirau
tfk wrote: Does running regular php(-cli) is just as slow? If so, I'd run php -m and disable module after module until you find the offender. Thanks. I have already tried that. Disabling all the modules in php.ini does not help. There are left some pre-compiled modules, but I don't

Re: [fw-general] ZF CLI slow

2009-05-31 Thread admirau
beberlei wrote: enable xdebug profiler and see with kcachegrind what took so long. my guess is the recursive search for all providers in your includepath is the problem. Output profiler file is 10 MB big… 99.78% percent of time take calls to:

[fw-general] ZF CLI slow

2009-05-30 Thread admirau
On my computer zf.bat is very slow. Even zf show version takes up to 30 seconds. Maybe it is not ZF isuuse but an PHP CLI one, but how to speed it up? Zend library folder is at the beginning of the include_path. I've tried ZEND_TOOL_INCLUDE_PATH but it does not help. (Vista, Apache 2.2 + PHP

Re: [fw-general] RFC: ZendX_Doctrine

2009-05-12 Thread admirau
Matthew Lurz wrote: Thanks. Eventually proposals will need to be create and submitted. I think we need to address some big-picture questions before getting into the details of any given component. admirau wrote: Take a look on my approach: http://wiki.github.com/taat/myzend

Re: [fw-general] RFC: ZendX_Doctrine

2009-05-10 Thread admirau
Jasone wrote: I am able, and have the time, to do this. I authored two of those proposals. Been waiting on the zend team :) (Or now that I look, maybe they're not moved to ready for review yet?) Jason Take a look on my approach: http://wiki.github.com/taat/myzend -- regards

[fw-general] Zend_Application PHPUnit tests

2009-05-09 Thread admirau
Hi! I have created basic project using Zend_Tool. There is a directory /tests/ with empty phpunit.xml and some empty test files. Now I want to test if application is set up correctly. phpunit bootstrap=../public/index.php colors=false convertErrorsToExceptions=true

Re: [fw-general] Autoload models with no namespace

2009-05-06 Thread admirau
Matthew Lurz wrote: While this is the behavior out of the box, Doctrine is flexible. Take a look at http://www.doctrine-project.org/documentation/manual/1_1/en/yaml-schema-files#features-examples:packages and

[fw-general] Re: Re[fw-general] source plugins in custom directory

2009-05-05 Thread admirau
admirau wrote: Is there a chance to tell application where to look for resources with My_ prefix directly from the application.ini config file, possibly without modifying default index.php? Solution found on Rob Allen's blog: pluginPaths.My_Application_Resource = My/Application

[fw-general] Autoload models with no namespace

2009-05-05 Thread admirau
Hi! Doctrine generates class for models in /application/models/ The model class are following this scheme // file /application/models/Tablename.php class Tablename {} I register used namespaces in application.ini: autoloadernamespaces.0 = My autoloadernamespaces.1 = Doctrine But model classes

Re: [fw-general] Autoload models with no namespace

2009-05-05 Thread admirau
Matthew Weier O'Phinney-3 wrote: How to register this empty namespace only for this one models directory? Add the directory to the include_path. Truly, that's the simplest way. That said, I'm going to say it once again: you should always namespace your classes. PHP.net recommends

Re: [fw-general] Autoload models with no namespace

2009-05-05 Thread admirau
Matthew Weier O'Phinney-3 wrote: Tell the autoloader to act as a fallback autoloader. Zend_Loader_Autoloader::getInstance()-setFallbackAutoloader(true); Thank you Matthew. That's what I wrote in my first post. I just asked, if this is the best way or are there any drawbacks (big?)

[fw-general] Dollar character in Zend_Config key

2009-05-04 Thread admirau
Hi! Im trying to pass application options from application.ini to the cache resource via following options: line: 19 of application.ini: resources.cache.frontend.regexps.^/$.cache = true Executing: $this-getOptions('resource'); produces exception: Zend_Config_Exception: Error parsing

Re: [fw-general] Dollar character in Zend_Config key

2009-05-04 Thread admirau
vince. wrote: Hey, No, You can't use HTML characters inside the ini file. Use HTML Entities instead. I'm afraid I don't understand what you mean. What works fine: resources.cache.frontend.regexps.a.cache = true This doesn't work: resources.cache.frontend.regexps.$.cache = true How

Re: [fw-general] Dollar character in Zend_Config key

2009-05-04 Thread admirau
On 2009-05-04 12:04, Vadim Gabriel wrote: Hey, I know that you could use html entities as values, Not sure if that applies for keys as well. There is no need to use entities. If *value* (not key) contains special characters, you just enclose it with double quotes.

[fw-general] Zend_Cache pages+gzip

2009-05-03 Thread admirau
Hi! Below is fragment of my bootstrap file in which I enable gzip compression for all pages. It works fine unless I start caching pages via Zend_Cache_Frontend_Page. How should I enable gzip compression for cached pages too? /** * Send response to the browser * @access public

Re: [fw-general] Zend_Tool customization

2009-05-03 Thread admirau
Ralph Schindler-2 wrote: Yes, my plan for this week is to get out both module support as well as custom profile support. I will drop a note to the list when its ready to test from trunk/ Will be right here waiting for you :) Thanks. -- regards takeshin -- View this message in

[fw-general] Zend_Tool customization

2009-05-02 Thread admirau
I'm creating projects using Zend_Tool provided with ZF 1.8. How change default view suffix to .xhtml instead of .phtml (I'm using PHPTAL). How to create module? Can I have default module in 'modules' directory? -- regards takeshin -- View this message in context: