[symfony-users] Re: Security doubts on sfDoctrineGuardPlugin

2009-05-07 Thread Ken Marfilla
It does, if you will look closely at PluginsfGuardUserTable.php class PluginsfGuardUserTable extends Doctrine_Table { public static function retrieveByUsername($username, $isActive = true) { return Doctrine_Query::create() -from('sfGuardUser u') -where('u.username

[symfony-users] Re: Symfony on Windows - cache write permission

2009-05-07 Thread Tomasz Ignatiuk
C:\wamp\www\myproject 2009/5/7 Lawrence Krubner lkrub...@geocities.com On Apr 6, 5:46 am, Tomasz Ignatiuk tomek.ignat...@gmail.com wrote: I deinstalledwampserver 2.0c and installed new one, 2.0g and it works. I don't know what was the problem :( Where did you install your Symfony core

[symfony-users] Re: Doctrine DQL: where clause help

2009-05-07 Thread Ian P. Christian
2009/5/7 Mohd Shakir bin Zakaria mohdsha...@gmail.com: $ symfony doctrine:dql FROM Message m where('m.id = ?', 1) Yeah, it's a DQL string, not the API, so you don't use place holders like that 'FROM Message m WHERE m.id = 1' -- Blog: http://pookey.co.uk/blog Follow me on twitter:

[symfony-users] Storing NULL instead of empty string

2009-05-07 Thread Adrien Mogenet
Hi all, I get a very stupid question... and I'm really surprized to see that I can't find any solution thanks to Google ! Simple Model : -- user: id: ~ login: {varchar, required: false} foobar: {varchar, required: true} And then, when I'm filling my form, if I

[symfony-users] Re: Storing NULL instead of empty string

2009-05-07 Thread cokker
Do you use Sf1.2 with sfForm? If so have a look at the stringValidator if uses as empty value a string ('') not null greets Sven Adrien Mogenet schrieb: Hi all, I get a very stupid question... and I'm really surprized to see that I can't find any solution thanks to Google ! Simple

[symfony-users] Re: Doctrine DQL: where clause help

2009-05-07 Thread Mohd Shakir bin Zakaria
Thanks, it works now for me. My real problem is to actually change my admin generator to only display items from specific user, and so I create an overriding function at apps/app/modules/message/actions/actions.class.php to have this; class messageActions extends autoMessageActions { public

[symfony-users] where to set mysql user variables for trigger use

2009-05-07 Thread Roland Cruse
Hi I have a mysql trigger that is wanting a dynamic variable which my symfony app session would have after login. The logged in user id. The app can not be used without logging in. I have a filter that comes after the security filter which sets this variable with a mysql query (SET

[symfony-users] Re: Storing NULL instead of empty string

2009-05-07 Thread Adrien Mogenet
Yes I do :-) I'm going to check this now. I temporary overrode the setLogin() method which sets NULL if empty string. Thanks, Adrien On 7 mai, 10:40, cokker cokker...@googlemail.com wrote: Do you use Sf1.2 with sfForm? If so have a look at the stringValidator if uses as empty value a

[symfony-users] Re: Symfony on Windows - cache write permission

2009-05-07 Thread Tomasz Ignatiuk
Sorry it is in wamp/bin/php/php5.2.9-2/pear On 7 Maj, 09:22, Tomasz Ignatiuk tomek.ignat...@gmail.com wrote: C:\wamp\www\myproject 2009/5/7 Lawrence Krubner lkrub...@geocities.com On Apr 6, 5:46 am, Tomasz Ignatiuk tomek.ignat...@gmail.com wrote: I deinstalledwampserver 2.0c and

[symfony-users] Re: Storing NULL instead of empty string

2009-05-07 Thread cokker
Another way is to add a updateXXXColumn to the form: public function updateColumn($value) { if(empty($value)) return false; return $value; } replace XXX with your column-name. In case the value is empty the parameter is removed from the response and null schould be used.

[symfony-users] Fill manual Propel fields

2009-05-07 Thread HAUSa
I got a Propel form, to which I added two files manually. When I edit a Propel object, all database fields have a default value from the database. But now I want my two manual created fields to have default values to. I have a field named zipcode in the database. My two manually created fields

[symfony-users] Re: Fill manual Propel fields

2009-05-07 Thread Alexandru-Emil Lupu
HI! I guess something like: function getZipcode1(){ return substr($this-getZipcode(),0,4); } function getZipcode2(){ return substr($this-getZipcode(),4,2); } Alecs On Thu, May 7, 2009 at 5:07 PM, HAUSa jeroen_heeft_behoefte_aan_r...@hotmail.com wrote: I got a Propel form, to which I added

[symfony-users] Delay on getMessages

2009-05-07 Thread symfony.con.spir...@gmail.com
Hi all, for sending an action feedback to the user I use in my actions this: sfContext::getInstance()-getUser()-setMessage('My feedback'), 'warning'); For output in my partial this: ?php foreach($sf_context-getUser()-getMessageTypes() as $type) : ? ?php

[symfony-users] Re: Fill manual Propel fields

2009-05-07 Thread HAUSa
Thx for your reply! But helas, I already tried that. I even used a static String: public function getZipcode1(){ return '4923'; } But the value won't show up as a default value on edit... On 7 mei, 16:55, Alexandru-Emil Lupu gang.al...@gmail.com wrote: HI! I

[symfony-users] sfHelper in actions error

2009-05-07 Thread HAUSa
I get this message in the SF dev log: The sfLoader::loadHelpers() method is deprecated. Please use the same method from sfApplicationConfiguration. This is my actions.class.php: public function executeNew(sfWebRequest $oRequest){ sfLoader::loadHelpers('Url');

[symfony-users] Re: sfHelper in actions error

2009-05-07 Thread Gábor Fási
http://www.symfony-project.org/api/1_2/sfApplicationConfiguration#method_loadhelpers On Thu, May 7, 2009 at 17:29, HAUSa jeroen_heeft_behoefte_aan_r...@hotmail.com wrote: I get this message in the SF dev log: The sfLoader::loadHelpers() method is deprecated. Please use the same method from

[symfony-users] Re: Fill manual Propel fields

2009-05-07 Thread Gábor Fási
I guess this is what you're looking for: http://www.symfony-project.org/api/1_2/sfWidgetForm#method_setdefault On Thu, May 7, 2009 at 16:07, HAUSa jeroen_heeft_behoefte_aan_r...@hotmail.com wrote: I got a Propel form, to which I added two files manually. When I edit a Propel object, all

[symfony-users] Re: need advice: am switching from a Linux to a Windows development environment

2009-05-07 Thread Andrei Dziahel
Hi. My company loaned me an laptop with preinstalled WinXP. I've just resized windows' partition to free space for Linux et voilà! 2009/5/7 Jake Barnes lkrub...@geocities.com On May 6, 9:23 pm, Pablo Godel pgo...@gmail.com wrote: Have you considered running linux on vmware or virtual box?

[symfony-users] propel choice form - multi-select

2009-05-07 Thread Steve the Canuck
Hi, I am having some form troubles. I have a select dropdown which allows you select multiple options. If you select two options, I want to insert to records into the database. Here is a simple representation of the tables: User --- UserLevel --- Level So, I use the UserLevelForm and select

[symfony-users] Re: propel choice form - multi-select

2009-05-07 Thread Steve the Canuck
I should have titled this many-to-many. Basically all I'm looking for is an example of how to implement many to many relationships in forms. Thanks, Steve On May 7, 1:21 pm, Steve the Canuck steve.san...@gmail.com wrote: Hi, I am having some form troubles.  I have a select dropdown which

[symfony-users] Inserting new users into sfGuard tables

2009-05-07 Thread Reynier Perez Mira
Hi every: Recently I send some emails asking how to integrate sfGuard and LDAP authentication. Now I'm asking how to save, at least, the username and password once it was authenticated over LDAP. Any help? Cheers Ing. Reynier Pérez Mira Dirección Técnica IP

[symfony-users] Re: Inserting new users into sfGuard tables

2009-05-07 Thread Jonathan Wage
I've done integration with ldap or similar systems before and I always integrated my model directly with the central auth server. So that anytime the model changes, the same changes are made there. You can do this by utilizing the postSave() events, etc. - Jon On Thu, May 7, 2009 at 12:36 PM,

[symfony-users] Re: Inserting new users into sfGuard tables

2009-05-07 Thread Reynier Perez Mira
I've done integration with ldap or similar systems before and I always integrated my model directly with the central auth server. So that anytime the model changes, the same changes are made there. You can do this by utilizing the postSave() events, etc. Can you send me an example? Just

[symfony-users] SfDoctrineGuardPlugin -PluginsfGuardUser : hasPermission($name) method

2009-05-07 Thread BenjaM1
Hy, I may have found a bug in the sfDoctrineGuardPlugin. I tried to know if my user had permissions to do something so I used $sf_user-getGuardUser()-hasPermission('name_of_permission') in my view but it does not return me true. So I looked for why and I found that the hasPermission($name)

[symfony-users] Syntax for embedded forms

2009-05-07 Thread Steve the Canuck
I have embedded one form in another. What's the syntax for accessing the field? For example, I have ConsumerForm embedded in UserForm. The consumer has a first_name field. I've tried: first_name consumer_first_name consumer[first_name] in my templates, but none of them work. Thanks for

[symfony-users] Re: Syntax for embedded forms

2009-05-07 Thread Reynier Perez Mira
main_form['sub_form']['field_to_show'] Best Ing. Reynier Pérez Mira Dirección Técnica IP -Original Message- From: symfony-users@googlegroups.com [mailto:symfony-us...@googlegroups.com] On Behalf Of Steve the Canuck Sent: Thursday, May 07, 2009 5:13 PM To: symfony users Subject:

[symfony-users] Re: Security doubts on sfDoctrineGuardPlugin

2009-05-07 Thread Gary Rojas
Thanks for your answer Ken, but the signin action uses sfGuardValidatorUser which pass the user object through it. Here is the 'doClean' method which call 'findOneByUsername' and not 'retrieveByUsername' and the user's status is never checked . //plugins/sfDoctrineGuardPlugin\lib/validator/

[symfony-users] Re: Fatal error: Class 'BasesfGuardGroupFormFilter' not found

2009-05-07 Thread Josh Steiner
Ok, I was sleepy when I wrote this ;) I have been using: symfony propel:build-all-diff which I had mistaken assumed runs all the same sub tasks as symfony propel:build-all but it looks like the diff version (from sfPropelSqlDiffPlugin) only runs: ./symfony propel:insert-sql-diff

[symfony-users] Avoiding the regular Symfony 1.2 dispatch() call

2009-05-07 Thread Calvin
Hi all, I'm after some response on this thread http://groups.google.com/group/ symfony-users/browse_thread/thread/c3e5b04fd58a3497/2e282615e3990f16? #2e282615e3990f16. Does anyone have any ideas to do this? Thanks in advance, Calvin --~--~-~--~~~---~--~~ You

[symfony-users] Re: Avoiding the regular Symfony 1.2 dispatch() call

2009-05-07 Thread alvaro
In symfony 1.0 you can do sfContext::getInstance()-getController()- dispatch('somemodule', 'someaction'); We use that in production with no problems... I guess you can do the same in 1.2 without problems. On May 8, 2009, at 1:31 PM, Calvin wrote: Hi all, I'm after some response on this