[symfony-users] Symfony with MS-SQL Server
Hello list, are there any experiences running symfony 1.4 with Microsoft SQL Server backends? is it stable, are there any known bugs or problems? thx axel -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] several parallel requests from one client?
hello, when I start a symfony web request that needs several seconds to be finished, other requests to the same server/symfony application sent from the same client browser are locked until the first request is finished. (requests started during the processing time of the first long request that are sent from other clients (with other cookies and client ips) are processed immediately. is this a symfony configured behaviour (max parallel requests per cookie or per ip?) or rather an apache config issue? kind regards axel -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: several parallel requests from one client?
thx for your help: adding: $this-getUser()-shutdown(); session_write_close(); to the actions that usually take a long time (eg. pdf generation, xls exports,...) solved our problem thx a lot! On 1 Nov., 11:59, Gareth McCumskey gmccums...@gmail.com wrote: I wrote a blog post about this ages back. Feel free to take a look: http://garethmccumskey.blogspot.com/2009/10/php-session-write-locking... On Mon, Nov 1, 2010 at 12:26 PM, axel at axel.zu...@gmail.com wrote: hello, when I start a symfony web request that needs several seconds to be finished, other requests to the same server/symfony application sent from the same client browser are locked until the first request is finished. (requests started during the processing time of the first long request that are sent from other clients (with other cookies and client ips) are processed immediately. is this a symfony configured behaviour (max parallel requests per cookie or per ip?) or rather an apache config issue? kind regards axel -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- Gareth McCumskeyhttp://garethmccumskey.blogspot.com twitter: @garethmcc -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: several parallel requests from one client?
On 1 Nov., 12:54, Gareth McCumskey gmccums...@gmail.com wrote: $this-getUser()-shutdown() == session_write_close(); No need for both :) hm in symfony 1.4.6 session_write_close(); is only called within the shutdown function of sfSessionStorage class. but not called from sfBasicSecurityUser-shutdown() nor from sfUser.shutdown() so I had to call it after $this-getUser()-shutdown()... maybe a symfony change? On Mon, Nov 1, 2010 at 1:36 PM, axel at axel.zu...@gmail.com wrote: thx for your help: adding: $this-getUser()-shutdown(); session_write_close(); to the actions that usually take a long time (eg. pdf generation, xls exports,...) solved our problem thx a lot! On 1 Nov., 11:59, Gareth McCumskey gmccums...@gmail.com wrote: I wrote a blog post about this ages back. Feel free to take a look: http://garethmccumskey.blogspot.com/2009/10/php-session-write-locking... On Mon, Nov 1, 2010 at 12:26 PM, axel at axel.zu...@gmail.com wrote: hello, when I start a symfony web request that needs several seconds to be finished, other requests to the same server/symfony application sent from the same client browser are locked until the first request is finished. (requests started during the processing time of the first long request that are sent from other clients (with other cookies and client ips) are processed immediately. is this a symfony configured behaviour (max parallel requests per cookie or per ip?) or rather an apache config issue? kind regards axel -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com symfony-users%2bunsubscr...@googlegroups.comsymfony-users%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- Gareth McCumskeyhttp://garethmccumskey.blogspot.com twitter: @garethmcc -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- Gareth McCumskeyhttp://garethmccumskey.blogspot.com twitter: @garethmcc -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: doctrine query and not in (select ...) doesnt work
hm adding an alias in the subquery leads to a doctrine exception :-( regards axel On 24 Okt., 16:52, Stéphane stephane.er...@gmail.com wrote: Perhaps you should add an alias in the subquery for the table ? Regards, Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Sun, Oct 24, 2010 at 4:33 PM, axel at axel.zu...@gmail.com wrote: hello, I need the follwing query: - select * from person p where ... and (p.personid not in (select personid form person2building...) where person2building is an m:n relation connecting person and building table via primary keys the following doctrine query $q = Doctrine_Query::create() -from('Person p') ... -andWhere('p.personid not in (select personid from person2building where buildingid = ' . $buildingid . ') '); generates the following sql statement, that doesn't work because of the (select p.pesonid ... ) in the subselect section - select * from person p ... and (p.personid not in (select p.personid form person2building...) any ideas how to solve this? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] doctrine query and not in (select ...) doesnt work
hello, I need the follwing query: - select * from person p where ... and (p.personid not in (select personid form person2building...) where person2building is an m:n relation connecting person and building table via primary keys the following doctrine query $q = Doctrine_Query::create() -from('Person p') ... -andWhere('p.personid not in (select personid from person2building where buildingid = ' . $buildingid . ') '); generates the following sql statement, that doesn't work because of the (select p.pesonid ... ) in the subselect section - select * from person p ... and (p.personid not in (select p.personid form person2building...) any ideas how to solve this? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] distinguishing between task and web request
hello, I need to distinguish if a model function was called within a web request or run within a task (to avoid error thrown by sfContext::getInstance() when executed within a taks) thx for your help -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: distinguishing between task and web request
works for me thx a lot! On 13 Okt., 11:09, Stéphane stephane.er...@gmail.com wrote: You can check for isset($_SERVER['HTTP_HOST']) I guess, Cheers, Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Wed, Oct 13, 2010 at 11:08 AM, axel at axel.zu...@gmail.com wrote: hello, I need to distinguish if a model function was called within a web request or run within a task (to avoid error thrown by sfContext::getInstance() when executed within a taks) thx for your help -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: distinguishing between task and web request
I am aware of that, but then I have to change my question: I've got a modell with 1:n related objects and I need to change some settings preCreate the related objects how can I access the (new generated) objects that are created via embedded forms in the controller action: processForm... $newObject = $form-save(); On 13 Okt., 12:49, Thomas Rabaix tho...@rabaix.net wrote: You are doing something wrong, models must be context independant On Wed, Oct 13, 2010 at 11:17 AM, axel at axel.zu...@gmail.com wrote: works for me thx a lot! On 13 Okt., 11:09, Stéphane stephane.er...@gmail.com wrote: You can check for isset($_SERVER['HTTP_HOST']) I guess, Cheers, Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Wed, Oct 13, 2010 at 11:08 AM, axel at axel.zu...@gmail.com wrote: hello, I need to distinguish if a model function was called within a web request or run within a task (to avoid error thrown by sfContext::getInstance() when executed within a taks) thx for your help -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com symfony-users%2bunsubscr...@googlegroups.comsymfony-users%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -- Thomas Rabaixhttp://rabaix.net -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] order by with m:n relation
Invoice: columns: id: ... relations: Items: refClass: invoice2item local: invoiceid foreign:itemid alise: itemlist invoice2item: tablename... options: orderBy: name columns: invoiceid... itemid... relations invoice: local: invoiceid foreign:id item: local: itemid forien: id item: tablename:... colums: id... name: varchar(255) problem: I need to sort $invoice-getItems() by item.name for some cases (when symfony joins with items) this works by setting: options: orderBy: name into invoice2item but in some cases symfony doesnt't create full join sql statements and throws errors like unknown column name order by name (select * from invoice2item where order by name) is there an easier solution or do I have to overwrite the getItems() function? thx a lot -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Add description text after formWidgets in admin generator
hello, sometimes I would like to render a certain description text after a sfWidgetFormInputText rendered by admin generator. eg. SpecialTextAttribut [__] Please enter your bla bla bla any ideas how to achieve this? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: Add description text after formWidgets in admin generator
great! thx a lot On 14 Sep., 15:51, Massimiliano Arione garak...@gmail.com wrote: On 14 Set, 12:43, axel at axel.zu...@gmail.com wrote: sometimes I would like to render a certain description text after a sfWidgetFormInputText rendered by admin generator. eg. SpecialTextAttribut [__] Please enter your bla bla bla any ideas how to achieve this? You can find it in the docs: http://www.symfony-project.org/forms/1_4/en/A-Widgets#chapter_a_sub_s... cheers Massimiliano -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] custom url for doctineRouteCollection
hello, Car: class: sfDoctrineRouteCollection options: model:Car module: car prefix_path: /car column: id with_wildcard_routes: true to generate the edit url I can use: url_for('@car_edit?id=' . $car-getId()); generates /car/12345/edit but how can I generate an url for a new action for example url_for('@car_showCertificate?id=' . $car-getId()); should generate car/12345/showCertificate mapped to modules/car/actions/actions.class.php - function executeShowCertificate(...)? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] using same template in different applications
is it possible to use a template in several different applications of the same project? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] disable form value remembering?
symfony rembembers filter settings in admin generated forms, is there a way to disable that (globaly / or for certain modules)? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Where to place model integrity checks
Additional to FormValidation I often need model lowlevel integritychecks before saving an object. eg. to check if there are related objects before delete. I think these checks should be placed in the model class, but it's neccessary to call them from an actioncontroller and to deal there with the possible thrown errors to generated userfriendly flash messages. is there an existing pattern in the symfony framework that I could/ should use to implement this? thx -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: direct sql in Doctrine_Migration class
works for me! thx a lot On 23 Jul., 17:33, Dennis gear...@sbcglobal.net wrote: Does this work for you? $sql=Do someting in SQL; $PDOHandle = Doctrine_Manager::getInstance()-getCurrentConnection()-getDbh(); $result=$PDOHandle-query($sql); //test result Remember, it happens outside of Doctrine/Propel. Do any necessary refreshes to ket the in mmeory object graphs to be accurate. Or do: //for all records $record-free); $record=NULL; Consider doing tthe follwoing as well: $conn=Doctrine_Manager::getInstance()-getCurrentConnection(); $conn-clean(); (or is it $conn-clear();?) On Jul 22, 1:49 pm, axel at axel.zu...@gmail.com wrote: hello, I would need an example how to use direct sql statements within the up() function of an doctrine migration class (extends Doctrine_Migration_Base) thx -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] direct sql in Doctrine_Migration class
hello, I would need an example how to use direct sql statements within the up() function of an doctrine migration class (extends Doctrine_Migration_Base) thx -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] how to get changes in modell class pre update
hello, I have a model with an integer attribute - invitationCount, in case of an model update I would need to know the old and new value. public function preUpdate($event) { $oldValue = $this-getInvitationCount(); $newValue = .? } -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] orderBy of embedded relations
hello, I use embedRelation in a form to embed a 1:n relation $this-embedRelation('Events', 'myEventForm'); Events has in schema.yml options: orderBy: date ASC but it isn't used within the embedded form rendering. (if I use $eventlist = $location-getEventList(); the returned events are sorted by date) any ideas how to solve this problem? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: custom rendering of sfWidgetFormDoctrineChoice?
I used the following solution: first I extended sfWidgetFormSelectCheckbox overwriting the formatter function class myWidgetFormSelectCheckboxTable extends sfWidgetFormSelectCheckbox { public function formatter($widget, $inputs) { $rows = array(); $itemsPerRow = sfConfig::get('app_itemsperrow_typus'); $i=0; $rows[] = table; foreach ($inputs as $input) { if ($i % $itemsPerRow == 0) { $rows[] = tr; } $rows[] = $this-renderContentTag('td', $input['input'].$this- getOption('label_separator').$input['label']) ; $i++; if ($i % $itemsPerRow == 0) { $rows[] = /tr; } } $rows[] = /table; return !$rows ? '' : $this-renderContentTag('ul', implode($this- getOption('separator'), $rows), array('class' = $this- getOption('class'))); } } and in the form $this-setWidget('typeList', new sfWidgetFormDoctrineChoice(array( 'multiple' = true, 'expanded' = true, 'order_by' = array('name', 'asc'), 'model' = 'Typus', 'renderer_class' = 'myWidgetFormSelectCheckboxTable' ))); maybe there are smarter solutions but it works. On 16 Mrz., 10:15, Tom Ptacnik to...@tomor.cz wrote: Maybe this.. sfWidgetFormSchemaDecorator http://www.symfony-project.org/forms/1_4/en/A-Widgets On 11 bře, 12:02, axel at axel.zu...@gmail.com wrote: hello, the render method of new sfWidgetFormDoctrineChoice(array( 'multiple' = true, 'expanded' = true, renders the choices as unordered list. what's the easiest way to customize this, eg. rendering divs or table structures etc. -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: Disable checkbox without loosing value?
overwriting the doBind works for me but it's an ugly solution - other frameworks use checkbox widgets with hidden fields to solve this problem, would be nice for symfony too. anyway thx for your solution On 7 Apr., 17:19, Gábor Fási maerl...@gmail.com wrote: It gets overwritten because browsers do not send disabled inputs' values, just like when a checkbox is not checked. Therefore symfony interprets it as a false. Overwrite the forms doBind() method, to set the fields current value in the input (tainted) array. On Wed, Apr 7, 2010 at 16:13, axel at axel.zu...@gmail.com wrote: hello, to disable a checkbox in a form for certain users I use: if (!user-mayXY() { $this-widgetSchema['active'] = new sfWidgetFormInputCheckbox(array(), array('disabled' = 'disabled')); } to disable editing of the checkbox but still displaying the current setting. the problem is that symfony overwrites the current value with 0 in case of form submit! (using symfony 1.4.3 schema.yml active: { type: boolean, notnull: true, default: 0 } (same problem with sfWidgetFormInput but here it works to set readonly new sfWidgetFormInput(array(), array('readonly' = 'readonly', 'class' = 'readonly'));) -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject. -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Disable checkbox without loosing value?
hello, to disable a checkbox in a form for certain users I use: if (!user-mayXY() { $this-widgetSchema['active'] = new sfWidgetFormInputCheckbox(array(), array('disabled' = 'disabled')); } to disable editing of the checkbox but still displaying the current setting. the problem is that symfony overwrites the current value with 0 in case of form submit! (using symfony 1.4.3 schema.yml active: { type: boolean, notnull: true, default: 0 } (same problem with sfWidgetFormInput but here it works to set readonly new sfWidgetFormInput(array(), array('readonly' = 'readonly', 'class' = 'readonly'));) -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en To unsubscribe, reply using remove me as the subject.
[symfony-users] Re: m:n with orderBy setting in yml is ignored
hello, I found a solution by adding a default sort order to the Visitor model: Visitor: options: orderBy: name ASC columns: id: ... On 16 Feb., 16:06, Tom Ptacnik to...@tomor.cz wrote: I think there were topic like that, and if I remember right the answer is bad ... it's not possible. On 16 ún, 15:51, axel at axel.zu...@gmail.com wrote: hm no one with the same problem here? On 15 Feb., 14:41, axel at axel.zu...@gmail.com wrote: hello, using symfony 1.4 with doctrine: how can I add an order by xy to the default doctrine getter example: Event: columns: id: type: integer(4) primary: true title: type: varchar(255) Visitor: class: Visitor refClass: Event2Visitor local: id foreign: id orderBy: name foreignAlias: Visitors Visitor: columns: id: type: integer(4) primary: true name: type: varchar(255) Event2Visitor: columns: eventid: type: integer(4) primary: true visitorid: type: integer(4) primary: true relations: Visitor local: visitorid foreign: id Event: local: eventid foreign: id var event = foreach ( event-getVisitors() ) is ordered by id and not by name, the orderBy name setting in schema.yml seems to be ignored -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: problems with embedRelation with a self related m:n
type: many didn't change the problem On 4 Mrz., 09:24, romain godefroy romain.godef...@wanadoo.fr wrote: hi, Have you tried to defined the relation with type: many I don't know if it could change anything for you but it should be test ? On 3 mar, 20:56,axelat axel.zu...@gmail.com wrote: I have a list of persons, and an m:n relation that relates one person with several other persons: Person: columns: id type: integer(4) primary: true name: string(255) relations: # m:n Person2Person Person: class: Person refClass: Person2Person local: id foreign: related foreignAlias: contactPerson # m:n Person2Person: columns: id: type: integer(4) primary: true relatedId: type: integer(4) primary: true relations: Person: class: Person local: relatedId foreign: id Person2: class: Person local: id foreign: id in the PersonFrom class i use $this-embedRelation('RelatedPersons', myRelatedPersonForm); everything works fine: symfony embedds 1 to n related person forms into the main person form also updates work fine the problem ist following: each time saving the form symfony commits a query like: update person2person set id = 100 where (id=200 and relatedId=100) (200 is the id of the main form and 100 the relatedId) and of course this destroys the realation. any idea whats wrong and why this happens? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] Re: problems with embedRelation with a self related m:n
On 5 Mrz., 08:22, Tom Ptacnik to...@tomor.cz wrote: Maybe it's only a typo here, but in relation definition in the Person table you have foreign: related and it should be foreign: relatedId it's only a simplified example for my problem - so yes a typo but not the problem. Or maybe the problem is that if you have M:N relation, you have schema like this: Table1 ... relation: local: id1 foreign: id2 ... Table2 ... relation: local: id2 foreign: id1 Table12 .. there is an existing database schema and I can't change the structure because there is a lot of legacy code :-( But you have only Table1 and the relation definition has always local:id1 and never comes to the object where local is id2 - even if it's a related object... maybe this can couse trables In this case the Nest relations can be the solution. I don't know, maybe my reflection is bad, or maybe nobody will uderstand me :-) On 3 bře, 20:56,axelat axel.zu...@gmail.com wrote: I have a list of persons, and an m:n relation that relates one person with several other persons: Person: columns: id type: integer(4) primary: true name: string(255) relations: # m:n Person2Person Person: class: Person refClass: Person2Person local: id foreign: related foreignAlias: contactPerson # m:n Person2Person: columns: id: type: integer(4) primary: true relatedId: type: integer(4) primary: true relations: Person: class: Person local: relatedId foreign: id Person2: class: Person local: id foreign: id in the PersonFrom class i use $this-embedRelation('RelatedPersons', myRelatedPersonForm); everything works fine: symfony embedds 1 to n related person forms into the main person form also updates work fine the problem ist following: each time saving the form symfony commits a query like: update person2person set id = 100 where (id=200 and relatedId=100) (200 is the id of the main form and 100 the relatedId) and of course this destroys the realation. any idea whats wrong and why this happens? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] problems with embedRelation with a self related m:n
I have a list of persons, and an m:n relation that relates one person with several other persons: Person: columns: id type: integer(4) primary: true name: string(255) relations: # m:n Person2Person Person: class: Person refClass: Person2Person local: id foreign: related foreignAlias: contactPerson # m:n Person2Person: columns: id: type: integer(4) primary: true relatedId: type: integer(4) primary: true relations: Person: class: Person local: relatedId foreign: id Person2: class: Person local: id foreign: id in the PersonFrom class i use $this-embedRelation('RelatedPersons', myRelatedPersonForm); everything works fine: symfony embedds 1 to n related person forms into the main person form also updates work fine the problem ist following: each time saving the form symfony commits a query like: update person2person set id = 100 where (id=200 and relatedId=100) (200 is the id of the main form and 100 the relatedId) and of course this destroys the realation. any idea whats wrong and why this happens? -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en
[symfony-users] m:n problem
hello list, problem: I have to build a symfony model for an existing database structure and I'm not allowed to change the existing structure. there are two m:n related tables using the same m:n table partitioned with a type attribute: table1 id ... table2 id ... table3 id ... table1_to_table2_table3 table1.id id2 type (table2 | table3) question: I would need something like this: Table1_to_table2_table3 columns: id: type: integer(20) autoincrement: true primary: true type: type: string(1) id1: type: integer(4) id2: type: integer(4) relations: Table1: local: id1 foreign: id Table2: local: id2 type (syntax?) foreign: id any ideas? thx -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: m:n with orderBy setting in yml is ignored
hm no one with the same problem here? On 15 Feb., 14:41, axel at axel.zu...@gmail.com wrote: hello, using symfony 1.4 with doctrine: how can I add an order by xy to the default doctrine getter example: Event: columns: id: type: integer(4) primary: true title: type: varchar(255) Visitor: class: Visitor refClass: Event2Visitor local: id foreign: id orderBy: name foreignAlias: Visitors Visitor: columns: id: type: integer(4) primary: true name: type: varchar(255) Event2Visitor: columns: eventid: type: integer(4) primary: true visitorid: type: integer(4) primary: true relations: Visitor local: visitorid foreign: id Event: local: eventid foreign: id var event = foreach ( event-getVisitors() ) is ordered by id and not by name, the orderBy name setting in schema.yml seems to be ignored -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] m:n with orderBy setting in yml is ignored
hello, using symfony 1.4 with doctrine: how can I add an order by xy to the default doctrine getter example: Event: columns: id: type: integer(4) primary: true title: type: varchar(255) Visitor: class: Visitor refClass: Event2Visitor local: id foreign: id orderBy: name foreignAlias: Visitors Visitor: columns: id: type: integer(4) primary: true name: type: varchar(255) Event2Visitor: columns: eventid: type: integer(4) primary: true visitorid: type: integer(4) primary: true relations: Visitor local: visitorid foreign: id Event: local: eventid foreign: id var event = foreach ( event-getVisitors() ) is ordered by id and not by name, the orderBy name setting in schema.yml seems to be ignored -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] mergeForm, embeddForm, embedRelation
Hello list, are there any examples, docs for mergeForm, embeddForm, embedRelation and symfony 1.4? I try to embedd an 1:1 related object into a form using mergeForm. The attributes of the merged form are displayed correctly but save doesn't work. Unknown record property / related component x on y (x is an attribute of the embedded object and y is the base object that embedds the form. I found http://www.blogs.uni-osnabrueck.de/rotapken/2009/03/13/symfony-merge-embedded-form/ what seems to solve my problem but it doesn't work with symfony 1.4. thx axel -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Changing group title in admin generator edit view
hello, how can I change the displayed group title from an admin generated edit view: form: fields: display: NONE: [a,b,c] Group1: [x,y,z ] Group2: [u,v,w ] from eg Group1: special i18n title with öüß -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: Slow template rendering
On 28 Jan., 06:49, Eno symb...@gmail.com wrote: On Wed, 27 Jan 2010, axel at wrote: I didn't expect it to be faster than straight PHP, but it's about 35 times slower!!! do you have any constructive ideas for performance tuning? People always make such a simplistic comparisons. There's lots you can do, like optimize queries, use fumctional and template caching, etc. You also forget all the conveniences that using a framework brings you for free. You do actually have to learn a framework more fully before you can write code that makes such a comparison meaningful. -- I tried template caching, but it didnt't solve the problem as it is no problem with the templateing. the following code takes 25 seconds too: foreach ($event-getUserList() as $user) { $test = $user-getLastname(); } debugging toolbar shows that the query to get the result list only takes 4ms so where the rest 25 seconds come from? any ideas, this is really a huge problem and a need a solution since our customzers won't accept such response times. functional templateing wouldn't work here, since the result of getUserList() chances almost every second. maybe there is something wrong with my php/x-cache setup? any other ideas or suggestions? thx -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: Slow template rendering
there are 8 database requests consuming 6 ms at all (only one of them gets the list, the rest is about authentication, dynamic menus and security. (the query joins the user table with a taglist) - displayed data is only fetched out of the user table. On 28 Jan., 11:11, Stéphane stephane.er...@gmail.com wrote: Does the very first query to retrieve users is selecting all needed (by your code) fields and relations ? If not, objects will lazy-load properties and relations. How many db requests are there ? Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Thu, Jan 28, 2010 at 11:08 AM, axel at axel.zu...@gmail.com wrote: On 28 Jan., 06:49, Eno symb...@gmail.com wrote: On Wed, 27 Jan 2010, axel at wrote: I didn't expect it to be faster than straight PHP, but it's about 35 times slower!!! do you have any constructive ideas for performance tuning? People always make such a simplistic comparisons. There's lots you can do, like optimize queries, use fumctional and template caching, etc. You also forget all the conveniences that using a framework brings you for free. You do actually have to learn a framework more fully before you can write code that makes such a comparison meaningful. -- I tried template caching, but it didnt't solve the problem as it is no problem with the templateing. the following code takes 25 seconds too: foreach ($event-getUserList() as $user) { $test = $user-getLastname(); } debugging toolbar shows that the query to get the result list only takes 4ms so where the rest 25 seconds come from? any ideas, this is really a huge problem and a need a solution since our customzers won't accept such response times. functional templateing wouldn't work here, since the result of getUserList() chances almost every second. maybe there is something wrong with my php/x-cache setup? any other ideas or suggestions? thx -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en. -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: Slow template rendering
Hello Georg, thanx for your help, it was actually the creation of the user objects that took 90% oft the time, with your solution the execution time of the request went down to 5 seconds (2,5 seconds for the list rendering) whats imho ok for the rendering of a list containing 5000 resultrows. what's my learning: never use doctrine based object fetching for large resultsets? is there a way to enforce Doctrine_Core::HYDRATE_SCALAR eg for m:n relations eg: user - user2workshop - workshop (... foreignAlias: workshops) $user-getWorkshops(array(), Doctrine_Core::HYDRATE_SCALAR) ??? anyway thanks for your help! kind regards Axel On 28 Jan., 14:08, Georg Gell geor...@have2.com wrote: Axel, is it possible that the creation of the user objects takes such a long time? I don't know what your user objects do, or how many are in this list, but just for displaying the names of the users, I wouldn't create objects, but hydrate with Doctrine_Core::HYDRATE_SCALAR. Try if this works more quickly: set up this method in your Event object: class Event extends BaseEvent{ ... public function getUserListAsArray() { return Doctrine::getTable('Users')-createQuery()-where('event_id = ?', $this-id)-execute(array(), Doctrine_Core::HYDRATE_SCALAR); } and in the template: ?php foreach ($event-getUserListAsArray() as $user){ echo EOT tr td{$user['firstname']} {$user['lastname']}/td /tr EOT; } ? Does this solve your speed problem? Georg Am 27.01.2010 19:58, schrieb axel at: hello list, symfony seems to be extrem slow - compared to native php a request with the following code takes ~26 seconds (count($event- getUserList()) == 5000) ?php foreach ($event-getUserList() as $user): ? tr td?php echo $user-getFirstname(). . $user-getLastname (); ?/td /tr ?php endforeach; ? type calls time (ms) time (%) Configuration 13 1932.20 7 Factories 1 361.77 1 Database (Doctrine) 8 0.06 0 Action event/listAction 1 19.53 0 View Success for event/listAction 1 25653.20 93 Partial event/_assets 1 1.41 0 Partial event/_flashes 1 5.31 0 Component address/menuItems 1 68.60 0 Partial address/_menuItems 1 3.23 0 Component address/loginState 1 0.06 0 Partial address/_loginState 1 2.06 0 the doctrine database query is ok I don't think that the templating is the problem, (I tried to do the output with echo $user-... from within the action what took as long as if I used the template engine. for me it seems to be a doctrine problem (foreach...?) is there a way to improove this poor results? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: Slow template rendering
I just wrote the same code with standard php - direct database access, the request took 0,7 seconds! (same system as used above, intel cor...@3ghz with 8 gigs ram) On 27 Jan., 19:58, axel at axel.zu...@gmail.com wrote: hello list, symfony seems to be extrem slow - compared to native php a request with the following code takes ~26 seconds (count($event- getUserList()) == 5000) ?php foreach ($event-getUserList() as $user): ? tr td?php echo $user-getFirstname(). . $user-getLastname (); ?/td /tr ?php endforeach; ? type calls time (ms) time (%) Configuration 13 1932.20 7 Factories 1 361.77 1 Database (Doctrine) 8 0.06 0 Action event/listAction 1 19.53 0 View Success for event/listAction 1 25653.20 93 Partial event/_assets 1 1.41 0 Partial event/_flashes 1 5.31 0 Component address/menuItems 1 68.60 0 Partial address/_menuItems 1 3.23 0 Component address/loginState 1 0.06 0 Partial address/_loginState 1 2.06 0 the doctrine database query is ok I don't think that the templating is the problem, (I tried to do the output with echo $user-... from within the action what took as long as if I used the template engine. for me it seems to be a doctrine problem (foreach...?) is there a way to improove this poor results? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: Slow template rendering
I didn't expect it to be faster than straight PHP, but it's about 35 times slower!!! do you have any constructive ideas for performance tuning? On 27 Jan., 21:59, Eno symb...@gmail.com wrote: On Wed, 27 Jan 2010, axel at wrote: I just wrote the same code with standard php - direct database access, the request took 0,7 seconds! (same system as used above, intel cor...@3ghz with 8 gigs ram) Err, did really you expect a framework to be faster than straight PHP? -- -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: Advanced Forms Example
I found a (very dirty) solution but for now it works: I wrote a renderTextWidget: class renderTextWidget extends sfWidgetForm { public function configure($options = array(), $attributes = array ()) { parent::configure($options, $attributes); $this-addOption('template', ); } public function render($name, $value = null, $attributes = array(), $errors = array()) { return $this-getOption('template'); } } } and use it in the configure function of the my object form that contains the file-data: public function configure() { ... $this-setWidget(. ... if (!$this-isNew()) { $this-setWidget('delete, new renderTextWidget(array( 'template' = $deletelink, ))); On 14 Jan., 18:19, Fabrizio fabrizio.pucci...@gmail.com wrote: This problem affects me too. Nobody can give some help / info? How to add delete link with embedRelation() ? On 13 Gen, 17:29, axel at axel.zu...@gmail.com wrote: hi list, I'm using embedForm() and embedRelation() (described in:http://www.symfony-project.org/advent_calendar/8/enhttp://www.symfony... ) to handle upload of serveral files to objects of a certain class. everything works fine as described in the example. I use the form within an admin-generated view. my question: is there a easy way to add for example: download, deletelinks for each embeded relation? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Advanced Forms Example
hi list, I'm using embedForm() and embedRelation() (described in: http://www.symfony-project.org/advent_calendar/8/en http://www.symfony-project.org/advent_calendar/9/en ) to handle upload of serveral files to objects of a certain class. everything works fine as described in the example. I use the form within an admin-generated view. my question: is there a easy way to add for example: download, deletelinks for each embeded relation? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: sfWidgetFormJQueryDate option format is no longer supported in version 1.1.1?
there is already a ticket reporting this problem: http://trac.symfony-project.org/ticket/8041 I closed your ticket referring to 8041 I think mm-dd- is the standard format in the usa? greetings axel On 12 Jan., 07:57, dziobacz aaabbbcccda...@gmail.com wrote: I would like to use also format in sfWidgetFormJQueryDate in symfony 1.4. Here is my ticket:http://trac.symfony-project.org/ticket/8093#preview You can give there your suggestions so maybe fabien faster solve this problem. What is more I think current format: mm-dd- is wrong because in normal countries people use dd-mm- or at least -mm-dd. I don't know country where date has that strange format: mm-dd- xD On 7 Sty, 09:08, Massimiliano Arione garak...@gmail.com wrote: Tom, I fixed the layout issue. Thanks for reporting it. Massimiliano On 5 Gen, 19:38, Tom Ptacnik to...@tomor.cz wrote: I wanted to add a link to a printscreen to imageshack (with your datepicker in Opera), but when I add a link into this reply window it show me an error that I can't post it... On 5 led, 19:23, Tom Ptacnik to...@tomor.cz wrote: Hello Axel, I like your solution, but in Opera (v. 10.10) it has broken layout little bit ... -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: sfWidgetFormJQueryDate option format is no longer supported in version 1.1.1?
Hi Massimiliano, when I use your datepicker solution I still have the problem that the date selects are mm/dd/ and I would need dd/mm/ ( Date.format = 'dd.mm.'; is included in date_de.js ) On 31 Dez. 2009, 17:01, Massimiliano Arione garak...@gmail.com wrote: Forget sfWidgetFormJQuery and try this full-javascript solution:http://garakkio.altervista.org/datepicker/ On 29 Dic, 13:58, axel at axel.zu...@gmail.com wrote: after upgrading to symonfy 1.3 and sfFormExtraPlugin 1.1.1 the format option is no longer supported by sfWidgetFormJQuery $this-setWidgets(array( 'from_date' = new sfWidgetFormJQueryDate(array( 'image'='/images/icons/calendar_view_month.gif', 'format' = '%day%-%month%-%year%', 'culture' = 'de_AT') ), )); is there another way to change the date format (from mm-dd- to dd- mm-)? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] inconsistent line ending style - symfony 1.4.1
after upgrading to symfony 1.4.1 under windows (downloaded zip) doctrine:build-model generates Base* files with mixed line endings: '\n' and '\r\n' a svn commit doesn't work for those files svn: Inconsistent line ending style -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: sfWidgetFormJQueryDate option format is no longer supported in version 1.1.1?
no one here with the same problem? any ideas? thx On 29 Dez., 13:58, axel at axel.zu...@gmail.com wrote: after upgrading to symonfy 1.3 and sfFormExtraPlugin 1.1.1 the format option is no longer supported by sfWidgetFormJQuery $this-setWidgets(array( 'from_date' = new sfWidgetFormJQueryDate(array( 'image'='/images/icons/calendar_view_month.gif', 'format' = '%day%-%month%-%year%', 'culture' = 'de_AT') ), )); is there another way to change the date format (from mm-dd- to dd- mm-)? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: sfWidgetFormJQueryDate option format is no longer supported in version 1.1.1?
yes I use sfFormExtraPlugin 1.1.1, the latest stable version On 30 Dez., 19:29, gino pilotino spammm...@gmail.com wrote: is this the _latest_ sfFormExtraPlugin ? On 30 Dic, 13:51, axel at axel.zu...@gmail.com wrote: no one here with the same problem? any ideas? thx On 29 Dez., 13:58, axel at axel.zu...@gmail.com wrote: after upgrading to symonfy 1.3 and sfFormExtraPlugin 1.1.1 the format option is no longer supported by sfWidgetFormJQuery $this-setWidgets(array( 'from_date' = new sfWidgetFormJQueryDate(array( 'image'='/images/icons/calendar_view_month.gif', 'format' = '%day%-%month%-%year%', 'culture' = 'de_AT') ), )); is there another way to change the date format (from mm-dd- to dd- mm-)? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] symfony plugin:
PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] symfony plugin:*
Hello list, any plugin shell command (eg symfony plugin-list) produces the following error: PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 is there a way to fix this? thx a lot -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: symfony plugin:*
sorry, that doesn't solve the problem. I still get: c:\dev\projectXYs plugin:list Installed plugins: PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 symfony 1.3.1-stable # pear.symfony-project.com (symfony) sfDoctrineGuardPlugin 4.0.1-stable # plugins.symfony-project.org (symfony-plugins) - # pear.php.net (pear) On 29 Dez., 12:04, Stéphane stephane.er...@gmail.com wrote: Try to remove all your enablePlugins in your projectConfig and try again ? Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Tue, Dec 29, 2009 at 11:59 AM, axel at axel.zu...@gmail.com wrote: Hello list, any plugin shell command (eg symfony plugin-list) produces the following error: PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 is there a way to fix this? thx a lot -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en. -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: symfony plugin:*
the problem was a currupted sfformextraplugin.reg file after deleting plugins/.registry/..channgel.plugins.symfony- project.org/sfformextraplugin.reg and the pluginfolder plugins/ sfFormExtraPlugin I was able to reinstall formExtraPlugin and now everything works as it should On 29 Dez., 12:21, axel at axel.zu...@gmail.com wrote: sorry, that doesn't solve the problem. I still get: c:\dev\projectXYs plugin:list Installed plugins: PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 symfony 1.3.1-stable # pear.symfony-project.com (symfony) sfDoctrineGuardPlugin 4.0.1-stable # plugins.symfony-project.org (symfony-plugins) - # pear.php.net (pear) On 29 Dez., 12:04, Stéphane stephane.er...@gmail.com wrote: Try to remove all your enablePlugins in your projectConfig and try again ? Before Printing, Think about Your Environmental Responsibility! Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale! On Tue, Dec 29, 2009 at 11:59 AM, axel at axel.zu...@gmail.com wrote: Hello list, any plugin shell command (eg symfony plugin-list) produces the following error: PHP Notice: unserialize(): Error at offset 6885 of 20307 bytes in C: \PHP52\PEAR\pear\PEAR\Registry.php on line 1147 is there a way to fix this? thx a lot -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en. -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] sfWidgetFormJQueryDate option format is no longer supported in version 1.1.1?
after upgrading to symonfy 1.3 and sfFormExtraPlugin 1.1.1 the format option is no longer supported by sfWidgetFormJQuery $this-setWidgets(array( 'from_date'= new sfWidgetFormJQueryDate(array( 'image'='/images/icons/calendar_view_month.gif', 'format' = '%day%-%month%-%year%', 'culture' = 'de_AT') ), )); is there another way to change the date format (from mm-dd- to dd- mm-)? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] sfWidgetFormJQueryDate minDate
hello list, how can I set the minimal selectable date in sfWidgetFormJQueryDate I tried: config = {'minDate:. but it doesn't work $this-widgetSchema['gebdat'] = new sfWidgetFormJQueryDate(array ( format = '%day%-%month %-%year%', culture = 'de_AT', image = '/images/ calendar-chooser.jpg', config = '{minDate: new Date(1900, 1 - 1, 1)}' )); thx -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] admin generator edit form-save() deletes unbound attributes
hello, following prolbem with symfony 1.3 (and 1.2): admin generator, user/ edit view, action save: deletes parameters in database that are not bound! example: schema.yml: User: tableName: user columns: id: type: integer(4) primary: true name:string(35) ... Useraddon: tableName: useraddon columns: id: type: integer(4) primary: true age: type: integer steet: type: string(255) ... relations: User: foreignAlias: Useraddon local: id foreign: id foreignType: one generator.yml: form: display: Content: [name] $form-bind($request-getParameter($form-getName()), $request- getFiles($form-getName())); if ($form-isValid()) { . $adresse = $form-save(); == sets useraddon.age and useraddon.street to null! print_r( $request-getParameter($form-getName())); -- Array ( [id] = 8407 [_csrf_token] = 63c5d561c2594e4ed3c587de458fb5d9 [name] = Axel ) I thought that save() or doSave() only updates bound attributes?!!!? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: encoding problems with csv export
hi gabriel, using ?php echo mb_convert_encoding($result-get ($property),ISO-8859-1,UTF-8) works. thx for your help! axel On 15 Dez., 19:44, pghoratiu pghora...@gmail.com wrote: MS Excell does not get along too well with UTF8 CSV, these files work just fine with OpenOffice. If OpenOffice is not an option I suggest you search on Google for a possible workaround (switch to a different type of encoding for output text with mb_convert_encoding, UTF16 may work probably I have not tried this myself) or some library that writes .xls files directly.http://www.google.ro/search?q=php+excell+utf8 gabriel On Dec 15, 7:25 pm, axel at axel.zu...@gmail.com wrote: hello, I try to export result rows (from admin-generator) to a csv file: public function csvExport($pager) { ... $this-getResponse()-clearHttpHeaders(); $this-getResponse()-setHttpHeader('Content-Type', 'application/ vnd.ms-excel;charset=utf-8'); $this-getResponse()-setHttpHeader('Content-Disposition', 'attachment; filename='.$filename.'.csv'); $this-setLayout(false); $this-setTemplate('csv'); $this-properties = array(firstname, lastname, ...); $this-results = $pager-getResults(); cvsSuccess.php: ... ?php foreach ($results as $result): ? ?php foreach ($properties as $property): ??php echo $result-get ($property); ?;?php endforeach; ? ?php endforeach; ? if I open the exported csv with ultraedit special characters are displayed correctly (dos-utf8 filteype) but when opend with ms-excel special chars are not displayed correctly (ä - ö ) settings.yml contains: charset: utf-8 thx for your help -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] encoding problems with csv export
hello, I try to export result rows (from admin-generator) to a csv file: public function csvExport($pager) { ... $this-getResponse()-clearHttpHeaders(); $this-getResponse()-setHttpHeader('Content-Type', 'application/ vnd.ms-excel;charset=utf-8'); $this-getResponse()-setHttpHeader('Content-Disposition', 'attachment; filename='.$filename.'.csv'); $this-setLayout(false); $this-setTemplate('csv'); $this-properties = array(firstname, lastname, ...); $this-results = $pager-getResults(); cvsSuccess.php: ... ?php foreach ($results as $result): ? ?php foreach ($properties as $property): ??php echo $result-get ($property); ?;?php endforeach; ? ?php endforeach; ? if I open the exported csv with ultraedit special characters are displayed correctly (dos-utf8 filteype) but when opend with ms-excel special chars are not displayed correctly (ä - ö ) settings.yml contains: charset: utf-8 thx for your help -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] problem with admin generator
hello list, in my current project I have to use an existing database and in this special case there is no way to change the given structure (which is not 3 normalized) Person: tableName: ... columns: id: type: integer(4) primary: true type1: integer(4) type2: integer(4) type3: integer(4) Type: tableName: columns: id: type: integer(4) primary: true autoincrement: true name: type: string(150) relations: Person: foreignAlias: type1 local: id foreign: type1 foreignType: one Person: foreignAlias: type2 local: id foreign: type2 foreignType: one Person: foreignAlias: type3 local: id foreign: type3 foreignType: one When I use generate-admin I have the following problem in Person/edit/ form: type1 and type2 are displayed as textinputfields while type3 is displayed as input type=select (as it should also be for type1 and type2) I think the problem is the not normalized data structure, but is there a way to solve this problem without normalizing the database? thx for your ideas -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] Re: sfGuardUser: Unknown method sfGuardUser::getProfile
the problem was my doctrine database yml with the following definition it works for doctrine: sfGuardUserProfile: columns: id: { type: integer, primary: true, autoincrement: true } user_id: { type: integer(4) } firstname: { type: string(255) } lastname: { type: string(255) } phone: { type: string(255) } address: { type: string(255) } relations: User: class: sfGuardUser local: user_id foreign: id type: one foreignType: one foreignAlias: Profile options: collate: utf8_unicode_ci charset: utf8 On 25 Nov., 11:49, tirengarfio tirengar...@gmail.com wrote: After following the README at sfDoctrineGuardPlugin doc, this is working for me: In the actions: $this-getUser()-getGuardUser()-getId() $this-getUser()-getGuardUser()-getUsername() $this-getUser()-getGuardUser()-getProfile()-getAddress() In the templates: $sf_user-getGuardUser()-getId() $sf_user-getGuardUser()-getUsername() $sf_user-getGuardUser()-getId()-getProfile()-getAddress() Javi On Nov 24, 11:43 pm, larry lkrub...@geocities.com wrote: I just had a similar issue. In my case, I had copied info from the schema.yml file that comes with the sfGuardUserPlugin to the top-level config/schema.yml file in my project. That was pretty stupid on my part. When I ran propel:build-model, Symfony generated some generic model classes with names like sfGuardUserPeer. These overrode all of the classes in the plugin, so I suddenly lost all of the functionality in the plugins. I needed to pull the sfGuardUser data out of my top- level schema.yml file, delete the generic models that just happened to have names like sfGuardUserPeer, and thus allow my site to see the code in the plugin. If I were you, I'd look for some place where you may have some code that is overriding the defaults in the plugin. On Nov 24, 9:55 am, axel at axel.zu...@gmail.com wrote: Hello, I try to customize the sfGuardUser model, therefore I added sfGuardUserProfile to my schema.yml and built/executed model and sql for it. here's the problem: $this-getUser()-getProfile()-getFirstName(); throws the following error: Unknown method sfGuardUser::getProfile my configuration: schema.yml ... sfGuardUserProfile: connection: xyz columns: id: type: integer(4) primary: true autoincrement: true userid: type: integer(4) first_name: varchar(20) last_name: varchar(20) birthday: date relations: sfGuardUser: foreignAlias: sfGuardUserProfile local: userid foreign: id foreignType: one myUser extends: class myUser extends sfGuardSecurityUser { } echo get_class($this-getUser()); myUser echo get_parent_class($this-getUser()); sfGuardSecurityUser I also added sf_guard_plugin: profile_class: sfGuardUserProfile profile_field_name: user_id to my app.yml any ideas? thx a lot -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] sfGuardUser: Unknown method sfGuardUser::getProfile
Hello, I try to customize the sfGuardUser model, therefore I added sfGuardUserProfile to my schema.yml and built/executed model and sql for it. here's the problem: $this-getUser()-getProfile()-getFirstName(); throws the following error: Unknown method sfGuardUser::getProfile my configuration: schema.yml ... sfGuardUserProfile: connection: xyz columns: id: type: integer(4) primary: true autoincrement: true userid: type: integer(4) first_name: varchar(20) last_name: varchar(20) birthday:date relations: sfGuardUser: foreignAlias: sfGuardUserProfile local: userid foreign: id foreignType: one myUser extends: class myUser extends sfGuardSecurityUser { } echo get_class($this-getUser()); myUser echo get_parent_class($this-getUser()); sfGuardSecurityUser I also added sf_guard_plugin: profile_class: sfGuardUserProfile profile_field_name: user_id to my app.yml any ideas? thx a lot -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en.
[symfony-users] sfGuard with several database connections
hello, I have defined two database connections in my databases.yml: all: xyz: class: sfDoctrineDatabase param: dsn: 'mysql:host=localhost;dbname=xyz' ... abc: class: sfDoctrineDatabase param: dsn: 'mysql:host=localhost;dbname=abc' installed sfGuardPlugin, the sf* databases are located in xyz database when I try to add a new user with: symfony guard:create-user --connection=xyz admin password I get the following error: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'avz.sf_guard_user' doesn't exist it seems that the --connection option is ignored? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=.
[symfony-users] Re: sfGuard with several database connections
Found an easier solution for the problem by adding connection: xyz to all model definitions in to the plugins/sfDoctrineGuardPlugin/config/doctrine/schema.yml: eg: sfGuardGroup: connection: xyz On 23 Nov., 13:57, Gareth McCumskey gmccums...@gmail.com wrote: The way I would do this in Propel instead is in my ModelClasses for the tables in database xyz is overwrite the doSelect, doSelectOne methods to explicitly call the correct connection: public static function (Criteria $criteria, $con = null) { parent::doSelect($criteria, Propel::getConnection('xyz')); } Also, ensure you have generated model classes for the xyz database and then cleared cache after you did that too On Mon, Nov 23, 2009 at 2:52 PM, axel at axel.zu...@gmail.com wrote: hello, I have defined two database connections in my databases.yml: all: xyz: class: sfDoctrineDatabase param: dsn: 'mysql:host=localhost;dbname=xyz' ... abc: class: sfDoctrineDatabase param: dsn: 'mysql:host=localhost;dbname=abc' installed sfGuardPlugin, the sf* databases are located in xyz database when I try to add a new user with: symfony guard:create-user --connection=xyz admin password I get the following error: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'avz.sf_guard_user' doesn't exist it seems that the --connection option is ignored? -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/symfony-users?hl=. -- Gareth McCumskeyhttp://garethmccumskey.blogspot.com twitter: @garethmcc -- You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-us...@googlegroups.com. To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/symfony-users?hl=.
[symfony-users] sfWidgetFormJQueryDate as default in auto generated code
hello list, 1) is there a way to make sfWidgetFormJQueryDate the default widgets for datetime fields in autogenerated code (Base*Form.classes) eg: class BaseTutorialForm extends BaseFormDoctrine { public function setup() { $this-setWidgets(array( 'id' = new sfWidgetFormInputHidden(), 'created_at' = new sfWidgetFormJQueryDate (sfConfig::get('sf_date_widget_settings')), 2) how can I change the date format in admin auto generator for input fields eg. for date filters I've tried something like form: class: BackendTutorialForm display: Content: [category_id, type, is_public, email] Admin: [_generated_token, is_activated, expires_at, created_at] fields: expires_at: { label: works, date_format:dd/MM/ } created_at: { label: for me, date_format:dd/MM/ } where the lables for expires_at and created_at are displayed correctly but the date_format settings don't have any effect in the edit/create form (using symfony 1.2.8 with doctrine) thx a lot --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Optimal PHP Version for Symfony 1.2
hello, I'm still new to symfony and php and need a little help: what's the most stable configuration for large webprojects for the moment? symfony 1.2 and php5.2.x or better php5.3.x. if symfony 1.2 php5.3 is recommendet, can anybody link me a tutorial how to get plugin:install (pear) working with this combination thx for your help --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Re: enable E_NOTICE
now it works! thx a lot 2009/9/23 nico nicolas.ri...@gmail.com Hi, You need to enable debug mode to see them Change your application configuration to $configuration = ProjectConfiguration::getApplicationConfiguration ('frontend', 'dev', true); Nicolas On Sep 23, 12:18 pm, peterreb axel.zu...@gmail.com wrote: Hi list, I'm new to symfony an need help by configuring error_reporting to enable E_NOTICE. error_reporting is set to E_ALL | E_PARSE in php.ini and settings.yml (for dev environment) $configuration = ProjectConfiguration::getApplicationConfiguration ('frontend', 'dev', false); but there are no Notice: Undefined variable: messages for example thx for your help -- Dipl.-Ing. Axel Zuzek grundsteingasse 64/2/25 1160 Wien tel: +43 650 678 email: a...@zuzek.info --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Symfony 1.1 Forms - how to validate a field only depending on input in another field?
Hi guys, I'm working with sf1.1 since quite some time now and I have to say that the form system is really, really great. With some of the tutorials out there (e.g. thatsquality.com), I was able to digg deeply into its inner workings and get things done. But there is something I just can't figure out: In short: I want a field to be validated only depending on the input in another field. Imagine a form, where a user can choose between two payment options: bank transfer and credit card (e.g. sfWidgetFormSelectRadio). This selection wil activate the validators for the relevant fields which are all required: Bank Transfer: bank name, account name, BIC/IBAN OR Credit Card: card organization, card number, expiry date On the view side, the relevant fields would be hidden and shown via JavaScript. But the widgets have to be there in the HTML, so they have to be created in the action. If there is no special form processing/ validation, submitting the form will always fail because some required fields would always be empty. Searching on google and asking in #symfony hinted me at using postValidator. But I couldn't figure out how to do it that way. There are several disadvantages with postValidator, as I think: - I can only access values in the current form, but would do you do if you have forms, embedded in forms? - I have to use the postValidator on the first widget (e.g. payment option) and add the validators of the dependant widgets (e.g. bank transfer or credit card). But what do you do, if you have several dependancies? I came up with my own solution to this problem, but I think it's the worst possible solution there is. I created my own form class extending sfForm, which has a method activateValidators(). All validators in this class are stored temporarily in an array (and not directly in $this-validatorSchema). In the action, in the process of creating the forms, I check for the dependencies and call activateValidators() if needed. The method activateValidators() will copy the validators from my temporary array to $this-validatorSchema, thus finally making the validators active. The problem here is, that I work on the parameters directly, without having them validated/cleaned yet, because I'm in the process of building the form. Altough I would wish to have them already validated or cleaned. Is there a better way to solve this? Is there a symfony way of doing this? Please help me out. Also I think this is a common thing and Symfony 1.1 really should support this. Regards, Axel --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---