Re: [symfony-users] Re: Any chance of creating a new Google group for Symfony2 only?

2011-06-21 Thread Stéphane Guidoin
I agree with this proposition. I'm new on the mailing list, I use sf1.4
because some specific plugins do not exist on sf2 for now... but my mailbox
is completely overwhelmed by emails irrelevant for me.

I guess a number of people will continue to use sf1 until sf2 is stable and
presents the same level of plugins (or at least to migration their existing
production) and for those people it will be useful to have there mails not
lost in the middle of the sf2 question.

Steph

2011/6/21 Fabien Potencier fabien.potenc...@symfony-project.com

 On 6/10/11 2:32 PM, Georg wrote:

 Hello,

 I am not yet using sf2.

 I am quite frustrated with the mailing list ATM.

 I used to read the mailing list along to help people when I knew
 something, learned a few tricks from answers by others, and had a place
 to get quick answers.

 Now on most mails I don't even understand the subject, I don't bother to
 find the mails where I could help, and i don't ask anymore, because
 obviously most sf1 users act in the same way as I do.
 Check how many sf1 questions were asked and answered 5 moth ago and now.
 This could either mean that nobody is using sf1 any more (which I doubt)
 or the list is not working for sf1 people any more (which is the case
 IMO).

 [RANT]I wonder what are the things that are shared between symfony 1 and
 symfony 2? That both are a PHP MVC framework and have the same name?
 TO me this feels like if I had a single mailing list for Drupal and
 Typo3, because both are PHP CMS[/RANT]


 Yes and no. They share the same philosophy but the implementation details
 are different. The web evolves very fast and so the framework should also
 evolve.

  [RANT2]Check 
 http://www.symfony-project.**org/installationhttp://www.symfony-project.org/installation
 :
 sf1.4 is the only stable symfony version ATM, and is supported until
 november 2012. I strongly hope (even if I have a different feeling),
 that at least until mid 2012, sf1 is not treated as legacy. There isn't
 even an update possible, I am afraid that companies will rethink their
 decision to develop in symfony if they are left standing in the rain.


 symfony1 is very stable and the few pain points are not really fixable
 without badly breaking BC. I review all the tickets and I've done some bug
 fixes in the last few weeks on symfony 1.4. But frankly, there is not a lot
 to do. Anyway, we are about to release a new version of symfony 1.4
 including these minor fixes.

  (Yes, I know this mail
 http://groups.google.com/**group/symfony-devs/msg/**f13ab956a61567cchttp://groups.google.com/group/symfony-devs/msg/f13ab956a61567ccby
 fabien, let me quote:
 [QUOTE]Keep in mind that symfony is an Open-Source project, so everybody
 can contribute and scratch its itch. The core developers and all plugin
 developers are all working for free. Of course, Sensio sponsors the
 framework, of course it dedicates a lot of time and money to it, and of
 it can even provide extended support for all versions for companies
 willing to pay. And do you know how many companies, except Sensio
 customers, signed up for extended support in the last 2 years? None!
 Yep, that's right, not a single one. [/QUOTE]
 [/RANT2]

 That's why I would like to have symfony-users and syomfony2-users as
 opposed to symfony-legacy-users.

 As always, keep up the great work. And I will switch to sf2, when it is
 stable (and probably has 1 as minor version number ;-) or when the
 *symfony2-users* list doesn't complain too much). But I will be stuck
 with sf1 for quite a long time with existing projects. And as pointed
 out above, I don't feel they have a lot together.


 I've been thinking about this mailing-list issue a lot during the last few
 months and I'm still convinced that creating more mailing-lists is not the
 right solution. Anyway, as many people think the contrary, here is what I
 propose now:

 We create two new mailing-lists: one for symfony1 and one for Symfony2. To
 be clear, this mailing-list (symfony-users) will die. That way, there is no
 legacy mailing-list, all symfony users will be treated the same way: they
 will have to do something about their subscription.

 If everybody agree, I will start the migration and send invitations for all
 current subscribers.

 Cheers,
 Fabien

  Regards
 Georg

 Am 10.06.2011 07:24, schrieb Fabien Potencier:

 On 6/9/11 10:17 PM, Chris Sedlmayr wrote:

 Hi all,

 I don't think we are against the idea of creating a Symfony2 specific
 group, but we must ensure that finding help in the right place is the
 main priority.


 I'm against creating a Symfony2 specific group. If we were to create a
 new group, then it would be a symfony-legacy group. Do we want to create
 a ghetto?

 Fabien

  Also, it's worth noting that there is significant time involved with
 moderating this group alone, which I am not complaining about as it
 means we have an incredibly active community of developers and users
 which is fantastic!

 I'll bring it up and we can go from 

[symfony-users] Symfony 1.4 - Management of a blob (or PostGIS) field with doctrine

2011-06-20 Thread Stéphane Guidoin
Hello there, 

I'm quite new with symfony and I'm trying to make it work with PostGIS  thru 
doctrine. I installed sfMapFishPlugin but my problem seems to be as basic as 
managing a blob/bytea field. 

So by considering only the blob question, here is my problem : 
- I design a table with a blob that looks like this in schema.yml 

MyTable: 
  actAs: { Timestampable: ~ } 
  columns: 
category_id:  { type: integer, notnull: true } 
my_blob: { type: blob() } 

Then I auto-generate the module based on my table. I'm able to access the 
index and to create a new record, the record is correctly inserted in the 
DB, in pgdamin my blob field is correctly displayed (some simple ascii 
content for the moment). 

But when I try to read the content of my record thru Symfony (for example in 
the show/id auto-generated page), everything is displayed excepted my blob 
field which is empty. Looking on the internet I found stuff mentionning to 
use stream_get_content or pg_unescape_bytea but nothing works. 

Did someone ever managed to get some content out of a blob. 

Or did someone already used (successfully) sfMapFishPlugin to manipulate 
some PostGIS data. 

Thanks 

Steph 

-- 
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] Symfony 1.4 - Management of a blob or postGis field with doctrine

2011-06-20 Thread Stéphane Guidoin

Hello,

I'm quite new with symfony and I'm trying to make it work with PostGIS  
thru doctrine. I installed sfMapFishPlugin but my problem seems to be as 
basic as managing a blob/bytea field.


So by considering only the blob question, here is my problem :
- I design a table with a blob that looks like this in schema.yml

MyTable:
  actAs: { Timestampable: ~ }
  columns:
category_id:  { type: integer, notnull: true }
my_blob: { type: blob() }

Then I auto-generate the module based on my table. I'm able to access 
the index and to create a new record, the record is correctly inserted 
in the DB, in pgdamin my blob field is correctly displayed (some simple 
ascii content for the moment).


But when I try to read the content of my record thru Symfony (for 
example in the show/id auto-generated page), everything is displayed 
excepted my blob field which is empty. Looking on the internet I found 
stuff mentionning to use stream_get_content or pg_unescape_bytea but 
nothing works.


Did someone ever managed to get some content out of a blob.

Or did someone already used (successfully) sfMapFishPlugin to manipulate 
some PostGIS data.


Thanks

Steph

--
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


Re: [symfony-users] Blog plugin for symfony1.4

2011-06-17 Thread Stéphane
Hello,

With Apostrophe there is a blog plugin.

www.apostrophe-now.com

But  you might need to use Apostrophe to use the plugin.

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, Jun 18, 2011 at 7:41 AM, Imran im...@allies.co.in wrote:

 Hi devs,


 Is there any plugin exists for blog integration in symfony 1.4
 application?

 I found a plugin sfSimpleBlogPlugin, but it works with Propel with
 symfony 1.1.


 -Imran

 --
 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


Re: [symfony-users] [sf1.4] execute action post plugin action

2011-06-11 Thread Stéphane
Hello,

You can overload plugin actions !

http://dasher.wordpress.com/2009/05/15/symfony-overloading-and-overriding-plugins-base-classes/


Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Jun 9, 2011 at 9:16 AM, Christian hoff...@thesisdigital.de wrote:

 Hi,

 what is best practise to execute a action after a plugin action is
 executed?

 I have several applications and one special application have to
 execute a action after a plugin action is executed. How could i do
 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


-- 
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] [Symfony 2] Bundles, large models, Front Back splitting

2011-04-27 Thread Stéphane
Hello Community,

When considering writting large apps with sf2, with a back and a
front, some questions are occuring, about how to structure things.

Say we have one large website with a front-end for end-users and a
back-end to feed the front-end, control objects, etc.

The two apps will use same models, obviously.

We'd like to separate our views on the models for the two apps (I
call them perspectives).

Let say we have a model named Topic.
On BackOffice, we'd like to speak about Topics using a TopicBO class,
which will only have methods for backoffice problem solving.
Same on FrontOffice, we'd speak to TopicFO instance.
Let say TopicBO and TopicFO are two perspective objects for the Topic object.

There are two problematics :

How to structure the bundles, when we have more than 100 entities,
when they have to be used between the two apps
How to have such distincts *FO and *BO classes ? Inheritance or
compositing(-wrapper) ?



About question 1.:

I'll try to dig somehow.
Let say we have Customer, Topic  Space (a forum space) models.

First try :
One bundle for Core (the model in itself, with methods that
could be used by both FO and BO)
One bundle for FO
One bundle for BO

Leading us to having

CustomerCoreBundle : class, metadata mapping
CustomerFrontBundle : actions, templates, resources, wrapper for Front
CustomerBackBundle : actions, templates, resources, wrapper for Back
TopicCoreBundle : class, metadata mapping
TopicFrontBundle : actions, templates, resources, wrapper for Front
TopicBackBundle : actions, templates, resources, wrapper for Back
SpaceCoreBundle : class, metadata mapping
SpaceFrontBundle : actions, templates, resources, wrapper for Front
SpaceBackBundle : actions, templates, resources, wrapper for Back


This is great when we have many different actions, resources,
templates to bundle within one of these bundles for specific app.
Yet I'm pretty sure we can have one bundle for each object, and create
directories within the bundle to have a separation between front 
back stuffs.

Not talking about dependencies here (how the hell hard would it be ?
If it even would be hard to manage ?)
We'd get a FrontBundle which would require somehow (is it even
possible) all bundles for the Front, and same thing for the Back.

Second
One bundle rule them all (bundling core model, metadata, FO
 BO inheritance/compositing objects, resources, actions, etc)

CustomerBundle : class, metadata, actions, templates, resources,
wrapper for Front  Back
TopicBundle : class, metadata, actions, templates, resources, wrapper
for Front  Back
SpaceBundle : class, metadata, actions, templates, resources, wrapper
for Front  Back

How easy would it be to have a separation (with the mean of
directory structure I guess) between Front  Back stuff ?

I guess here dependencies are a lot easier to manage



About question 2.:

The goal is to have a class with methods specific to the application
at hand. So it is easier to write and maintain (I guess).
*FO classes will have methods only used for Front app.
*BO classes will have methods only used for Back app.


Would we go by inheriting or by wrapping them ?

Inheritance:

Class BaseCustomer
Class CustomerFO extends BaseCustomer
Class CustomerBO extends BaseCustomer

(I don't go using aliases and namespaces here, KISS for the example)
When methods are needed on both side, put them in BaseCustomer

Compositing:


Class Customer
Class CustomerFO which wraps a Customer instance
Class Customer BO which wraps a Customer instance

When methods are needed on both side, we create proxy methods on both
wrappers  implement them in the Customer (no __call() + docblocks)

By writting it down, I see it's easier to inherit. Anyway, what are
your feelings/experiences about such problem ?


Thank you for reading and your time !

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!

-- 
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


Re: [symfony-users] MyUser extend sfUser class

2011-03-14 Thread Stéphane
Hello,

First, please use the _dev.php controllers to get beautifull exception stack
traces ;)
Second, clear-cache ?
Third, check you have put the MyUser.class.php in the lib/ directory of your
project.
Fourth, you can rename your userIsAuthentic() to -isAuthentic as you're
talking to a $sf_user (instanceof MyUser) so it's a user ;)

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Mar 14, 2011 at 2:54 PM, Cornelius Parkin 
cornelius.par...@gmail.com wrote:

 Hi

 I wrote a class called MyUser which extends the sfUser class in order
 to add some functionality. I then added the following in the
 factories.yml file in order for Symfony to use MyUser instead of
 sfUser.

 user:
class: MyUser

 This is what I could pick up from the web. However, when I try to call
 a function which I added in the MyUser class
 [$sf_user-userIsAuthentic()] I get an error [The server returned a
 500 Internal Server Error.]. It seems like the MyUser class is not
 picked up nor the functions defined in it.

 Can someone please point me in the right direction?

 Thanks in advance...

 --
 Warm Regards

 C.A.Parkin

 ~When you innovate, you've got to be prepared for everyone telling
 you you're nuts - Larry Ellison~

 --
 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


Re: [symfony-users] Passing a variable between new and edit actions in Symfony 1.4 + Doctrine

2011-03-13 Thread Stéphane
Hello,

Look at the contructor of form, you can pass an $options array.
Play with this array to pass along values from $request instead of using
sfContext::getInstance()-...
Then you'll be able to $this-getOption('id_parent', false) within your
-configure() method.

You can also play with user attributes (which are session'ed) to
store/retrieve information from new to create.
Or just adding an hidden input to store the parent id in your form directly.

Hope I've understood your needs well, too ;)

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sun, Mar 13, 2011 at 3:14 PM, Illya Klymov illya.kly...@gmail.comwrote:

 In my project i have a Product class, which acts as Nested Tree.
 Additionally each Product has set of Features (one-to-many relation).
 I have the following limitation - each subProduct can't use features,
 which are not used in it's parent Product.
 So, in order to generate a correct list of Features, available for new
 Product,  I'm passing a variable to executeNew action (now using GET
 parameter), which states id of parent, from which i'm deriving a new
 product. Of course, when POST'ed form arrives, there is no such
 variable in request, so in order to generate in executeCreate action
 the same selection i need to dig through POST'ed form. In other way
 now I have the following hack in my configure method of form to
 retrieve id_parent:

 $sfRequest = sfContext::getInstance()-getRequest();

 if ($productArray = $sfRequest-getParameter('product')) {
$idParent = $productArray['id_parent'];
 } else {
$idParent = $sfRequest-getParameter('id_parent');
 }

 Is there a better way 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


-- 
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


Re: [symfony-users] Passing a variable between new and edit actions in Symfony 1.4 + Doctrine

2011-03-13 Thread Stéphane
$sfRequest = sfContext::getInstance()-getRequest();

if ($productArray = $sfRequest-getParameter('product')) {
   $idParent = $productArray['id_parent'];
} else {
   $idParent = $sfRequest-getParameter('id_parent');
}

Is there a better way to solve this problem?

This is bad because your form shouldn't be using sfContext::getINstance().
You should use $options. IMHO.

So yes there is a better way : using options. Deport this code from your
$form-configure() to your action controller, and inject the $idParent
using form $options constructor.
This way you'll be able to do $idParent = $this-getOption('id_parent');

So the form will not have the knowledge of where to take the info from
(from GET or from POST ?), because it will be the role of the action to take
care of this.

You say you have to dig in the POST'ed params to get the product_id. So,
basically, you have the information. Where's the problem ?
Perhaps you want to make things clear ? Like, in executeNew()' form, adding
a derived_product_id hidden widget which contains the ID given by the GET,
so you'll get it in the POST too, in the executeCreate()' form ?


Regards,




Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sun, Mar 13, 2011 at 3:49 PM, Illya Klymov illya.kly...@gmail.comwrote:

 I've played with options - but it seems no difference for me - if i set an
 option for form in executeNew handler, it's not passed to form when
 executeCreate is running. And how could I add an input, which would not be
 affected by my setNameForm of widgetSchema. That mean's i would to like to
 have all product-related fields in POST still in product array, and separate
 field for id_product

 --
 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


Re: [symfony-users] Protect development credentials when deploying application

2011-03-01 Thread Stéphane
There are none bundled with sf1.4.

Anyway it's not that hard to code a task to remove every dev: in .yml files
and dump content in .yml.dist or .prod.
Needs to wrap this into a release process.

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Mar 1, 2011 at 9:28 PM, Alex Pilon alex.pi...@gmail.com wrote:

 Hello,

 Is there a way (sf1.4) to only publish production settings (e.g., in
 databases.yml, app.yml, or settings.yml) when you deploy a symfony
 application?

 Thanks

 --
 Alex Pilon
 (613) 608-1480

 --
 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


Re: [symfony-users] Protect development credentials when deploying application

2011-03-01 Thread Stéphane
I mean for now, on sf1.4, there are no way to take away these settings.

Even for dev, it's bad to have the prod: settings for database.
Developers are not meant to be seen as wrong people, but it can be.

On sf2, .yml files are splitted into config_dev.yml, etc.

I mean you could create a task such as ./symfony remove:env dev
This talk will remove every dev: entries in the yaml files.

I would copy/paste my root project before running this task (which is why
I'm talking about a process, why not including this copy/paste process
within the remove:env task, which is a dummy name, just to name it here).

About the .dist or .prod, it's just a way to go, but I would prefer going
the way I've just said on top.

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Mar 1, 2011 at 10:33 PM, Alex Pilon alex.pi...@gmail.com wrote:

 What do you mean there are none bundled with sf1.4?

 I mean in databases.yml for example, when you have

 dev:
   connection:
  # settings
 prod:
   connection:
 # settings

 A common security problem is credentials getting in the hands of the wrong
 person. So in effort to remove unneeded credentials when deploying an
 application, you are saying that creating a task to remove any non prod
 settings is the way to go?

 What do you mean by dumping content in .yml.dist or .prod. ? Could you
 elaborate on this?

 Thanks

 On Tue, Mar 1, 2011 at 15:57, Stéphane stephane.er...@gmail.com wrote:

 There are none bundled with sf1.4.

 Anyway it's not that hard to code a task to remove every dev: in .yml
 files and dump content in .yml.dist or .prod.
 Needs to wrap this into a release process.

 Regards,


 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


 On Tue, Mar 1, 2011 at 9:28 PM, Alex Pilon alex.pi...@gmail.com wrote:

 Hello,

 Is there a way (sf1.4) to only publish production settings (e.g., in
 databases.yml, app.yml, or settings.yml) when you deploy a symfony
 application?

 Thanks

 --
 Alex Pilon
 (613) 608-1480

 --
 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




 --
 Alex Pilon
 (613) 608-1480

 --
 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


Re: [symfony-users] Form widgets

2011-02-23 Thread Stéphane
sf cc ?


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Feb 24, 2011 at 1:20 AM, Parijat Kalia kaliapari...@gmail.comwrote:

 Hi guys,

 I am following the Symfony form's tutorials and have reached upto listing
 1-2 on http://www.symfony-project.org/forms/1_1/en/01-Form-Creation
 I have executed all steps up until listing 1-2 but while i attempt to run
 the webpage, it reads the following error:
 *
 *
 *Fatal error*: Class 'RegisterForm' not found in *
 C:\dev\sfproject\apps\frontend\modules\questions\actions\actions.class.php
 * on line *1623*
 *
 *
 Not sure why this is happening because I do have a RegisterForm.class.php
 file in my //lib/form folder (I am talking the lib folder for the entire
 project and not the local module lib folder, P.S: I have also carried out
 the same experiment with the module lib folder, only to get similar
 results).

 Anybody with any leads on what I am missing out here?

 Thanks!

 Parijat Kalia

 --
 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


Re: [symfony-users] UniversalClassLoader.php Missing or in the Wrong Place?

2011-02-21 Thread Stéphane
The autoload file in symfony dir is alright on my git repo.

--
I know you might try to understand how Sf2 is working, by making everything
by hand.

Anyway, if you don't know, and willing some help, there is a symfony project
bootstrapper up to date here https://github.com/Garfield-fr/Symfony2Project

It is not perfect, but it is working and up to date.
Even if there are rooms for improvements.

https://github.com/Garfield-fr/Symfony2ProjectRegards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Feb 21, 2011 at 11:52 PM, taidehuone taidehu...@gmail.com wrote:

 I recently moved my own project to a new Ubuntu 10.10 laptop environment
 and I also initialized a new symfony 2.0 project from scratch. I noticed the
 same thing you're facing. For some reason the symfony2 bootstrapper
 initializes an outdated file structure for you. The UniversalClassLoader for
 example used to reside in that namespace but obviously a lot has changed
 since then. I don't know why or how this happens and to be honest I wasn't
 too interested to know. It appears that the files in the bootstrapper's
 skeleton are correct but the .phar file you use for initializing the project
 does everything wrong it possibly can.

 I only got the project installed because I'm already familiar with the
 symfony2 file structure. I copied over the files from the bootstrapper's
 skeleton folder, renamed placeholder variables within the files and renamed
 some of the files themselves. You may want to explore the sandbox file
 structure and copy the bootstrapper files accordingly. There weren't too
 many things to rename but I can't remember which and where.

 At first I thought it was just me doing it wrong because it felt like a too
 big thing to be a bug, but somebody may want to fix this now or at least
 shed some light on 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


Re: [symfony-users] Re: query error

2011-02-19 Thread Stéphane
$query-fetchOne() will return only one user.

But Damon is right, the beginning of the code looks bad.

Regards

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, Feb 19, 2011 at 3:46 PM, Damon Jones damonljo...@gmail.com wrote:

 In your first statement you are creating and executing a query using
 the ActivationTable class to retrieve a Doctrine Collection and assign
 it to $value.

 In your second statement, you are overwriting $value with a new
 FriendlynationActivation object.

 Firstly, why are you overwriting $value before you have done anything
 with the results?

 Secondly, are the class names correct? Is is Activation or
 FriendlynationActivation?

 Now that you have a new FriendlynationActivation object, it's likely
 that $mail is going to be null (unless you have a default email
 property in that class).

 You then use that $mail variable as part of your query on the
 UserTable (which will probably not find any matching rows).

 When you do $user-execute() you are probably getting an empty
 Doctrine Collection. Even if the query found some Users, you would get
 a Doctrine Collection back rather than a User, so you'd need to assign
 $user from there:

 $users = $query-execute();
 $user = $users[0]; // to get the first one returned

 Hope this helps.

 On Feb 18, 7:42 pm, Laxmi laxmipsa...@gmail.com wrote:
  $value = Doctrine_Core::getTable('Activation')
  -createQuery('a')
 -where('a.temp = ?',$string)
  -execute();
 $value = new FriendlynationActivation();
 
 $mail = $value-getEmail();
 
 $query = Doctrine_Core::getTable('User')
  -createQuery('a')
  -where('a.email = ?',$email);
 $user = $query-execute();
$user-set('password',$newpassword);
 $user-save();
 
  I am getting error No description for object of class Activation ,
  when i am trying to retrive email from database and also please
  suggest me how the update query works in symfony

 --
 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] I18nizing a Relation

2011-02-12 Thread Stéphane
Hello,

Using sf1.4  doctrine 1.2.

Is it possible to I18nize a relation ?

I see bug in doctrine code when I try to do so. I have tried to debug it,
but can't remember which class is involved in Doctrine code.
I'll retry to debug it to provide more informations, if none see where shi**
happens :)

For example :

Post:
  actAs:
I18n:
  fields: [ image ]
  columns:
image:{ type: integer }
  relations:
Image:
  class:  DmMedia
  local:  image
  onDelete:   SET NULL


Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!

-- 
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


Re: [symfony-users] Re: Is it possible to check the filesize of an image *before* uploading it ?

2011-02-11 Thread Stéphane
Using File API for HTML 5 it's possible. But it needs File API enabled
browser (FF 4 for example).
Using JS of course.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Feb 11, 2011 at 4:07 PM, Gabriel Petchesi pghora...@gmail.comwrote:

 Look into flash (sfWidgetFormInputSWFUploadPlugin) or java applet
 uploaders.
 Those are capable of checking the size, I don't think it's technically
 possible using stock browser file upload.

gabriel

 --
 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


Re: [symfony-users] Re: How to let my users edit their password/profile ? [sfDoctrineGuardPlugin]

2011-02-07 Thread Stéphane
This plugin have modules to edit user permissions and groups, no ?

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Feb 7, 2011 at 11:51 AM, Manu emmanuel.parf...@gmail.com wrote:

 I checked out the plugin, it seems a little complicated; the edit user
 page sends an email using Zend mail...

 How come editing your profile isn't a part of sfDoctrineGuardPlugin ?
 Surely I cannot be the first one to want that functionality on their
 website !

 --
 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


Re: [symfony-users] Any way to rename actions.class.php

2011-02-07 Thread Stéphane
I don't get it.
What is the problem ?
Do you know you can break your actions methods into individual classes ? Is
it this ?

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Feb 7, 2011 at 5:53 PM, George M. Harkin
montana.har...@gmail.comwrote:

 When editing our module's actions.php i run into the issue of a 20
 actions.class.php files.

 Is it possible to rename it to module_name.actions.class.php or
 something else?  This a feature request?

 Thanks!

 --
 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


Re: [symfony-users] Any way to rename actions.class.php

2011-02-07 Thread Stéphane
Ah, thank you :)

On Eclipse, I'm using to Ctrl+Shift+T for Type, then typing the name of the
file. Keeping hands on the keyboard, or playing with Ctrl+PageUp or Down to
navigate between open editors (I'm on ubuntu, dunno behavior on other OSes).

Anyway, how to change this ?
Look at the sfController-controllerExists() method :)

Regards,

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Feb 7, 2011 at 10:27 PM, Alex Pilon alex.pi...@gmail.com wrote:

 I think he means.. he has say 10 modules each with an actions.class.php.
 When these are all open in an editor, the file name shows actions.class.php,
 and so it becomes confusing what file you are editing and you have to click
 like 5 tabs to find the actions file you are looking for. So applying some
 sort of naming convention to them that indicates what file they come from
 would be nice.. im sure there is a way to do it.

 I'll look when I get home and see if i can find a way to do it.

 On Mon, Feb 7, 2011 at 16:04, Stéphane stephane.er...@gmail.com wrote:

 I don't get it.
 What is the problem ?
 Do you know you can break your actions methods into individual classes ?
 Is it this ?

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



 On Mon, Feb 7, 2011 at 5:53 PM, George M. Harkin 
 montana.har...@gmail.com wrote:

 When editing our module's actions.php i run into the issue of a 20
 actions.class.php files.

 Is it possible to rename it to module_name.actions.class.php or
 something else?  This a feature request?

 Thanks!

 --
 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




 --
 Alex Pilon
 (613) 608-1480

 --
 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


Re: [symfony-users] Re: Localization of flash warning

2011-02-05 Thread Stéphane
Simply overload the template that echoes the flashes, and add a __() around,
no ?

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, Feb 5, 2011 at 11:50 AM, Gabriel Petchesi pghora...@gmail.comwrote:

 You can do it either in:
 1. Action

 http://www.symfony-project.org/gentle-introduction/1_4/en/13-I18n-and-L10n#chapter_13_sub_calling_the_translation_helper_outside_a_template
 http://www.symfony-project.org/gentle-introduction/1_4/en/13-I18n-and-L10n#chapter_13_sub_calling_the_translation_helper_outside_a_template2.
 Template
 echo __($sf_user-getFlash('error'))

 I think that the second option is recommended.

 gabriel


 On Friday, February 4, 2011 3:55:14 PM UTC+2, ricvec wrote:

 Hello everybody,
 the subject of this topic is quite clear; I'd like to know how can I
 localized the flash warnings/errors or some workaround to do it.
 In my example I have this lines in the class actions.class.php for the
 user model:

 $q = Doctrine_Query::create()
 -from('WeeventUser wu')
 -where('wu.username = ?', $request-getParameter('username'))
 -andWhere('wu.password = ?', $request-getParameter('password'));


   $weevent_users = $q-execute();

 if (count($weevent_users)==1)
   $this-redirect('user/show?id='.$weevent_users[0]-getId());
 else{
   $this-getUser()-setFlash('error', __('Username or password are
 wrong'));
   $this-redirect('user/login');
 }

 Thank you very much

 Riccardo

  --
 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


Re: [symfony-users] detect the right object

2011-01-29 Thread Stéphane
foreach ($hotels as $hotel) {
   if ($hotel*-getRawValue()* instanceof BookingComHotelsPromoteCountry)


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, Jan 29, 2011 at 5:08 PM, Sela tzi...@gmail.com wrote:

 I use the symofny and iterating object i have this problem when
 running the following code


 foreach ($hotels as $hotel) {
if ($hotel instanceof BookingComHotelsPromoteCountry)

 $hotel itself is wrapped by symfony so only inside the value is
 actually the BookingComHotelsPromoteCountry, what is the syntax i need
 to use?

 --
 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


Re: [symfony-users] Re: Introducing Vespolina - the new sf2 based e-commerce platform

2011-01-27 Thread Stéphane
Hello,

Good to see that !

Have you already thought about how you will modelize the product breakdown ?

I have started some times ago a dmCommercePlugin which is far far away from
a finished plugin, but it's starting idea, for now is to let accredited
users define product types, their characteristics, and so on, via backend
dedicated interface.

What about this ? I don't know about about Magento, but is it something you
guys wish to see in vespolina (nice name btw) ?

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Jan 27, 2011 at 6:50 PM, apm korja...@gmail.com wrote:

 Sure, share, its interesting.

 On 26 янв, 22:56, Justen Doherty phpc...@gmail.com wrote:
  I've made a start on a personal ecommerce project in symfony 1.4 - at the
  moment its just got categories/subcategories with a photo library in the
  backend.. but i've been coding this in my spare time at home, if anyone
 is
  interested i can make the code available via github :)
 

 --
 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


Re: [symfony-users] Re: memcached ubuntu php doubt

2011-01-26 Thread Stéphane
php -i | grep memcache

in a terminal

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Jan 26, 2011 at 9:19 PM, Christian alice...@googlemail.com wrote:

 the php cli has it own ini file. check memcache is activated in there

 On Jan 26, 6:35 am, Shihab KB shiha...@gmail.com wrote:
  I managed to install memcached and its extension (memcache) in ubuntu
  and caching is working fine. For the installation I followed the
 sitehttp://stevelove.org/2009/09/30/how-to-install-php-memcached-on-an-ub.
 ..
 
  After installation my following code is working fine.
 
  [syntax=php]?php
  error_reporting(-1);
  ini_set('display_errors', true);
  $memcache = new Memcache();
  //$memcache-connect(10.1.11.33,11211) or die (Could not
  connect);
  $memcache-addServer(10.1.11.33,11211, 33);
  echo version =  . print_r($memcache-getVersion());
 
  if ( ! extension_loaded('memcache')) {
  throw new Doctrine_Cache_Exception('In order to use
  Memcache driver, the memcache extension must be loaded.');
  }
  ?[/syntax]
 
  And from symfony I used resultcaching. It is also working. I verified
  by modifying the content in the database and the modified content is
  not loading in the result. But after the life span the changed content
  is loading.
 
  Here is the code snippet which I used to load the cache driver in the
  symfony framwork.
 
   [syntax=php]   public function configureDoctrine(Doctrine_Manager
  $manager) {
  $servers = array(
  'host' = '10.1.11.33',
  'port' = 11211,
  'persistent' = true
  );
  $cacheDriver = new Doctrine_Cache_Memcache(array(
  'servers' = $servers,
  'compression' = false
  )
  );
  //enable Doctrine cache
  $manager = Doctrine_Manager::getInstance();
  $manager-setAttribute(Doctrine::ATTR_RESULT_CACHE,
  $cacheDriver);
  $manager-setAttribute(Doctrine::ATTR_RESULT_CACHE_LIFESPAN,
  900);
  }[/syntax]
 
  But I have one more issue. When I tried to clear the cache it is
  giving me the an error [quote]In order to use Memcache driver, the
  memcache extension must be loaded.[/quote]
 
  But in the sample code this error is not returning.
 
  Do u have any solutions for this?
 
  regards
  Shihab

 --
 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


Re: [symfony-users] Re: Many to many relationship: complete iteration.

2011-01-17 Thread Stéphane
$user-getGroups() or such ? (I don't know propel)

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jan 17, 2011 at 11:25 PM, Javier Garcia tirengar...@gmail.comwrote:

 I used a join and I get the objects from the exchange table, so if I
 iterate it I get:

 user1-group2
 user1-group5
 user2-group1
 user2-group3
 user2-group4

 But I'm wondering how could i get the group objects from the user
 objects...


 On Jan 17, 11:04 pm, Javier Garcia tirengar...@gmail.com wrote:
  Hi,
 
  I have a many-to-many relationship between two tables.
 
  I would like to show the elements of a table with the corresponding
  elements of the other table.
 
  For example:
 
  user1-group2
 group5
  user2-group1
 group3
 group4
  ...
 
  In an easy and smart way, of course.
 
  sf 1.4/propel 1.4.
 
  Any advice or tutorial?
 
  Javi

 --
 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


Re: [symfony-users] Content-type negotiation

2011-01-12 Thread Stéphane
In routes.yml, you can define the :sf_format and set its default value I
guess.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Jan 12, 2011 at 2:41 PM, Renoir Boulanger r...@evocatio.com wrote:

 This response is based upon my own memory. It's been a while since I read
 how to do it.

 Content type negociation are set in configuration file (view.yml,
 settings.yml?) and can be specified in actions.

 Not to forget that you can also use format specific templates e.g.:
 modules/potato/templates/clients.json.php

 I cant' recall where I've seen this more in detail

 hope it helps


 RENOIR BOULANGER //

 devLABmtl.org/
 ConFoo.ca/
 evocatio.com/

 (envoyé de mon téléphone)
 ~


 On 2011-01-11, at 16:15, paulkmoore paulkmo...@gmail.com wrote:

  Hi all

 I'm new to Symfony and tried posting this in the forum, but I'm not
 convinced that audience is correct.

 I am building a REST API for our application, and have been looking at
 the sfDoctrineRestGeneratorPlugin which looks very promising (and
 extensible - thanks). However, the library does not appear to provide
 Content-Type negotiation, which I'd like to use to establish the
 response format rather than using an extension (.xml, .yaml etc) based
 approach.

 Investigating further I am unable to find any content-type negotiation
 capabilities in Symfony, and am therefore wondering if:

 i) I've just missed it - please let me know (Note: I've also searched
 the plug-ins without success)
 ii) They're isn't any and people build this capability as required
 (I've previously used the PECL_Http http_negotiate_content_type
 http://uk3.php.net/manual/en/function.http-negotiate-content-type.php
 functionality for this purpose)

 Many thanks

 Paul


 --
 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


Re: [symfony-users] Re: Content-type negotiation

2011-01-12 Thread Stéphane
http://www.symfony-project.org/api/1_0/sfWebRequest#method_getacceptablecontenttypes

http://www.symfony-project.org/api/1_0/sfWebRequest#method_getacceptablecontenttypes
?

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Jan 12, 2011 at 4:51 PM, Dennis gear...@sbcglobal.net wrote:

 As far as real content negotiation as per the HTTP standard,  choosing
 which one out of an offered, prioritized set of ACCEPT: mime types, I
 haven't seen anything done in Symfony on any forum, tutorial, etc.

 There MAY be a native way to to that in Symfony 1, using the config
 files, but I woulldn't be any money on it. It would be  really good
 question for Favian Ponifier(sp).

 To me, if it wasn't native to Symfony, iether one, the obvious place
 to put it would be to extend the Response and its use of the header
 ACCEPT vs template files. Something almost like a routing file seems
 natural,where it falls through from highest to lowest availability,
 but id dynamically ordered.

 So you'd have an array of available output types, their lower
 equivilancies, and then a way that parses the ACEPT header to order
 that array.

 Probably the coolest way to do it would be to have the template files
 have the base type in their extension, and then a mimetype in them.
 You could hve mulitple xml types then, but with specific versions and
 micoformats. Just a thought.

 On Jan 12, 6:28 am, Stéphane stephane.er...@gmail.com wrote:
  In routes.yml, you can define the :sf_format and set its default value I
  guess.
 
  Regards,
 
  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
  On Wed, Jan 12, 2011 at 2:41 PM, Renoir Boulanger r...@evocatio.com
 wrote:
   This response is based upon my own memory. It's been a while since I
 read
   how to do it.
 
   Content type negociation are set in configuration file (view.yml,
   settings.yml?) and can be specified in actions.
 
   Not to forget that you can also use format specific templates e.g.:
   modules/potato/templates/clients.json.php
 
   I cant' recall where I've seen this more in detail
 
   hope it helps
 
   RENOIR BOULANGER //
 
   devLABmtl.org/
   ConFoo.ca/
   evocatio.com/
 
   (envoyé de mon téléphone)
   ~
 
   On 2011-01-11, at 16:15, paulkmoore paulkmo...@gmail.com wrote:
 
Hi all
 
   I'm new to Symfony and tried posting this in the forum, but I'm not
   convinced that audience is correct.
 
   I am building a REST API for our application, and have been looking at
   the sfDoctrineRestGeneratorPlugin which looks very promising (and
   extensible - thanks). However, the library does not appear to provide
   Content-Type negotiation, which I'd like to use to establish the
   response format rather than using an extension (.xml, .yaml etc) based
   approach.
 
   Investigating further I am unable to find any content-type negotiation
   capabilities in Symfony, and am therefore wondering if:
 
   i) I've just missed it - please let me know (Note: I've also searched
   the plug-ins without success)
   ii) They're isn't any and people build this capability as required
   (I've previously used the PECL_Http http_negotiate_content_type
  http://uk3.php.net/manual/en/function.http-negotiate-content-type.php
   functionality for this purpose)
 
   Many thanks
 
   Paul
 
   --
   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


-- 
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

Re: [symfony-users] Re: Content-type negotiation

2011-01-12 Thread Stéphane
I don't know if there is a way to say html first, then xml, then json,
kind of 0.8, 0.5, etc.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Jan 12, 2011 at 4:54 PM, Stéphane stephane.er...@gmail.com wrote:


 http://www.symfony-project.org/api/1_0/sfWebRequest#method_getacceptablecontenttypes


 http://www.symfony-project.org/api/1_0/sfWebRequest#method_getacceptablecontenttypes
 ?

 Regards,

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


 On Wed, Jan 12, 2011 at 4:51 PM, Dennis gear...@sbcglobal.net wrote:

 As far as real content negotiation as per the HTTP standard,  choosing
 which one out of an offered, prioritized set of ACCEPT: mime types, I
 haven't seen anything done in Symfony on any forum, tutorial, etc.

 There MAY be a native way to to that in Symfony 1, using the config
 files, but I woulldn't be any money on it. It would be  really good
 question for Favian Ponifier(sp).

 To me, if it wasn't native to Symfony, iether one, the obvious place
 to put it would be to extend the Response and its use of the header
 ACCEPT vs template files. Something almost like a routing file seems
 natural,where it falls through from highest to lowest availability,
 but id dynamically ordered.

 So you'd have an array of available output types, their lower
 equivilancies, and then a way that parses the ACEPT header to order
 that array.

 Probably the coolest way to do it would be to have the template files
 have the base type in their extension, and then a mimetype in them.
 You could hve mulitple xml types then, but with specific versions and
 micoformats. Just a thought.

 On Jan 12, 6:28 am, Stéphane stephane.er...@gmail.com wrote:
  In routes.yml, you can define the :sf_format and set its default value I
  guess.
 
  Regards,
 
  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
  On Wed, Jan 12, 2011 at 2:41 PM, Renoir Boulanger r...@evocatio.com
 wrote:
   This response is based upon my own memory. It's been a while since I
 read
   how to do it.
 
   Content type negociation are set in configuration file (view.yml,
   settings.yml?) and can be specified in actions.
 
   Not to forget that you can also use format specific templates e.g.:
   modules/potato/templates/clients.json.php
 
   I cant' recall where I've seen this more in detail
 
   hope it helps
 
   RENOIR BOULANGER //
 
   devLABmtl.org/
   ConFoo.ca/
   evocatio.com/
 
   (envoyé de mon téléphone)
   ~
 
   On 2011-01-11, at 16:15, paulkmoore paulkmo...@gmail.com wrote:
 
Hi all
 
   I'm new to Symfony and tried posting this in the forum, but I'm not
   convinced that audience is correct.
 
   I am building a REST API for our application, and have been looking
 at
   the sfDoctrineRestGeneratorPlugin which looks very promising (and
   extensible - thanks). However, the library does not appear to provide
   Content-Type negotiation, which I'd like to use to establish the
   response format rather than using an extension (.xml, .yaml etc)
 based
   approach.
 
   Investigating further I am unable to find any content-type
 negotiation
   capabilities in Symfony, and am therefore wondering if:
 
   i) I've just missed it - please let me know (Note: I've also searched
   the plug-ins without success)
   ii) They're isn't any and people build this capability as required
   (I've previously used the PECL_Http http_negotiate_content_type
  http://uk3.php.net/manual/en/function.http-negotiate-content-type.php
   functionality for this purpose)
 
   Many thanks
 
   Paul
 
   --
   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




-- 
If you want to report a vulnerability issue on symfony, please send it to 
security

Re: [symfony-users] Symfony2 Sandbox git

2011-01-10 Thread Stéphane
Hi,

mkdir myproject  cd myproject #create a directory and enter it
git init #create a new git repo
git submodule add @symfony2git@ lib/vendor/symfony2 #add sf2 as a submodule,
put it in lib/vendor/symfony2
git submodule update --init --recursive #initialize the submodules
recursively

Doesnt it make the job ?

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jan 10, 2011 at 3:26 PM, Donald chekot...@gmail.com wrote:

 Hi,

 I've been experimenting with the zip version of the symfony 2 sandbox
 for a while, and I'd like to start using github for my project. I've
 read up a little on git and am familiar with the basics, plus
 submodules and subtrees.

 I'm trying to determine the best way to proceed when setting up a new
 symfony2 project. With symfony 1, I had used svn:externals to keep the
 symfony framework up-to-date, and with symfony2 I've tried various
 things from subtree merges, to creating the vendors as submodules, to
 even forking the symfony 2 sandbox on github.

 I'm not exactly sure which of these is the most appropriate way to
 setup a new project. They all seem to have their benefits and
 problems. Can anyone with experience in this provide me with some sage
 advice?

 Thanks,

 Donald

 --
 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


Re: [symfony-users] - Symfony 1.4.8 - Problems with a redirect() inside of a try...catch construct in action code

2011-01-10 Thread Stéphane
Hi,

Yes it is a good idea to create your own exception class !

A little link, worth reading, about exceptions
http://ralphschindler.com/2010/09/15/exception-best-practices-in-php-5-3
http://ralphschindler.com/2010/09/15/exception-best-practices-in-php-5-3:)

No there's no symfony way about exceptions, it uses the language features,
as usual.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jan 10, 2011 at 4:18 PM, Gabriel Comeau comeaugabr...@gmail.comwrote:

 Hello all,

 I'm having a problem using a redirect inside of my action code.  The
 problem is that the redirect occurs inside of a try block.  Before it
 happens, there is a method call to an object from my model.  If this
 object is not in the right state when the method is called, it throws
 an exception.

 The action code looks like this:

 try
 {
  $this-purchaseOrder-doPurchase();
  $this-redirect('thanks');
 }
 catch (Exception $e)
 {
  $this-getUser()-setFlash('error', 'Sorry - '.$e-getMessage());
  $this-redirect('homepage');
 }

 If the doPurchase() method actually throws an exception, this code
 works exactly as expected.  The problem when the method completes its
 execution without problem.

 The redirect to the 'thanks' action happens, but the flash error gets
 displayed (only the Sorry -  part).  I figured out that this is
 because a redirect throws an sfStopException, which doesn't have a
 message (hence the $e-getMessage() not printing anything out).

 The solution I am thinking of right now is to create a custom
 exception class for my model so that my catch block can instead be
 something like catch (purchaseOrderException $e) and will ignore the
 stopException.

 Is this the right way to go about it or is there a better solution to
 this problem that I'm not seeing.

 This is my first real symfony project, though I've been working with
 PHP for a while.  If there's a framework-specific way of solving this
 problem, I'd love to know about it.

 Thanks very much,

 Gabriel

 --
 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


Re: [symfony-users] - Symfony 1.4.8 - Problems with a redirect() inside of a try...catch construct in action code

2011-01-10 Thread Stéphane
Your code catch the exception because you ask it to do so by coding a
catch(Exception - here, Exception is the master class of all Exceptions !
sfStopException inherits from this class, so your catch will catch it as
expected :)

Now if you create a myException extends sfException, and you catch
myException,
it will not catch sfStopException exceptions.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jan 10, 2011 at 7:15 PM, Gabriel Comeau comeaugabr...@gmail.comwrote:

 Hi guys,

 Thanks for your responses!

 I've decided I'll create some custom exceptions for my project; it
 does seem like the cleanest solution.

 I am however curious as to why exactly I am seeing the behavior I am
 seeing - maybe someone can shed some light on this.

 The redirect('thanks'); call throws an sfStopException.  Shouldn't
 this stop exception get caught higher up in the stack as the redirect
 gets executed?  Why is my catch block catching it to begin with?  The
 other weird part is that my catch block contains two statements - the
 first adds an error to the user's flash and the second redirects to
 the homepage.  The error gets added but the homepage redirect never
 happens.  Instead I am redirected to my thanks action, and its code
 gets executed as if nothing went wrong, though it contains the flash
 error.

 This seems off to me.  Shouldn't it either complete the entire catch
 block and thus I end up on 'homepage' with a flash error?  Or skip the
 entire catch block altogether and stop this action's execution at
 redirect('thanks') ?

 Thanks,

 Gabriel Comeau

 --
 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


Re: [symfony-users] - Symfony 1.4.8 - Problems with a redirect() inside of a try...catch construct in action code

2011-01-10 Thread Stéphane
The framework should send a response with http header Location:.
It doesn't ?

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jan 10, 2011 at 9:43 PM, Gabriel Comeau comeaugabr...@gmail.comwrote:

 Right, but why does it only execute the first part of the catch block
 and not the redirect inside of it?

 -Gabe

 --
 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


Re: [symfony-users] Re: Debugging symfony application within Eclipse?

2011-01-07 Thread Stéphane
http://www.xdebug.org/ Look at the docs section, well done (and Thanks
Deryck Rethan, creator of xdebug, btw ;)

You welcome :)

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Jan 7, 2011 at 7:27 AM, Eric B ebenza...@gmail.com wrote:

 On Thu, Jan 6, 2011 at 11:27 AM, Stéphane stephane.er...@gmail.comwrote:

 Hello,

 I've been made this for one+ year now.
 On Windows and Ubuntu boxes. (I'm actually on a ubuntu 10.10 box, and
 installing xdebug is easy as sudo pecl install xdebug ... then configuring
 is as easy as copy/past the following xdebug.ini to my
 /etc/php5/conf.d/xdebug.ini).

 Installing Xdebug on windows is a bit messy but when you find the correct
 dll it is okay. You'll know it's installed by php -i and looking for
 xdebug

 What is your problem ? Having xdebug installed or launching a debug
 process with eclipse and another browser (Menu Preferences  General  Web
 Browsers, add your own and check use external browser).
 To create a xdebug launch, you have to create your server in Preferences 
 Php  Servers and configure Xdebug (usually you have nothing to do).

 This is my xdebug.ini (using xdebug 2.1)
 zend_extension=/usr/lib/php5/20090626/xdebug.so
 xdebug.cli_color=1
 debug.collect_includes = 1
 xdebug.collect_params = 4
 xdebug.collect_return = 1
 xdebug.collect_vars = 1
 xdebug.default_enable = 0
 xdebug.dump_globals =0
 xdebug.dump_undefined = 1
 xdebug.show_exception_trace = 0
 xdebug.show_local_vars = 1
 xdebug.show_mem_delta = 1
 xdebug.var_display_max_depth=10
 xdebug.idekey=ECLIPSE_DBGP
 xdebug.remote_enable = 1
 xdebug.remote_connect_back=1
 xdebug.remote_host=localhost


 Regards,



 Brilliant!

 Thank you so much!  I had tried both ZendDebugger and XDebug, but couldn't
 get either to work properly.  Thanks for the tip on setting up my external
 browser.  It would be nice to configure it on a per project or per debug
 basis, but it looks like I can only configure a default browser for all
 debug configs.  I can live with that.

 I'm not sure what those settings above mean or do, but quite frankly, don't
 care if they work.  And they seem to work great.  I haven't tested it out
 fully yet (just a quick couple of things here and there), but it looks good
 so far.

 Thanks again a million!


 Eric

  --
 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


Re: [symfony-users] Re: Debugging symfony application within Eclipse?

2011-01-06 Thread Stéphane
Hello,

I've been made this for one+ year now.
On Windows and Ubuntu boxes. (I'm actually on a ubuntu 10.10 box, and
installing xdebug is easy as sudo pecl install xdebug ... then configuring
is as easy as copy/past the following xdebug.ini to my
/etc/php5/conf.d/xdebug.ini).

Installing Xdebug on windows is a bit messy but when you find the correct
dll it is okay. You'll know it's installed by php -i and looking for
xdebug

What is your problem ? Having xdebug installed or launching a debug process
with eclipse and another browser (Menu Preferences  General  Web Browsers,
add your own and check use external browser).
To create a xdebug launch, you have to create your server in Preferences 
Php  Servers and configure Xdebug (usually you have nothing to do).

This is my xdebug.ini (using xdebug 2.1)
zend_extension=/usr/lib/php5/20090626/xdebug.so
xdebug.cli_color=1
debug.collect_includes = 1
xdebug.collect_params = 4
xdebug.collect_return = 1
xdebug.collect_vars = 1
xdebug.default_enable = 0
xdebug.dump_globals =0
xdebug.dump_undefined = 1
xdebug.show_exception_trace = 0
xdebug.show_local_vars = 1
xdebug.show_mem_delta = 1
xdebug.var_display_max_depth=10
xdebug.idekey=ECLIPSE_DBGP
xdebug.remote_enable = 1
xdebug.remote_connect_back=1
xdebug.remote_host=localhost


Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Jan 6, 2011 at 5:15 PM, Dennis gear...@sbcglobal.net wrote:

 No, I never got it working. I would LOVE to single step sometimes, but
 no luck.

 So it's back to the ol' 'die()' and 'echo got to ._FILE__'
 statements.

 If any body else can tell us how to do it, WOW, Ill name my first kid
 after you, (keep in mind I'm 52 ;-)

 On Jan 5, 9:30 pm, Eric B ebenza...@gmail.com wrote:
  Hi,
 
  I'm wondering if anyone has had any success in getting a symfony app to
  debug (step-by-step) using Eclipse PDT.  I've downloaded both the XDebug
 and
  the ZendDebug dlls and am having difficulties with both.  The closest
 I've
  managed to get working is to try to create a launch config from within
  eclipse, but them I am forced to use the browse built-into eclipse, which
  isn't particularly practical.
 
  I've read through some standard PHP/Eclipse debug configuration tips on
  various sites, but haven't been very successful getting it to work the
 way I
  would like.  Basically, I would like to run/serve the app from within
  eclipse, but able to navigate/browse through any external browser.
 
  Is this even possible?  Am I missing/forgetting a simple step somewhere?
 
  Thanks!
 
  Eric

 --
 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


Re: [symfony-users] Re: Debugging symfony application within Eclipse?

2011-01-06 Thread Stéphane
On the latest Eclipse PDT, I get some problems, the debugger doesnt show me
the files, I get a lot of errors (unmanaged file blabla), but still it
works... Not as good as I was used to, but it works. Netbeans doesnt bug on
this.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Jan 6, 2011 at 5:27 PM, Stéphane stephane.er...@gmail.com wrote:

 Hello,

 I've been made this for one+ year now.
 On Windows and Ubuntu boxes. (I'm actually on a ubuntu 10.10 box, and
 installing xdebug is easy as sudo pecl install xdebug ... then configuring
 is as easy as copy/past the following xdebug.ini to my
 /etc/php5/conf.d/xdebug.ini).

 Installing Xdebug on windows is a bit messy but when you find the correct
 dll it is okay. You'll know it's installed by php -i and looking for
 xdebug

 What is your problem ? Having xdebug installed or launching a debug process
 with eclipse and another browser (Menu Preferences  General  Web Browsers,
 add your own and check use external browser).
 To create a xdebug launch, you have to create your server in Preferences 
 Php  Servers and configure Xdebug (usually you have nothing to do).

 This is my xdebug.ini (using xdebug 2.1)
 zend_extension=/usr/lib/php5/20090626/xdebug.so
 xdebug.cli_color=1
 debug.collect_includes = 1
 xdebug.collect_params = 4
 xdebug.collect_return = 1
 xdebug.collect_vars = 1
 xdebug.default_enable = 0
 xdebug.dump_globals =0
 xdebug.dump_undefined = 1
 xdebug.show_exception_trace = 0
 xdebug.show_local_vars = 1
 xdebug.show_mem_delta = 1
 xdebug.var_display_max_depth=10
 xdebug.idekey=ECLIPSE_DBGP
 xdebug.remote_enable = 1
 xdebug.remote_connect_back=1
 xdebug.remote_host=localhost


 Regards,

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



 On Thu, Jan 6, 2011 at 5:15 PM, Dennis gear...@sbcglobal.net wrote:

 No, I never got it working. I would LOVE to single step sometimes, but
 no luck.

 So it's back to the ol' 'die()' and 'echo got to ._FILE__'
 statements.

 If any body else can tell us how to do it, WOW, Ill name my first kid
 after you, (keep in mind I'm 52 ;-)

 On Jan 5, 9:30 pm, Eric B ebenza...@gmail.com wrote:
  Hi,
 
  I'm wondering if anyone has had any success in getting a symfony app to
  debug (step-by-step) using Eclipse PDT.  I've downloaded both the XDebug
 and
  the ZendDebug dlls and am having difficulties with both.  The closest
 I've
  managed to get working is to try to create a launch config from within
  eclipse, but them I am forced to use the browse built-into eclipse,
 which
  isn't particularly practical.
 
  I've read through some standard PHP/Eclipse debug configuration tips on
  various sites, but haven't been very successful getting it to work the
 way I
  would like.  Basically, I would like to run/serve the app from within
  eclipse, but able to navigate/browse through any external browser.
 
  Is this even possible?  Am I missing/forgetting a simple step somewhere?
 
  Thanks!
 
  Eric

 --
 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


Re: [symfony-users] Help Optimization Loading Symfony

2011-01-02 Thread Stéphane
Hello,

About loading performances:
for doctrine :
http://www.doctrine-project.org/documentation/manual/1_0/en/improving-performance:compile
for symfony : http://www.symfony-project.org/book/1_0/18-performance search
for Optimizing your code

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Dec 30, 2010 at 2:54 PM, Wizermil mathieu.gar...@gmail.com wrote:

 Hi,

 My company started a web service project using symfony 1.4.x +
 Doctrine + MySQL (FYI: I upgraded the project to 1.4.8) few months
 ago.
 Just to let you know what we are doing it's kind of openfeint (http://
 openfeint.com/) webservices to handle a community, leaderboards, game
 profile (level, xp, ...), virtual currency and items.
 The system is hosted on Amazon EC2 we are using 1 server for MySQL
 (ubuntu 10.10 large 64bits percona server 5.1) and many servers (ec2
 large 64bits ubuntu 9.04 + Nginx 0.7 + PPHP-FPM 5.3 + Memcached + APC)
 depending of the number of users using the services, they are behind a
 load balancer.

 Our main problem is the variance of the response time for example a
 service returning the timestamp of the server (http://
 services.yagasp.com/time/get.json) is between 85-200ms.
 The 2nd problem is the latency from chrome dev tool we have almost at
 each request 100-200ms of latency and I have no idea of the reason
 (the load average of the server is always under 1.0). The request time
 can be checked easily from a facebook games we developped: Masterchef
 (http://apps.facebook.com/mastercheflejeu)

 Now I'm assigned to the project to debug and optimize it. You will see
 below all the tests, modifications I did to solve those problems,
 without real success.
 1. I thought that it was linked to our system: sclar (https://
 www.scalr.net/) that wasn't fast enough to launch new instances but
 after many tests I saw that i wasn't the case and our settings where
 good.
 2. Then I noticed that symfony open a connection to db at each request
 so I'd changed the server:mysql to percona (http://www.percona.com/
 software/percona-server/) to be sure that the db server is able to
 handle high number of connections (stat from the db max 30
 connections) but I'm pretty sure that php driver are optimized to keep
 a pool of connection opened. It didn't change anything about time
 response or latency.
 3. Log of slow queries, all our sql queries are executed in less than
 100ms, I know that we are using a lot of join with doctrine and it's
 not recommended for performance but right now I'm not sure that it
 explains our time response for services not doing any sql requests
 like time :D (I checked with symfony debug consol)
 4. Log execution time of each request from nginx. It seems that there
 are all under 200ms so it means the info returned by chrome dev tools
 are not false. Great news but it's doesn't really help us in our case.
 5. Using ab to see the time response the only information that it gave
 me is that with concurrency the time response is increasing but at a
 specific level (that I didn't defined) it's not the case. It doesn't
 make any sense but you will see the charts at this urls:
 http://www.megaupload.com/?d=SVR7T690 and
 http://www.megaupload.com/?d=IDYZCMAX
 6. Profiling with XHProf (http://www.megaupload.com/?d=FCK266ZW) TI
 saw which methods are consuming a lot of time at each request (I'used
 the service time in prod environment) and it seems that it's the
 initialization and the loading of the classes so we are probably
 messing with parameters making the framework slower than it should be.

 Thanks for all the users that will spend the time to read and if you
 have any hints that could help me optimize the loading of symfony
 please let me know.

 Cheers,

 Mathieu

 --
 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


Re: [symfony-users] Re: Handling dynamic data in the generator.yml

2010-12-28 Thread Stéphane
When using the admin generator, there is a configuration class which have a
getFormClass method (or such), just override this method as you which :)

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Dec 28, 2010 at 10:30 AM, Tristan tristan.bessou...@gmail.comwrote:

 Thanks for the tip ;)

 On 28 déc, 09:26, Gabriel Petchesi pghora...@gmail.com wrote:
  In my opinion the proper place to do it is to override the autogenerated
  actions:
  executeNew
  executeCreate*
  executeEdit
  executeUpdate*
  executeDelete
  and put in there the conditions that checks for user type and instantiate
  the right form class.
 
  You could do it in the form class itself without changing all these
 actions
  by having a single form class for both superadmin and user and unseting
 the
  fields but this is not an elegant solution.
 
 gabriel

 --
 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


Re: [symfony-users] Best practice to use Eclipse PDT and symfony?

2010-12-14 Thread Stéphane
Hello,

In Eclipse, you can add settings in Window-PreferenceValidation,

Then select the validation you wish to configure. Here you'll be able to add
exclusion filters, adding the workspace directory you want (then select
symfony directory). It will not be validated any more, for selected
validator.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Dec 13, 2010 at 11:26 PM, Eric B ebenza...@gmail.com wrote:

 Sure - Eclipse shows icons on files with errors, but when you have a large
 tree (like you do with symfony), it is tough to see the individual errors
 all the time.  Furthermore, it is a lot easier to see in the console that
 you have errors when it is clean and not cluttered with 1000+ errors and
 warnings.  I've removed the XML validation, but still have a significant
 number of errors/warnings left that I can't figure out how to remove.

 Thanks,

 Eric


 On Mon, Dec 13, 2010 at 4:18 PM, Macvek mac...@gmail.com wrote:

 I've recently worked on a small project using PDT.

 For errors: I didn't figured how to remove error checking from symfony
 directory. It wasn't a problem, cause Eclipse shows an icon on files
 which have errors.

 Eclipse should index your code, and it will propably check the
 lib/vendor/symfony, so if you add it to buildpath, you'll have
 functions duplicates.

 For team work, I suggest ignoring cache, log, lib/vendor/symfony and
 it should work.

 During my development, I've done ordinary CLI commands, and eclipse
 (after F5 or project refresh) just checked changes and it still worked
 well. The only problem was after regenerating models, because SVN was
 creating patches instead of removing them and adding newones
 (generating a series of conflicts as result). To fix it, svn:ignore
 should be put for /lib/model/[om,map].

 Regards,
 Maciej Aleksandrowicz



 2010/12/13 benze ebenza...@gmail.com:
  Hi,
 
  I used to use Eclipse to develop Java, and am new to using it for
  PHP.  I've downloaded the Eclipse PDT All-In-One package and was
  hoping it would give me a familiar experience when programming.  I am
  hoping that there are some users on this list who use Eclipse PDT with
  symfony that can help me figure out how to set things up right.
 
  I created my new project using the Cli, and placed symfony in /lib/
  vendor/symfony.  When I create my new project (I called it mipp) in
  Eclipse, the first thing I notice is that it puts the entire project
  as the source folder in the build path.  Is that the correct way to
  set it up?  Should some folders be specifically excluded from the
  build path?  The second thing I notice is a few thousand errors in
  the /lib/vendors/symfony directory.  Mostly relating to .xml
  validation errors, .mod errors, etc.  I know I can configure eclipse
  to skip xml validation, etc, but figured there must be some better way
  to set up a project.  If I exclude symfony from the build path, the
  errors remain.
 
  I know I can remove symfony from the tree altogether and download it
  to another location as a library, but if I do that, then I'll need to
  configure my WebServer to use an external lib for symfony and not find
  it within the web-app itself.
 
  Can anyone shine a little light and experience on how to setup PDT for
  symfony properly?  I've tried searching the web, and ppl are extolling
  NetBeans and other editors, but I'd love to see this working in an
  environment I am familiar with.
 
  Thanks!
 
  Eric
 
 
  --
  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.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.comsymfony-users%2bunsubscr...@googlegroups.com
 For 

Re: [symfony-users] Pass variables through actions

2010-11-28 Thread Stéphane
Hey,

I didn't test it, but using forward instead of redirect, perhaps you can
modify the sfWebRequest object and it will get passed around to the
forwarded action, no ?

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sun, Nov 28, 2010 at 7:45 PM, oscar balladares liebegr...@gmail.comwrote:

 Hi.

 Yes, it is possible, but currently I only now the GET method.

 Look for this snippet:

 if ($this-form-isValid()){
   
 $this-redirect('contact/thankyou?'.http_build_query($this-form-getValues()));}



 On this Resource...

 http://www.symfony-project.org/forms/1_4/en/02-Form-Validation

 It is the Forms in action From Symfony docs.

 The .http_build_query will pass the data to another action, if the form is
 valid (for this example)
 But I would love to know a POST implementation example.

 If you get it first than I, please send me a short mail [?]

 2010/11/24 Marcelo marcelooliveira...@gmail.com

 Is it possible to pass variables through actions ?

 Because I use some vars in new action, but if the form is invalid it
 will stop on create action to fix the erros and then I get the
 undefined variables

 ps: The values of these variables in new action is requested by url
 (new/someid/3) which by the way is hard coded.

 Or is there another (correct) way to do that ?

 Thanks!

 --
 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.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
360.gif

Re: Yan: [symfony-users] Re: 06-Advanced-Forms Some Questions.

2010-11-23 Thread Stéphane
Of course, instead of using static variables, you can create getters to
retrieve values from configurations, so it will be easier to change the
number of allowed uploadable photos by simply changing a value in a
config/app.yml.
Something like
public function getMaxUploadablePhotos(){
return sfConfig::get('app_max_uploadable_photos');
}

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Nov 23, 2010 at 1:39 PM, Raphael Schumacher 
m...@raphaelschumacher.ch wrote:

 To limit the number of uploadable photos to 6 at most:


 // lib/form/doctrine/ProductForm.class.php
 public function configure()
 {
  static $maxUploadablePhotos = 6;
  static $maxUploadablePhotosAtOnce = 2;

  $form = new ProductPhotoCollectionForm(null, array(
'product' = $this-getObject(),
 'size'= min($maxUploadablePhotosAtOnce, max(0,
 $maxUploadablePhotos - count($this-getObject()-getPhotos(,
  ));

  $this-embedForm('newPhotos', $form);
 }

 This solution may allow more than two photos to be uploaded at once,
 but I guess you can adapt this easily to your desired behaviour.

 

 If you don't want the user to edit the already uploaded photos, you
 can simply use the unset($this['Photos']) call. most typically in the
 configure() method of the form. An alternative (but with equal
 effect): unset($this-widgetSchema['Photos'], $this-
 validatorSchema['Photos']);

 -RAPHAEL

 --
 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


Re: [symfony-users] I18N: Why Underscore?

2010-11-12 Thread Stéphane
echo __('Home') ?

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Nov 12, 2010 at 2:05 PM, Felix E. Klee felix.k...@inka.de wrote:

 I am working on an old Symfony 1.1 project [1], and I noticed a
 weirdness with I18N.

 There is the following code in a PHP file, in a partial template of the
 frontend/main module:

  __('House')

 In the translation file, there is:

  trans-unit id=1332
sourceHouse/source
targetCasa/target
  /trans-unit

 However, this translation does *not* get shown in the generated web
 page!

 It only gets shown after adding an underscore prefix:

  trans-unit id=1332
source_House/source
targetCasa/target
  /trans-unit

 However, with the underscore, i18n:extract complains:

  $ ./symfony i18n:extract --display-old frontend es_ES
   i18n  extracting i18n strings for the frontend application
   i18n  found 208 new i18n strings
   i18n  found 1 old i18n strings
   i18n  display old i18n strings
 _House

 Can someone explain this weirdness? Why the underscore?

 - Felix

 [1] To be updated once I have a good understanding of the 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.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


Re: [symfony-users] Question: The best way to embed javascript : in parial or in js files

2010-11-04 Thread Stéphane
Putting javascript tags in the middle of the body blocks the
loading/computing of the page layout (or something similar).

Having a slot to put all JS and echo it at the end or having a stacking func
to gather all js calls and echo its array at the end (within the layout) is
quite similar.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Nov 4, 2010 at 9:47 AM, JoJo jojoyangd...@gmail.com wrote:

 Hi Alex and Stéphane,


 Thanks a lot for your suggestion.

 As Gareth said, my concern is how to embed javascript function from
 partials between *head/head* tag.

 Because the return of partial will be added at the place where it is
 called, so the js functions are added in the middle of layout, it isn't
 clean.

 The use of slot for this purpose should be a good idea, i havn't tried it,
 i will keep you in contact later.

 Any suggestion is welcomed,

 Best Regards,


 JoJo

 2010/11/3 Gareth McCumskey gmccums...@gmail.com

 His one concern is having javascript included in the middle of HTML isntead
 of all at the end of the html. This tactic would still insert the javascript
 in the middle of everything.


 On Wed, Nov 3, 2010 at 12:57 PM, Alex Pilon alex.pi...@gmail.com wrote:

 You could also put that js into external js files and use use_javascript
 to have each partial include the related external js file when it loads into
 the template.


 On Wed, Nov 3, 2010 at 05:58, Gareth McCumskey gmccums...@gmail.comwrote:

 Forgot the link:
 http://www.symfony-project.org/gentle-introduction/1_4/en/07-Inside-the-View-Layer#chapter_07_sub_slots

 On Wed, Nov 3, 2010 at 11:55 AM, JoJo jojoyangd...@gmail.com wrote:

 Hello everyone,

 I have a question not very technical but quite structural.

 In my modules, I use some partials to complete the layout. And in these
 partials, I use some javascript functions. So when page loaded, these
 javascript functions are added in the middle of template.

 I think that it is not very clean do display js in that way, because
 normally they should be added between head/head, but these js 
 functions
 are spécificaly for its partials and in several js functions, i need the
 objects passed from action or component.

 So can anyone suggest what is the best way to implement these
 javascript functions please.

 Thanks in advance.

 Best Regards,

 JoJo

 --
 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 McCumskey
 http://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




 --
 Alex Pilon
 (613) 608-1480

  --
 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 McCumskey
 http://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


  --
 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

Re: [symfony-users] Question: The best way to embed javascript : in parial or in js files

2010-11-04 Thread Stéphane
Yes, ok, so it's the same for slots, just check where to echo the things.
Within action template or layout :)

Just giving pointers, not saying you have to do that this way ! :)

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Nov 4, 2010 at 10:43 AM, Macvek mac...@gmail.com wrote:

 If JS is not generated dynamically and it doesn't generate html
 (document.write) then the best way is to put it in file and refer by
 js helper
 ( use_javascript() ).

 Then to run the code, you bind to DOM Load event to execute js. In
 jQuery it is $(document).ready( ... ).

 Encapsulating js in file lets browser cache javascript, so the page is
 loaded faster.

 Regards,
 Maciej Aleksandrowicz

 2010/11/4 Stéphane stephane.er...@gmail.com:
  Putting javascript tags in the middle of the body blocks the
  loading/computing of the page layout (or something similar).
  Having a slot to put all JS and echo it at the end or having a stacking
 func
  to gather all js calls and echo its array at the end (within the layout)
 is
  quite similar.
  Regards,
  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
 
  On Thu, Nov 4, 2010 at 9:47 AM, JoJo jojoyangd...@gmail.com wrote:
 
  Hi Alex and Stéphane,
 
 
  Thanks a lot for your suggestion.
 
  As Gareth said, my concern is how to embed javascript function from
  partials between head/head tag.
 
  Because the return of partial will be added at the place where it is
  called, so the js functions are added in the middle of layout, it isn't
  clean.
 
  The use of slot for this purpose should be a good idea, i havn't tried
 it,
  i will keep you in contact later.
 
  Any suggestion is welcomed,
 
  Best Regards,
 
 
  JoJo
 
  2010/11/3 Gareth McCumskey gmccums...@gmail.com
 
  His one concern is having javascript included in the middle of HTML
  isntead of all at the end of the html. This tactic would still insert
 the
  javascript in the middle of everything.
 
  On Wed, Nov 3, 2010 at 12:57 PM, Alex Pilon alex.pi...@gmail.com
 wrote:
 
  You could also put that js into external js files and use
 use_javascript
  to have each partial include the related external js file when it
 loads into
  the template.
 
  On Wed, Nov 3, 2010 at 05:58, Gareth McCumskey gmccums...@gmail.com
  wrote:
 
  Forgot the
  link:
 http://www.symfony-project.org/gentle-introduction/1_4/en/07-Inside-the-View-Layer#chapter_07_sub_slots
 
  On Wed, Nov 3, 2010 at 11:55 AM, JoJo jojoyangd...@gmail.com
 wrote:
 
  Hello everyone,
 
  I have a question not very technical but quite structural.
 
  In my modules, I use some partials to complete the layout. And in
  these partials, I use some javascript functions. So when page
 loaded, these
  javascript functions are added in the middle of template.
 
  I think that it is not very clean do display js in that way, because
  normally they should be added between head/head, but these js
 functions
  are spécificaly for its partials and in several js functions, i need
 the
  objects passed from action or component.
 
  So can anyone suggest what is the best way to implement these
  javascript functions please.
 
  Thanks in advance.
 
  Best Regards,
 
  JoJo
 
  --
  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 McCumskey
  http://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
 
 
 
  --
  Alex Pilon
  (613) 608-1480
 
  --
  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

Re: [symfony-users] Re: Package template/layout as a plugin to re-use across sites?

2010-11-02 Thread Stéphane
The Diem CMF/CMS does the same thing.
I believe there is no standard way, but this can be a good one to do so.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Nov 2, 2010 at 5:49 PM, rich_81 rich.s...@gmail.com wrote:


 On Nov 1, 10:52 pm, John Kary johnk...@gmail.com wrote:
  Our University is using symfony 1.x for many different internal
  applications, and we want to easily brand them with our University's
  web template. I figured creating this inside a plugin would be best,
  so we could easily update the plugin when we tweak the template design
  instead of copying around a layout file to app/frontend/templates/
  layout.php.
 
  I looked through documentation and didn't see how I could package a
  layout.php file as a plugin. Is this possible, or how would I go about
  doing it?

 I'd like to know if there's an official correct way of doing it...
 in the meantime, I've been experimenting this week with the same
 thing.  I ended up creating a new plugin directory, and first of all
 adding in a config/ directory containing the following in the
 myPluginConfiguration.class.php file:

 class myPluginConfiguration extends sfPluginConfiguration
 {
  public function initialize()
  {
sfConfig::set(my_plugin_dir, $this-getRootDir());
  }
 }

 Then created a directory in the plugin called 'layout' and placed my
 layout.php file inside.

 Finally in the view.yml in my application, I used:

  layout: ?php echo sfConfig::get(my_plugin_dir) . /layout/
 layout; ?

 This seems to work OK, however it does seem a bit hackish so I'd be
 interested to know of better ways! :-)

 Rich

 --
 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


Re: [symfony-users] Re: per RECORD/Entity permissions?

2010-10-27 Thread Stéphane
Here it is :

?php

class Doctrine_Template_Permissionable extends Doctrine_Template
{
public function setTableDefinition()
{
$this-addListener( new
Doctrine_Template_Listener_Permissionable($this-getOptions()) );
}
}

---

?php
class Doctrine_Template_Listener_Permissionable extends
Doctrine_Record_Listener
{
static protected $OBJECT_PATTERN = %s/%d/%s;
static protected $OBJECT_ACTIONS = array('create'=array(), 'edit'=array(),
'delete'=array());

protected $invoker = null;

public function __construct($options = array())
{
if( !isset($options['object_pattern']))
{
$options['object_pattern'] = self::$OBJECT_PATTERN;
}
if( !isset($options['object_actions']))
{
$options['object_actions'] = self::$OBJECT_ACTIONS;
}
$this-_options = array_merge($this-_options, $options);
}

/**
 * Compute the name of the permission for this subject and action.
 *
 * @param Doctrine_Record $subject
 * @param string $action
 * @return string
 */
public function computePermissionName($subject, $action)
{
$sClass = null;
if( 'no' == $this-getOption('subtype_concrete') )
{
$sClass =  $this-getOption('subtype_replace');
if( strlen($sClass) == 0 )
{
throw new sfException(get_class($subject) . ' has no subtype_replace set in
its Permissionable behavior.');
}
}
else
{
$sClass = get_class( $subject );
if( $this-getOption('subtype_discriminant', false) 
count($subject-getTable()-getOption('subclasses')) 0)
{
$sClass = $subject-get($this-getOption('subtype_discriminant', false));
}
}
return sprintf($this-getOption('object_pattern'), $sClass,
$subject-getId(), $action );
}

public function postInsert(Doctrine_Event $e)
{
$this-insertPermissions($e);
}

protected function insertPermissions(Doctrine_Event $e)
{
$actions = $this-getOption('object_actions');
if($actions)
{
foreach($actions as $actionName=$aParams)
{
$permission = new sfGuardPermission();
$permission-name = $this-computePermissionName($e-getInvoker(),
$actionName);
$permission-description = isset($aParams['description']) ?
$aParams['description'] : '';
$permission-save();
if(isset($aParams['link_to'])  !empty($aParams['link_to']))
{
foreach($aParams['link_to'] as $group )
{
$oGroup = Doctrine::getTable('sfGuardGroup')-findOneByName($group);
if($oGroup)
{
$oGroup-permissions[] = $permission;
$oGroup-save();
}
}
}
}
}
}

public function postDelete(Doctrine_Event $e)
{
$actions = $this-getOption('object_actions');
if($actions)
{
$names = array();
foreach($actions as $actionName=$aParams)
{
$names[] = $this-computePermissionName($e-getInvoker(), $actionName);
}
Doctrine_Query::create()-delete('sfGuardPermission p')-whereIn('name',
$names)-execute();
}
}
}

--

Configuration within schema.yml:
actAs:
Permissionable:
  # let developer specify if perms are using concrete class or no
  # can be yes or no; this is for inheritance management
  subtype_concrete: no
  # if subtype_concrete=no, then developers can specify which type to
use
  # can be any class which is part of the inheritance chain
  subtype_replace: vsBasicpage
  # if you say subtype_concrete=yes, then you have to tell the template
which column is the discriminant for subtype
  #subtype_discriminant: subtype
  # %s/%d/%s : vsBasicpage/:id/:object_action
  object_pattern: %s/%d/%s
  object_actions:
# example of usage
#create:
#  description: to create a page
 #  link_to: [contributors] #link to group contributors
edit: ~
delete: ~
insert: ~
togglePublish: ~
access: ~

This was mainly used to secure module/actions, not record methods. That's
why you can see object_actions and not object_methods.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Oct 26, 2010 at 9:27 PM, Stéphane stephane.er...@gmail.com wrote:

 Ok.

 I have made such a behavior for Doctrine 1.2, some months ago, might
 not be perfect feet for your needs, anyway. I'll share it tomorow
 here.

 Regards,

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



 On Tue, Oct 26, 2010 at 8:57 PM, Dennis gear...@sbcglobal.net wrote:
  I *DID* mean database records/entities :-).
 
  So, the only post so far that points in the right direction seems to
  be the one showing a concantenated:
 
   RECORD.USER.ACTION. I would probably make it
   RECORD.GROUP.ACTION.
 
  The user's personal group would represent his own permissions and
  other groups could be assigned permissions and other members. That way
  I wouldn't have to assigne 10M rows of permissions per record in the
  database.
 
 
 
  On Oct 26, 7:33 am, Stéphane stephane.er...@gmail.com wrote:
  Ah, so it's my tweaked mind :-)
 
  Regards,
 
  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
  On Tue, Oct 26

Re: [symfony-users] per RECORD/Entity permissions?

2010-10-26 Thread Stéphane
In my mind it was to manage user access to actions, based not only on
a per-action basis, but also on a per-record-user-action, - Can user
X can execute action Y ? - Take a look at its credentials for X_Y_Z !

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Tue, Oct 26, 2010 at 8:48 AM, Gareth McCumskey gmccums...@gmail.com wrote:
 sfGuard is a FUNCTIONAL security mechanism, not a DATA SCOPE mechanism. What
 this means is that sfGuard is best suited to restricting access to what a
 user can DO, not necessarily what data they can SEE.
 We resolve this in our own applications by mapping data to users. For
 example, one of our applications does things on a domain level. A user can
 either have access to data for that domain or not. If they are allowed
 access to a specified domain, then all images, text, and other database
 entries linked to that domain in the database are shown to that user. This
 then gives the flexibility to assign multiple domains to a user, assign a
 mixture of domains to different users etc and the system will only yank the
 applicable data.
 What this means ultimately is that you need to work the logic of limiting to
 the correct data for a user within all your database queries. That is, quite
 honestly, the only sane way to do it.

 On Mon, Oct 25, 2010 at 6:38 PM, Dennis Gearon gear...@sbcglobal.net
 wrote:

 Does sfGuard allow assigning 'per record' permissions, or only the usual
 Symfony 'per application/action' permissions?


 Dennis Gearon

 Signature Warning
 
 It is always a good idea to learn from your own mistakes. It is usually a
 better idea to learn from others’ mistakes, so you do not have to make them
 yourself. from
 'http://blogs.techrepublic.com.com/security/?p=4501tag=nl.e036'

 EARTH has a Right To Life,
  otherwise we all die.

 --
 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



 --
 Gareth McCumskey
 http://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


-- 
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


Re: [symfony-users] Ajax tips in Symfony?

2010-10-26 Thread Stéphane
Saying Symfony, I thought he wanted help on Sf2.0, not 1.4 ;)
Perhaps it is still the same thing in regards to javascript side,
anyway.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Tue, Oct 26, 2010 at 8:21 AM, Jérémie jeremie.symf...@gmail.com wrote:
 This link should help you :
 http://www.symfony-project.org/jobeet/1_4/Doctrine/en/18

 You'll see, it's very easy :)

 Jérémie

 Le lundi 25 octobre 2010 à 16:36 -0700, Parijat Kalia a écrit :
 Hey people...

 Sorry if this email sounds hurried up, but I am hurried up!

 So I have a page view where I have a comments feature. So users can
 comment upon the data they preview on the page. It is offcourse, a
 post operation, but I would like the comments to appear simultaneously
 as I implement this. I have 0 experience regarding Ajax, but if anyone
 can send pointers to me as to exactly how this can happen, that would
 be really cool!

 Regards

 Parijat


 --
 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


-- 
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


Re: [symfony-users] per RECORD/Entity permissions?

2010-10-26 Thread Stéphane
Ah, so it's my tweaked mind :-)

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Tue, Oct 26, 2010 at 3:23 PM, Gareth McCumskey gmccums...@gmail.com wrote:
 Maybe it was just worded badly. I see record and think database records
 

 On Tue, Oct 26, 2010 at 9:41 AM, Stéphane stephane.er...@gmail.com wrote:

 In my mind it was to manage user access to actions, based not only on
 a per-action basis, but also on a per-record-user-action, - Can user
 X can execute action Y ? - Take a look at its credentials for X_Y_Z !

 Regards,

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



 On Tue, Oct 26, 2010 at 8:48 AM, Gareth McCumskey gmccums...@gmail.com
 wrote:
  sfGuard is a FUNCTIONAL security mechanism, not a DATA SCOPE mechanism.
  What
  this means is that sfGuard is best suited to restricting access to what
  a
  user can DO, not necessarily what data they can SEE.
  We resolve this in our own applications by mapping data to users. For
  example, one of our applications does things on a domain level. A user
  can
  either have access to data for that domain or not. If they are allowed
  access to a specified domain, then all images, text, and other database
  entries linked to that domain in the database are shown to that user.
  This
  then gives the flexibility to assign multiple domains to a user, assign
  a
  mixture of domains to different users etc and the system will only yank
  the
  applicable data.
  What this means ultimately is that you need to work the logic of
  limiting to
  the correct data for a user within all your database queries. That is,
  quite
  honestly, the only sane way to do it.
 
  On Mon, Oct 25, 2010 at 6:38 PM, Dennis Gearon gear...@sbcglobal.net
  wrote:
 
  Does sfGuard allow assigning 'per record' permissions, or only the
  usual
  Symfony 'per application/action' permissions?
 
 
  Dennis Gearon
 
  Signature Warning
  
  It is always a good idea to learn from your own mistakes. It is usually
  a
  better idea to learn from others’ mistakes, so you do not have to make
  them
  yourself. from
  'http://blogs.techrepublic.com.com/security/?p=4501tag=nl.e036'
 
  EARTH has a Right To Life,
   otherwise we all die.
 
  --
  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
 
 
 
  --
  Gareth McCumskey
  http://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
 

 --
 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



 --
 Gareth McCumskey
 http://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


-- 
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


Re: [symfony-users] Re: per RECORD/Entity permissions?

2010-10-26 Thread Stéphane
Ok.

I have made such a behavior for Doctrine 1.2, some months ago, might
not be perfect feet for your needs, anyway. I'll share it tomorow
here.

Regards,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Tue, Oct 26, 2010 at 8:57 PM, Dennis gear...@sbcglobal.net wrote:
 I *DID* mean database records/entities :-).

 So, the only post so far that points in the right direction seems to
 be the one showing a concantenated:

  RECORD.USER.ACTION. I would probably make it
  RECORD.GROUP.ACTION.

 The user's personal group would represent his own permissions and
 other groups could be assigned permissions and other members. That way
 I wouldn't have to assigne 10M rows of permissions per record in the
 database.



 On Oct 26, 7:33 am, Stéphane stephane.er...@gmail.com wrote:
 Ah, so it's my tweaked mind :-)

 Regards,

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!

 On Tue, Oct 26, 2010 at 3:23 PM, Gareth McCumskey gmccums...@gmail.com 
 wrote:
  Maybe it was just worded badly. I see record and think database records
  

  On Tue, Oct 26, 2010 at 9:41 AM, Stéphane stephane.er...@gmail.com wrote:

  In my mind it was to manage user access to actions, based not only on
  a per-action basis, but also on a per-record-user-action, - Can user
  X can execute action Y ? - Take a look at its credentials for X_Y_Z !

  Regards,

  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!

  On Tue, Oct 26, 2010 at 8:48 AM, Gareth McCumskey gmccums...@gmail.com
  wrote:
   sfGuard is a FUNCTIONAL security mechanism, not a DATA SCOPE mechanism.
   What
   this means is that sfGuard is best suited to restricting access to what
   a
   user can DO, not necessarily what data they can SEE.
   We resolve this in our own applications by mapping data to users. For
   example, one of our applications does things on a domain level. A user
   can
   either have access to data for that domain or not. If they are allowed
   access to a specified domain, then all images, text, and other database
   entries linked to that domain in the database are shown to that user.
   This
   then gives the flexibility to assign multiple domains to a user, assign
   a
   mixture of domains to different users etc and the system will only yank
   the
   applicable data.
   What this means ultimately is that you need to work the logic of
   limiting to
   the correct data for a user within all your database queries. That is,
   quite
   honestly, the only sane way to do it.

   On Mon, Oct 25, 2010 at 6:38 PM, Dennis Gearon gear...@sbcglobal.net
   wrote:

   Does sfGuard allow assigning 'per record' permissions, or only the
   usual
   Symfony 'per application/action' permissions?

   Dennis Gearon

   Signature Warning
   
   It is always a good idea to learn from your own mistakes. It is usually
   a
   better idea to learn from others’ mistakes, so you do not have to make
   them
   yourself. from
   'http://blogs.techrepublic.com.com/security/?p=4501tag=nl.e036'

   EARTH has a Right To Life,
    otherwise we all die.

   --
   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

   --
   Gareth McCumskey
  http://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

  --
  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

  --
  Gareth McCumskey
 http://garethmccumskey.blogspot.com
  twitter: @garethmcc

  --
  If you want to report a vulnerability issue on symfony, please send

Re: [symfony-users] per RECORD/Entity permissions?

2010-10-25 Thread Stéphane
Hi,

sfGuard allows you to assign permissions to users and/or groups.

symfony module/action security.yml let you define which permission is
needed to the user to be able to execute the action.

Anyway, you can use the sfGuard model to create per-record and
per-action permissions, like %CLASS%_%OBJECT_ID%_%MODULE%_%ACTION%
which will create, for example, for a module named myClassModule and
its show action, for an object of class myClass with id 2, this
permission : myClass_2_myClassModule_show.

Then, another problem is assigning the permission to the users/groups.

Regards,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Mon, Oct 25, 2010 at 6:38 PM, Dennis Gearon gear...@sbcglobal.net wrote:
 Does sfGuard allow assigning 'per record' permissions, or only the usual 
 Symfony 'per application/action' permissions?


 Dennis Gearon

 Signature Warning
 
 It is always a good idea to learn from your own mistakes. It is usually a 
 better idea to learn from others’ mistakes, so you do not have to make them 
 yourself. from 
 'http://blogs.techrepublic.com.com/security/?p=4501tag=nl.e036'

 EARTH has a Right To Life,
  otherwise we all die.

 --
 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


Re: [symfony-users] doctrine query and not in (select ...) doesnt work

2010-10-24 Thread Stéphane
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


Re: [symfony-users] sfDoctrineGuard user profile one-to-one relationships

2010-10-22 Thread Stéphane
Hi,

You don't need refClass for 1-to-1 !

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Sat, Oct 23, 2010 at 1:31 AM, Jonotron jonot...@gmail.com wrote:
 I want to create a one-to-one relationship between users and
 companies. Since I shouldn't be editing the sfDoctrineGuard schema's
 directlyI've created a sfGuardUserProfile model:

 sfGuardUserProfile:
  tableName:            sf_guard_user_profile
  columns:
    user_id:            { type: integer, notnull: true }
    org_id:             { type: integer, notnull: true }
  relations:
    sfGuardUser:        { onDelete: CASCADE, local: user_id, foreign:
 id, foreignAlias: Profile, foreignType: one, type: one }
    Company:        { onDelete: CASCADE, local: org_id, foreign: id,
 foreignAlias: sfGuardUserProfiles }


 And my Company model has a relation like this:
  relations:
    sfGuardUser:
      foreignAlias: Company
      class: sfGuardUser
      local: id
      foreign: org_id
      refClass: sfGuardUserProfile
      foreignType: one

 This appears to create all the correct models, the basesfGuardUser
 model has:

        $this-hasOne('Company', array(
             'refClass' = 'sfGuardUserProfile',
             'local' = 'org_id',
             'foreign' = 'id'));


 However, when I do:
 $sf_user-getGuardUser()-getCompany();

 it returns a collection rather than an object. The simple fix is to do
 this:
 $sf_user-getGuardUser()-getProfile()-getCompany();

 (and refactor it into the sfGuardUser class)

 I suspect that the refClass is what is causing this behaviour. Is this
 intended? is there another way to create a one-to-one relationship as
 I've described above? My solution works, but it feels wrong somehow.

 Thanks


 --
 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


Re: [symfony-users] Re: How to change a POST value posted from form

2010-10-20 Thread Stéphane
Retrieving the sfContext from within your model is bad coding.
How to test your model then (when in CLI there is no sfContext available).

You have to separate concerns : the controller is here to prepare data
to the model and view.

Then you'll be able to test your models separatly, giving them what
they do need from within your tests (so tests will be acting as
controllers, in feeding the models with data according to scenariis).

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



On Thu, Oct 21, 2010 at 12:26 AM, hribo hribo...@gmail.com wrote:
 hello, thank you for all your posts. i am still new to OOP and MVC.
 i have already solved my problem.

 but one thing i have found out that it actually is possible to
 retrieve post parameter from model with using this syntax :
 sfContext::getInstance()-getRequest()-
getParameter('lender_user_id');


 --
 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


Re: [symfony-users] distinguishing between task and web request

2010-10-13 Thread Stéphane
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


Re: [symfony-users] Nested Form in Doctrine - symfony 1.4

2010-10-06 Thread Stéphane
Maybe this too :
http://www.symfony-project.org/plugins/ahDoctrineEasyEmbeddedRelationsPlugin

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Oct 6, 2010 at 10:37 PM, Gustavo Adrian comfortablynum...@gmail.com
 wrote:

 Maybe this could help:

 http://www.symfony-project.org/more-with-symfony/1_4/en/06-Advanced-Forms


 http://www.symfony-project.org/more-with-symfony/1_4/en/06-Advanced-FormsBest
 regards.


 On Wed, Oct 6, 2010 at 5:26 PM, hribo hribo...@gmail.com wrote:

 Hi all,
 I would like to create the same exact thing as is descibed at blog:

 http://www.symfony-project.org/blog/2008/11/10/call-the-expert-nested-forms-a-real-implementation
 but this is done only for propel

 is there anybody who knows how to do nested forms in doctrine for
 symfony 1.4?
 or do you know about good tutorial or official material about nested
 forms or embeding forms?
 I was searching for these items but nothing suited my needs.

 thank you for 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.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


Re: [symfony-users] Re: Doctrine problem with sf 1.3.7/8 - 1.4.7/8

2010-10-01 Thread Stéphane
Bertrand, good website, btw :-) (french reader)

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Oct 1, 2010 at 1:28 PM, Bertrand Zuchuat mailingl...@funstaff.chwrote:

 Hi Loïc,

 I use this solution to resolve this problem:

 http://www.funstaff.ch/2010/08/27/multiples-connexions-doctrine-et-le-chargement-des-modeles

 Best regards

 Bertrand

 Le 1 oct. 2010 à 10:37, Loïc Vernet a écrit :

 ?

 2010/9/28 Loïc Vernet vernet.l...@gmail.com

 Thanks.

 There are now 3 people reporting the issue in the ticket. I'm surprise
 there is not more feedback, because it can potentially break all projects
 who are using more than 1 doctrine connexion.

 Kris ? Jonathan ?


 2010/9/24 BenjaM1 benjamin.grandf...@gmail.com

 Hi Loïc,

 I had this bug too and I found this which works fine for me :
 http://www.doctrine-project.org/jira/browse/DC-421
 But I hope it will be resolved as fast as possible ... :(

 On Sep 24, 1:14 pm, Loïc Vernet vernet.l...@gmail.com wrote:
  Hi,
 
  Did someone looked at this bug ?
 
  http://trac.symfony-project.org/ticket/9092
 
  It seems like a regression since 1.4.6...
 
  ++ COil

 --
 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


  --
 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


Re: [symfony-users] Re: Deploy to Same Server?

2010-09-20 Thread Stéphane
You can overload the project:deploy task to feet your needs.

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Sep 20, 2010 at 10:32 PM, Felix E. Klee felix.k...@inka.de wrote:

 On Sep 20, 9:32 pm, Felix E. Klee felix.k...@inka.de wrote:
  Is it possible to disable SSH in properties.ini?

 Just looked at the source, and the answer is no. Of course, I could
 try defining some alias for ssh, but that would not be a robust
 solution.

 So, I'll just stick with SSH-ing to localhost.

 --
 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


Re: [symfony-users] Choosing the best JS toolkit plugin for RIA

2010-09-09 Thread Stéphane
If you want true javascript framework (with OO layer), for
desktop-application UI look-alike, look at qooxdoo !

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Sep 10, 2010 at 7:20 AM, Gareth McCumskey gmccums...@gmail.comwrote:

 If you want something that is probably the most actively maintained open
 source JS framework go for JQuery. JQuery even has a collection of JQuery UI
 elements as a sub project. There is even easy integration options with
 symfony.


 On Wed, Sep 8, 2010 at 10:53 PM, Daniel Toffetti dto...@gmail.com wrote:

 Hi all,

I'm a new Symfony user, with some experience in the Wicket java
 web framework. I need to develop rich internet apps for internal
 usage, mainly to replace old VB6 desktop apps.
One of the main requirements is that the application must look and
 behave like a desktop app, say, a drop down main menu at the top,
 powerful data grids (editable, sortable, groupable, etc) and
 treeviews, modal dialogs that are able to hold forms, etc.
So far, I believe my best options are Dojo, ExtJS and YUI, but
 can't decide between them. Dojo plugin seems best supported than ExtJS
 and YUI.
So this is two questions in fact:

 1- Which of the JS toolkits I've mentioned is the best in term of
 features ? Is there any other I've missed and should consider ?
 2- How much support exist for them in the form of a Symfony plugin ?
 How difficult would it be to enhance / complete the existing support ?

 Cheers and thanks,

 Daniel

 --
 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 McCumskey
 http://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


-- 
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


Re: [symfony-users] IDE

2010-09-03 Thread Stéphane
Free:
Netbeans : simple
Eclipse : simple and complex
VIM : :-)

Commercial:
phpStorm
Zend Studio
PHPEdit

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Sep 3, 2010 at 3:56 PM, Andrei Dziahel trickster...@gmail.comwrote:

 Hi.

 For free — Netbeans, commercial — PHPStorm.

 2010/9/3 |-|@|\/|||) hamidrezaa...@gmail.com

 I need IDE for symfony. please introduce IDE for symfony.

 --
 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




 --
 With the best regards, Andrei.

 --
 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


Re: [symfony-users] IE8 and isXmlHttpRequest

2010-08-31 Thread Stéphane
Compare the http request headers of the firefox's xhr over the ie8's one

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Aug 31, 2010 at 8:20 PM, HAUSa 
jeroen_heeft_behoefte_aan_r...@hotmail.com wrote:

 In IE8, my isXmlHttpRequest function doesn't work.
 In my template, I use ?php if(!$sf_request-isXmlHttpRequest()): ?
 to hide content if it is an AJAX call.
 Firefox handles this okay, but IE8 shows the entire template, as well
 as the complete layout again!

 How is this possible? Bug?
 Anyone who knows a fix?

 --
 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


Re: [symfony-users] Re: headers already sent

2010-08-30 Thread Stéphane
You mean you are writting HTML within actions ?


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Aug 30, 2010 at 3:18 PM, bibob olivier.bib...@cnfpt.fr wrote:

 Hi,
 If I write return sfView::NONE; at the end of the function, the
 problem is solved, but I'm not sure that it is very clean and elegant.
 I rather think that I have to rewrite the functions and expurgate all
 the HTML instructions from them.
 Thank you all for your help.

 On 25 août, 19:11, Florian sideral.undergro...@gmail.com wrote:
  IMHO, this is not a HTML header problem but a HTTPheadersproblem. It
  happens when php tris to send httpheaders(via header() function )
  after havingsentsome http body response!
 
  On 25 août, 12:57, Lutz lutz.p...@gmail.com wrote:
 
   This message generally occurs, when the webserver is asked to send the
   header of the HTML-page, but some content of the body-section had
  alreadybeen send to the  client (and so the header).
   I experienced this behaviour when working with symfony (1.4), when you
   do have an 'echo' or any other html-output in your action class.
   Use the action class for actions and for output the templates, this
   should solve the problem.
 
   The comment about the space, carriage return or closing '?' I saw
   several times as solution for this issue also, but me personally was
   never able to reproduce that in my cases.
 
   BR,
   Lutz
 
   On 25 Aug., 11:33, bibob olivier.bib...@cnfpt.fr wrote:
 
Hi,
Thank you for your answer.
I don't find a bad space character anywhere in the actions.class or
templates of my project.
It's curious because when I modify a existing report, I have no
problem, but when I create a new one, the problem appears.
Maybe, I miss a step !
 
On 20 août, 23:25, Jochen Daum jdau...@gmail.com wrote:
 
  Hi,
 
  On Sat, Aug 21, 2010 at 1:13 AM, bibob olivier.bib...@cnfpt.fr
 wrote:
  Bonjour,
  lors du lancement d'un rapport d'administration au format .csv
 dans
  l'actions.class.php du module concerné, j'ai le message, en fin
 de
  fichier, cannot modifiy header information -headerssentin /lib/
  vendor/symfony/lib/response/sfWebResponse.class.php puis un
 paquet de
  commandes HTML
  J'ai vérifié la présence d'espace dans les scripts que j'ai
 modifiés,
  j'ai retapé toutes les lignes, sans résultat. quelqu'un a-t-il
 une
  solution ? Merci
 
  its nearly always some characters after the closing ? of the
 file. I
  think this happens because of transmission/charset problems most
 of th
  time.
 
  Short term solution is to find the file which has the additional
 space
  characters. Long term remove ? at the end of files. I don't know
 what
  Symfony's policy is for that.
 
  Kind Regards,
 
  Jochen Daum
 
  P.S.: My french is very weak.- Zitierten Text ausblenden -
 
- Zitierten Text anzeigen -

 --
 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


Re: [symfony-users] y2K38 bug in PHP - Symfony

2010-08-27 Thread Stéphane
64bit isn't the common answer ?


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Aug 27, 2010 at 10:57 AM, Mercedes Sualog III 
mercedes.sua...@gmail.com wrote:

 I am encountering the Y2K38 bug in PHP/Symfony used in my application.
 Any suggestion on how to solve it?
 Here is the link about the bug:


 http://www.sitepoint.com/blogs/2010/08/24/is-your-php-application-affected-by-the-y2k38-bug/

 Please help.Thank you.

 --
 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


Re: [symfony-users] Re: Symfony 1.4-compatible minifier for Symfony now included in Apostrophe, can be used in any Symfony project

2010-08-27 Thread Stéphane
Hi,

We sometime need to combine js and css depending on runtime things, so its
better handled this way I think.

Thank you !

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Aug 27, 2010 at 10:53 AM, Thomas Rabaix tho...@rabaix.net wrote:

 Hello,

 Sorry to hijack this thread, but If you are looking for a way to combine
 asset (js and css) you *really* have to look at this plugin :
 http://github.com/rande/swCombinePlugin/blob/master/README.md

 The main advantage is that no computation is done at runtime, but through a
 task.


 On Fri, Aug 27, 2010 at 1:56 AM, Benoit Pr benoit.perro...@gmail.comwrote:

 Hi,

 I just implemented this plugin, which seems very interesting (1.4
 compatible also).

 However, when i use a_include*, I am collecting js and css which are
 not in my project, like these one for example:
 /apostrophePlugin/css/a-reset.css
 /apostrophePlugin/css/a-utility.css
 /apostrophePlugin/css/a-forms.css
 /apostrophePlugin/css/a-buttons.css
 /apostrophePlugin/css/a-navigation.css
 /apostrophePlugin/css/a-components.css
 /apostrophePlugin/css/a-area-slots.css
 /apostrophePlugin/css/a-engines.css
 /apostrophePlugin/css/a-admin.css
 /apostrophePlugin/css/a-colors.css
 /apostrophePlugin/js/aUI.js
 /apostrophePlugin/js/aControls.js
 /apostrophePlugin/js/plugins/jquery.autogrow.js
 /apostrophePlugin/js/plugins/jquery.keycodes-0.2.js
 /apostrophePlugin/js/plugins/jquery.timer-1.2.js
 /apostrophePlugin/js/a.js

 How do disable the call to thoses files?

 Thanks by advance,

 On 18 août, 16:34, Stéphane stephane.er...@gmail.com wrote:
  Done :http://trac.apostrophenow.org/ticket/533
 
  http://trac.apostrophenow.org/ticket/533Cheers,
 
  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
 
 
  On Wed, Aug 18, 2010 at 3:24 PM, Tom Boutell t...@punkave.com wrote:
   A specific task would be convenient for those who consider 'symfony
   cc' too heavy, and I could still invoke it automatically from a
   'symfony cc' hook. Would you mind opening a ticket on
   trac.apostrophenow.org to remind me to look at this?
 
   On Aug 17, 9:54 am, Stéphane stephane.er...@gmail.com wrote:
+1 for the specific task !
 
Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
On Tue, Aug 17, 2010 at 3:52 PM, Daniel Lohse
annismcken...@googlemail.comwrote:
 
 Mhm, I somehow I knew that this would have been t easy. (:
 
 But okay, so we do need to cache these relations array(bundle =
 sha1sum.ccsgz) somewhere it gets loaded on every request and I'd
 guess
   the
 app.yml.php file is a good place. Still, using this approach does
 not
 necessitate – or even need for that matter – manual cache
 invalidation
 because we could send the far future Expires header everytime. If
 files
   in
 that bundle change, clear the files (not necessarily with a
 brute-force
 symfony cc) and they are rebuilt on the next page refresh. Maybe
 we
   could
 provide a apostrophe:clear-minified-resources [--js] [--css]
 [--all]
 [--env=dev|prod|staging] task so as to not need the brute-force
   symfony cc
 or go hunting for these minified files manually?
 
 Cheers, Daniel
 
 On 17.08.2010, at 15:32, Tom Boutell wrote:
 
  Daniel, this almost works and I got pretty excited thinking
 about
  it... but there's a tragic flaw.
 
  On the first page access you slurp up all the CSS files, minify
 them,
  md5 that and create a cache file. Fine.
 
  On the second page access you... can't point to the cache file
   without
  first doing all of that again (everything except actually
 writing the
  file) just to figure out what the filename is. (:
 
  Opening all of the files, slurping them in and md5'ing them on
 every
  page access is overhead we do not want. So it makes more sense
 to
   have
  a cache key.
 
  On Aug 16, 9:13 am, Daniel Lohse annismcken...@googlemail.com
   wrote:
  Sorry for being a bit slow today: why would we need cache
   invalidation?
 If the filename of the compacted file(s) is a hash generated from
 the
 contents of the file then after one file changes and the
   scripts/stylesheets
 are re-generated the filename changes. The browser then should
 just
   request
 the file because it doesn't about that file yet (filename is not
 the
   same).
 
  Am I missing something here?
 
  Cheers, Daniel
 
  Sent from my iPad
 
  On Aug 16, 2010, at 2:59 PM, Tom Boutell t...@punkave.com
 wrote:
 
  You're right, we do need cache invalidation. I just came up
 with a
  clean way to do it without tweaking app.yml settings, adding a
   table
  or making glob() calls: just use a file in the asset-cache
 folder
   to
  hold

Re: [symfony-users] Re: What Symfony CMF should I use? Apostrophe, Sympal, Diem?

2010-08-27 Thread Stéphane
Sympal is just a sample IMO.

Apostrophe is edit-in-context, with simple but goot slot-type task
scaffolding generator.

Diem is edit-in-context-within-a-lightbox, with good backend features
(create a page for kinds of records you specify in a module.yml config file;
say you want a page generated for each course, you can do this very easily
with diem, as it is a bundled feature).

It's pretty simple to diemize apostrophe, while its harder to
apostrophize Diem (speaking about their backend options; Apostrophe has
none except for its blog plugin, while Diem is back-ended for almost
everything)(I say this because apostrophizing Diem will need to touch core
Diem, while diemizing apostrophe can be done via apostrophe plugins).

Diem is pretty good with its toolbar in edit mode; Apostrophe have a toolbar
too, but not for the same thing (but you can diemize apostrophe as I
said).

Anyway, you can test them both, your feelings does matter here.

I can be wrong somehow, hope others will correct me :-)

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, Aug 27, 2010 at 6:47 PM, rumianom maciej.rumianow...@gmail.comwrote:

 As fair as I know Diem is standalone CMS, others are plugins.

 On 27 Sie, 00:12, Fabian Barrera barrera.ale...@gmail.com wrote:
  Hi, I have a question about the Symfony CMFs (Sympal, Apostrophe,
  Diem). I hope someone could help me:
 
  I haven't used any CMS before (but I use Symfony and love it :) ) and
  I'll have to build a site with a lot of features that a CMF can manage
  (forum, news, personal blogs, events). But it also requires especific
  features (messaging, courses and groups associated to a professor).
 
  So, wich one of these CMFs would be better for this project? I'm
  thinking in Apostrophe, because it seems I can add it to an existing
  project with my own modules, can I do the same with the others?
 
  Thanks

 --
 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


Re: [symfony-users] Re: headers already sent

2010-08-25 Thread Stéphane
Yes, it is the HTTP headers, not the HTML HEAD thing.

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Aug 25, 2010 at 7:11 PM, Florian sideral.undergro...@gmail.comwrote:

 IMHO, this is not a HTML header problem but a HTTP headers problem. It
 happens when php tris to send http headers (via header() function )
 after having sent some http body response!


 On 25 août, 12:57, Lutz lutz.p...@gmail.com wrote:
  This message generally occurs, when the webserver is asked to send the
  header of the HTML-page, but some content of the body-section had
  already been send to the  client (and so the header).
  I experienced this behaviour when working with symfony (1.4), when you
  do have an 'echo' or any other html-output in your action class.
  Use the action class for actions and for output the templates, this
  should solve the problem.
 
  The comment about the space, carriage return or closing '?' I saw
  several times as solution for this issue also, but me personally was
  never able to reproduce that in my cases.
 
  BR,
  Lutz
 
  On 25 Aug., 11:33, bibob olivier.bib...@cnfpt.fr wrote:
 
 
 
   Hi,
   Thank you for your answer.
   I don't find a bad space character anywhere in the actions.class or
   templates of my project.
   It's curious because when I modify a existing report, I have no
   problem, but when I create a new one, the problem appears.
   Maybe, I miss a step !
 
   On 20 août, 23:25, Jochen Daum jdau...@gmail.com wrote:
 
 Hi,
 
 On Sat, Aug 21, 2010 at 1:13 AM, bibob olivier.bib...@cnfpt.fr
 wrote:
 Bonjour,
 lors du lancement d'un rapport d'administration au format .csv
 dans
 l'actions.class.php du module concerné, j'ai le message, en fin de
 fichier, cannot modifiy header information -headerssentin /lib/
 vendor/symfony/lib/response/sfWebResponse.class.php puis un
 paquet de
 commandes HTML
 J'ai vérifié la présence d'espace dans les scripts que j'ai
 modifiés,
 j'ai retapé toutes les lignes, sans résultat. quelqu'un a-t-il une
 solution ? Merci
 
 its nearly always some characters after the closing ? of the file.
 I
 think this happens because of transmission/charset problems most of
 th
 time.
 
 Short term solution is to find the file which has the additional
 space
 characters. Long term remove ? at the end of files. I don't know
 what
 Symfony's policy is for that.
 
 Kind Regards,
 
 Jochen Daum
 
 P.S.: My french is very weak.- Zitierten Text ausblenden -
 
   - Zitierten Text anzeigen -

 --
 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


Re: [symfony-users] Loading factories.yml configuration from task

2010-08-24 Thread Stéphane
What this means is that you need to add an (optional) argument (with default
value) to your task, named application.


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Aug 24, 2010 at 6:16 PM, Thomas Rabaix tho...@rabaix.net wrote:

 factories configuration is linked to an application configuration object
 via sfContext object. Tasks are standalone objects.

 However there is a hack : read the getMailer() documentation
 from sfCommandApplicationTask class :

* Returns a mailer instance.
*
* Notice that your task should accept an application option.
* The mailer configuration is read from the current configuration
* instance, which is automatically created according to the current
* --application option.
*

 On Tue, Aug 24, 2010 at 10:42 AM, Martin Chatterton 
 martin.paul.chatter...@gmail.com wrote:

 Hi, I'm using symfony 1.4.6 and I have the following configuration set
 in my factories.yml file...

 #
 all:
  mailer:
param:
  transport:
class: Swift_SendmailTransport
param:
  command: /usr/sbin/sendmail -oi -t
 #

 ...to overcome the 'double dot' issue as described here -

 http://swiftmailer.lighthouseapp.com/projects/21527/tickets/113-quoted-printable-soft-line-breaks-problem
 .

 When I run the following code...

 #
 $mailer = $this-getMailer();
 $message = $mailer-compose();

 $message-setTo('f...@bar.com');
 $message-setFrom('f...@bar.com');
 $message-setSubject('Testing');
 $message-setBody(
  $mailer-getRealtimeTransport()-getCommand(),
  'text/plain'
 );

 $mailer-send($message);
 #

 ...inside an action everything works as expected. But when I run the
 same code from inside a task, I get a fatal error - PHP Fatal error:
 Call to undefined method getCommand - because SwiftMailer is using the
 default transport class and not the Swift_SendmailTransport class as
 specified in the factories.yml configuration.

 Any ideas why the factories.yml configuration isn't loaded in a
 symfony task, and how I can go about solving this issue?

 --
 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 Rabaix
 http://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.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


Re: [symfony-users] schema modified but same old database

2010-08-19 Thread Stéphane
Look at the doctrine:clean-model-files task

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Aug 19, 2010 at 11:41 AM, Jérémie jeremie.symf...@gmail.com wrote:

 There must be your old class in lib/form lib/model/ lib/filters...
 I had the same problem, and it seems like symfony uses you schema.yml
 but also base files in these directories.
 Delete them, rebuild everything and it should be ok!

 Jérémie

 Le jeudi 19 août 2010 à 10:34 +0200, KEY5 a écrit :
  Hello,
 
  I have changed some things in the schema.yml
  and cleared cache ( both symfony cache:clear and symfony cc  :-D )
 
  I've rebuilt the model, I've done symfony doctrine:build --sql
 
  yet the same database is recreated, (deleted tables are back every
 time...)
 
 
  What am I missing?
 


 --
 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


Re: [symfony-users] Re: Symfony 1.4-compatible minifier for Symfony now included in Apostrophe, can be used in any Symfony project

2010-08-18 Thread Stéphane
Done : http://trac.apostrophenow.org/ticket/533


http://trac.apostrophenow.org/ticket/533Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Aug 18, 2010 at 3:24 PM, Tom Boutell t...@punkave.com wrote:

 A specific task would be convenient for those who consider 'symfony
 cc' too heavy, and I could still invoke it automatically from a
 'symfony cc' hook. Would you mind opening a ticket on
 trac.apostrophenow.org to remind me to look at this?

 On Aug 17, 9:54 am, Stéphane stephane.er...@gmail.com wrote:
  +1 for the specific task !
 
  Before Printing, Think about Your Environmental Responsibility!
  Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
  On Tue, Aug 17, 2010 at 3:52 PM, Daniel Lohse
  annismcken...@googlemail.comwrote:
 
   Mhm, I somehow I knew that this would have been t easy. (:
 
   But okay, so we do need to cache these relations array(bundle =
   sha1sum.ccsgz) somewhere it gets loaded on every request and I'd guess
 the
   app.yml.php file is a good place. Still, using this approach does not
   necessitate – or even need for that matter – manual cache invalidation
   because we could send the far future Expires header everytime. If files
 in
   that bundle change, clear the files (not necessarily with a brute-force
   symfony cc) and they are rebuilt on the next page refresh. Maybe we
 could
   provide a apostrophe:clear-minified-resources [--js] [--css] [--all]
   [--env=dev|prod|staging] task so as to not need the brute-force
 symfony cc
   or go hunting for these minified files manually?
 
   Cheers, Daniel
 
   On 17.08.2010, at 15:32, Tom Boutell wrote:
 
Daniel, this almost works and I got pretty excited thinking about
it... but there's a tragic flaw.
 
On the first page access you slurp up all the CSS files, minify them,
md5 that and create a cache file. Fine.
 
On the second page access you... can't point to the cache file
 without
first doing all of that again (everything except actually writing the
file) just to figure out what the filename is. (:
 
Opening all of the files, slurping them in and md5'ing them on every
page access is overhead we do not want. So it makes more sense to
 have
a cache key.
 
On Aug 16, 9:13 am, Daniel Lohse annismcken...@googlemail.com
 wrote:
Sorry for being a bit slow today: why would we need cache
 invalidation?
   If the filename of the compacted file(s) is a hash generated from the
   contents of the file then after one file changes and the
 scripts/stylesheets
   are re-generated the filename changes. The browser then should just
 request
   the file because it doesn't about that file yet (filename is not the
 same).
 
Am I missing something here?
 
Cheers, Daniel
 
Sent from my iPad
 
On Aug 16, 2010, at 2:59 PM, Tom Boutell t...@punkave.com wrote:
 
You're right, we do need cache invalidation. I just came up with a
clean way to do it without tweaking app.yml settings, adding a
 table
or making glob() calls: just use a file in the asset-cache folder
 to
hold the current cache key. The OS should cache reads from that
 file
extremely well.
 
It may even be possible to avoid the filesystem hit by writing it
 as a
PHP file in cache/frontend/prod/config that just calls
sfConfig::set(). Then with any luck it would be autoloaded and even
cached by APC until its modification date changes just like an
 app.yml
setting would. But plain old file_get_contents() calls to a simple
file with an asset cache version number in it would also get cached
nicely by the operating system so it might be overkill to try to
 wedge
it into Symfony's cache.
 
On Aug 15, 11:44 am, pghoratiu pghora...@gmail.com wrote:
It might be worthwhile to take things a step further by
 versioning
them in the URL so that they can be given an infinite cache
   expiration
date, although this requires a database hit or perhaps a glob
 call
when outputting the pages that contain them. The code is a big
 step
forward as-is if you are using unminimized, uncombined CSS and JS
 and
has no negative impact on your existing caching issues, but we'll
think about next steps.
 

I think think it's important to add cache invalidation as well. My
suggestion is to append another key
to app.yml to have a cache key that can be updated manually and
 append
that key too the minified resource
file:
all:
  a:
ver:1
css/main.css?ver=1
This way css and js pages can be cached indefinitely on the client
side without having problems when manually
updating the css or js files.
 
gabriel
 
--
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

Re: [symfony-users] Re: Symfony 1.4-compatible minifier for Symfony now included in Apostrophe, can be used in any Symfony project

2010-08-17 Thread Stéphane
I didn't took a look at the implementation yet.

PHP is caching filesystem infos AFAIK.

Can't we use these file informations as part of the key cache to compute md5
? So their will be no more need to invalidate, it will invalidate by itself,
or by calling (for hard-writting apps) clearstatcache() ?

Cheers,



Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Aug 17, 2010 at 3:32 PM, Tom Boutell t...@punkave.com wrote:

 Daniel, this almost works and I got pretty excited thinking about
 it... but there's a tragic flaw.

 On the first page access you slurp up all the CSS files, minify them,
 md5 that and create a cache file. Fine.

 On the second page access you... can't point to the cache file without
 first doing all of that again (everything except actually writing the
 file) just to figure out what the filename is. (:

 Opening all of the files, slurping them in and md5'ing them on every
 page access is overhead we do not want. So it makes more sense to have
 a cache key.

 On Aug 16, 9:13 am, Daniel Lohse annismcken...@googlemail.com wrote:
  Sorry for being a bit slow today: why would we need cache invalidation?
 If the filename of the compacted file(s) is a hash generated from the
 contents of the file then after one file changes and the scripts/stylesheets
 are re-generated the filename changes. The browser then should just request
 the file because it doesn't about that file yet (filename is not the same).
 
  Am I missing something here?
 
  Cheers, Daniel
 
  Sent from my iPad
 
  On Aug 16, 2010, at 2:59 PM, Tom Boutell t...@punkave.com wrote:
 
   You're right, we do need cache invalidation. I just came up with a
   clean way to do it without tweaking app.yml settings, adding a table
   or making glob() calls: just use a file in the asset-cache folder to
   hold the current cache key. The OS should cache reads from that file
   extremely well.
 
   It may even be possible to avoid the filesystem hit by writing it as a
   PHP file in cache/frontend/prod/config that just calls
   sfConfig::set(). Then with any luck it would be autoloaded and even
   cached by APC until its modification date changes just like an app.yml
   setting would. But plain old file_get_contents() calls to a simple
   file with an asset cache version number in it would also get cached
   nicely by the operating system so it might be overkill to try to wedge
   it into Symfony's cache.
 
   On Aug 15, 11:44 am, pghoratiu pghora...@gmail.com wrote:
   It might be worthwhile to take things a step further by versioning
   them in the URL so that they can be given an infinite cache
 expiration
   date, although this requires a database hit or perhaps a glob call
   when outputting the pages that contain them. The code is a big step
   forward as-is if you are using unminimized, uncombined CSS and JS and
   has no negative impact on your existing caching issues, but we'll
   think about next steps.
 
   
   I think think it's important to add cache invalidation as well. My
   suggestion is to append another key
   to app.yml to have a cache key that can be updated manually and append
   that key too the minified resource
   file:
   all:
 a:
   ver:1
   css/main.css?ver=1
   This way css and js pages can be cached indefinitely on the client
   side without having problems when manually
   updating the css or js files.
 
   gabriel
 
   --
   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.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


Re: [symfony-users] Re: Symfony 1.4-compatible minifier for Symfony now included in Apostrophe, can be used in any Symfony project

2010-08-17 Thread Stéphane
+1 for the specific task !



Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Aug 17, 2010 at 3:52 PM, Daniel Lohse
annismcken...@googlemail.comwrote:

 Mhm, I somehow I knew that this would have been t easy. (:

 But okay, so we do need to cache these relations array(bundle =
 sha1sum.ccsgz) somewhere it gets loaded on every request and I'd guess the
 app.yml.php file is a good place. Still, using this approach does not
 necessitate – or even need for that matter – manual cache invalidation
 because we could send the far future Expires header everytime. If files in
 that bundle change, clear the files (not necessarily with a brute-force
 symfony cc) and they are rebuilt on the next page refresh. Maybe we could
 provide a apostrophe:clear-minified-resources [--js] [--css] [--all]
 [--env=dev|prod|staging] task so as to not need the brute-force symfony cc
 or go hunting for these minified files manually?

 Cheers, Daniel

 On 17.08.2010, at 15:32, Tom Boutell wrote:

  Daniel, this almost works and I got pretty excited thinking about
  it... but there's a tragic flaw.
 
  On the first page access you slurp up all the CSS files, minify them,
  md5 that and create a cache file. Fine.
 
  On the second page access you... can't point to the cache file without
  first doing all of that again (everything except actually writing the
  file) just to figure out what the filename is. (:
 
  Opening all of the files, slurping them in and md5'ing them on every
  page access is overhead we do not want. So it makes more sense to have
  a cache key.
 
  On Aug 16, 9:13 am, Daniel Lohse annismcken...@googlemail.com wrote:
  Sorry for being a bit slow today: why would we need cache invalidation?
 If the filename of the compacted file(s) is a hash generated from the
 contents of the file then after one file changes and the scripts/stylesheets
 are re-generated the filename changes. The browser then should just request
 the file because it doesn't about that file yet (filename is not the same).
 
  Am I missing something here?
 
  Cheers, Daniel
 
  Sent from my iPad
 
  On Aug 16, 2010, at 2:59 PM, Tom Boutell t...@punkave.com wrote:
 
  You're right, we do need cache invalidation. I just came up with a
  clean way to do it without tweaking app.yml settings, adding a table
  or making glob() calls: just use a file in the asset-cache folder to
  hold the current cache key. The OS should cache reads from that file
  extremely well.
 
  It may even be possible to avoid the filesystem hit by writing it as a
  PHP file in cache/frontend/prod/config that just calls
  sfConfig::set(). Then with any luck it would be autoloaded and even
  cached by APC until its modification date changes just like an app.yml
  setting would. But plain old file_get_contents() calls to a simple
  file with an asset cache version number in it would also get cached
  nicely by the operating system so it might be overkill to try to wedge
  it into Symfony's cache.
 
  On Aug 15, 11:44 am, pghoratiu pghora...@gmail.com wrote:
  It might be worthwhile to take things a step further by versioning
  them in the URL so that they can be given an infinite cache
 expiration
  date, although this requires a database hit or perhaps a glob call
  when outputting the pages that contain them. The code is a big step
  forward as-is if you are using unminimized, uncombined CSS and JS and
  has no negative impact on your existing caching issues, but we'll
  think about next steps.
 
  
  I think think it's important to add cache invalidation as well. My
  suggestion is to append another key
  to app.yml to have a cache key that can be updated manually and append
  that key too the minified resource
  file:
  all:
a:
  ver:1
  css/main.css?ver=1
  This way css and js pages can be cached indefinitely on the client
  side without having problems when manually
  updating the css or js files.
 
  gabriel
 
  --
  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.comsymfony-users%2bunsubscr...@googlegroups.com
  For more options, visit this 

Re: [symfony-users] Re: Install plugins programmatically?

2010-08-12 Thread Stéphane
There is a class which helps you wrapping methods. Search for
sfClassManipulator.

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Aug 12, 2010 at 8:07 AM, Damon Jones damonljo...@gmail.com wrote:

 You can certainly run these tasks from within a task, as described
 here:

 http://www.symfony-project.org/more-with-symfony/1_4/en/13-Leveraging-the-Power-of-the-Command-Line

 So, maybe you can create instance of these tasks and run them from
 elsewhere in your code.

 I think the issue would be how you enable them in your
 ProjectConfiguration.

 On Aug 11, 8:49 pm, Gustavo Adrian comfortablynum...@gmail.com
 wrote:
  Hi!
 
  Quick question: Is there a way to install and enable a plugin from PHP?
 
  Thanks!

 --
 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


Re: [symfony-users] Re: a good IDE for Symfony

2010-08-11 Thread Stéphane
When I code only PHP, i use eclipse.
When I have to mix php, js and html, I use netbeans as eclipse is buggy when
it is about to mix code languages (even helios) :/

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Aug 11, 2010 at 5:29 PM, wodzik wodzik...@gmail.com wrote:

 I'm using NetBeans because it has friendly use of shortcut, already,
 and if i want use IDE for other language it is there.
 In Eclipse it's always problem with compatibility of plugins. NB is
 supported by the Oracle.

 --
 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


Re: [symfony-users] Re: a good IDE for Symfony

2010-08-11 Thread Stéphane
I guess so :-)


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Aug 11, 2010 at 6:17 PM, Julian julian.reyes.escri...@gmail.comwrote:

 i find the root of the problem is Windows, i install a old ubuntu 9.04 and
 for now dont have trouble, i think for now netbeans is unestable when the
 project grows but if you re instasll the problem vanished

 2010/8/11 Stéphane stephane.er...@gmail.com

 When I code only PHP, i use eclipse.
 When I have to mix php, js and html, I use netbeans as eclipse is buggy
 when it is about to mix code languages (even helios) :/

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


 On Wed, Aug 11, 2010 at 5:29 PM, wodzik wodzik...@gmail.com wrote:

 I'm using NetBeans because it has friendly use of shortcut, already,
 and if i want use IDE for other language it is there.
 In Eclipse it's always problem with compatibility of plugins. NB is
 supported by the Oracle.

 --
 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.comsymfony-users%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/symfony-users?hl=en




 --
 Si la depuración es el proceso de eliminar errores, entonces la
 programación debe ser el proceso de introducirlos
 – Edsger W. Dijkstra

 --
 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


Re: [symfony-users] Re: Urls in Javascript

2010-08-10 Thread Stéphane
Hi,


I have no problem generating js within templates.

I see js in two ways :
there are libraries, which are static files, and there are configuration
javascripts which do use the js libraries.
Within template I generate JS using script .../script and setting
php-side variables using ?php echo ..? within the js script scope.
Of course, there are different partials or components. Some are js-related
some are not.
A dynamic js is a partial or a component depending on its complexity, still
I have no problem at doing this so.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Aug 10, 2010 at 10:32 AM, Sebastien Armand [Pink]
khe...@gmail.comwrote:

 Have found a way to do it, this is through use_dynamic_javascript('route');

 the route here will point for example at a javascript module
 javascript/mydynamicscript and can use the '.js' format.
 then you can skip the mydynamicscript action and directly go to the
 template mydynamicscriptSuccess.js.php

 In this template you can put your script and use the php tags to echo the
 links needed.

 Not sure yet which solution I will personally use, but thought the solution
 might be useful for some of us!

 2010/8/9 Kevin kevinb...@gmail.com

 I have also run into this problem.  Using the href/action works great
 for links and forms but isn't always applicable since some ajax calls
 don't rely on those html items.  What I do is set a dummy meta tag
 with the url in it and pull that in with javascript.  Not the best
 solution but at least I can keep my javascript completely seperate...

 I have discussed this before:

 http://groups.google.ca/group/symfony-users/browse_thread/thread/50389a8ad4d987c/d983f5b09c512702?lnk=gstq=ajax+url#d983f5b09c512702

 The ideal soltion would be to use the html5 data attribute:
 http://ejohn.org/blog/html-5-data-attributes/ but using this breaks
 xhtml validation...

 - Kevin

 On Aug 9, 1:16 am, Sebastien Armand [Pink] khe...@gmail.com wrote:
  In both your suggestions, if I get them correctly, the idea is that from
 a
  template, I should output some javascript to set some variables or any
 other
  way to get the url back from my javascript later. Which seems weird to
 me,
  and wrong on the side that I don't really want to add js in my
 templates
  and prefer to keep it separate.
 
  For an idea, my case goes like this: I have a form to enter some
 information
  of a sofa for example, and one of the fields allows me to chose a
 design
  for the sofa. This design has some default dimensions: width and length.
  Those are the information I want to bring back through ajax.
 
  So:
  1. get to the form page to create a new sofa
  2. choose a design
  3. this triggers the JS to go look for the default size (from the design
  module) and fill it in the form.
 
  my js file is in the js folder and in it I have a url linking to
  /design/:design_id.json but for this to work on my dev environment, I
 need
  that url to be: /frontend_dev.php/design/:design_id.json.
 
  So is there a way to output that url in the js through php and symfony?
  Or a way that I can get it through the dom but without already having to
 put
  it here by myself beforehand?
 
  2010/8/7 Stéphane stephane.er...@gmail.com
 
   It shouldnt break.
   You should do this:
 
   Create a route to reach your module/action
 (/apps/$app/config/routing.yml,
   check doc).
   Then in a template, write something like:
 
   script type=text/javascript
   window.myactionurl = ?php echo url_for('@my_route')?;
 
   alert(window.myactionurl);
   $.post(window.myactionurl, null, function(data){//...});
   /script
 
   This is a stupid example (about the window.myactionurl, store this
   somewhere else).
 
   Before Printing, Think about Your Environmental Responsibility!
   Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!
 
   On Sat, Aug 7, 2010 at 12:25 PM, Phennim phen...@gmail.com wrote:
 
   Get the url from the DOM using js.
 
   $('a.do-ajax').click(function(){
var url = $(this).attr('href');
 
$.post(url, function(data){
  //do stuff
});
   });
 
   On Aug 7, 11:11 am, Sebastien Armand [Pink] khe...@gmail.com
   wrote:
Hello everyone,
 
I was wondering how to get an environment independent url in
 javascript
files. My js needs to connect to the server and get some JSON data
 and
update a form on certain actions. But putting that actions url in
 the js
directly breaks everything when you change environment...
 
I might be missing something here but don't see the light of how to
 do
   it,
any insight welcome ;-)
 
   --
   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

Re: [symfony-users] Re: Urls in Javascript

2010-08-07 Thread Stéphane
It shouldnt break.
You should do this:

Create a route to reach your module/action (/apps/$app/config/routing.yml,
check doc).
Then in a template, write something like:

script type=text/javascript
window.myactionurl = ?php echo url_for('@my_route')?;

alert(window.myactionurl);
$.post(window.myactionurl, null, function(data){//...});
/script

This is a stupid example (about the window.myactionurl, store this somewhere
else).


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, Aug 7, 2010 at 12:25 PM, Phennim phen...@gmail.com wrote:

 Get the url from the DOM using js.

 $('a.do-ajax').click(function(){
  var url = $(this).attr('href');

  $.post(url, function(data){
//do stuff
  });
 });


 On Aug 7, 11:11 am, Sebastien Armand [Pink] khe...@gmail.com
 wrote:
  Hello everyone,
 
  I was wondering how to get an environment independent url in javascript
  files. My js needs to connect to the server and get some JSON data and
  update a form on certain actions. But putting that actions url in the js
  directly breaks everything when you change environment...
 
  I might be missing something here but don't see the light of how to do
 it,
  any insight welcome ;-)

 --
 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


Re: [symfony-users] Re: Real purpose of admin generator

2010-08-03 Thread Stéphane
That is right, having a declaration style is always good, at any point.
Because it makes code reusable, at least.

Admin-gen is not made to handle all the needs, even if it can.
The idea is really good, the implementation has its own limits.
Limits that you can extend by extending the admin-gen files, or create your
very own.

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Aug 3, 2010 at 7:21 AM, pghoratiu pghora...@gmail.com wrote:

 I see the admin generator more as a starting point, something you can
 build upon.
 We have in our application backend both simple and complicated admin
 modules.
 Simple - generated admin modules where only a couple of partials are
 used, no actions override.
 Complicated - rewritten editing + custom object actions.
 Even for complicated modules we are able to reuse some functionality
 such as listing, filtering, ordering
 so it's a win for my point of view.

 What I've seen also in our project is that people don't know how to
 solve a given task using the admin generator
 and start to work against it (due to time constraints, other
 reasons) thus defeating the whole point of using it.

 Having less lines of written PHP code is always good.

gabriel


 On Jul 26, 9:03 pm, Christian Fazzini christian.fazz...@gmail.com
 wrote:
  Hello all,
 
  I've used admin generator a few times. Personally, I don't really
  understand the point of this. The forms in admin generator are based
  on the definitions in the form class. For the backend app, why is the
  common convention for devs to use admin generator? The only difference
  admin generator provides is the search filter. Doctrine generate
  creates the same kind of CRUD functionality that is seen in admin
  generator.
 
  Second, since we have to rely on yml files (i.e. generator.yml) to
  configure the forms in admin generator. It leads to messy code.
  Especially when we have to declare partials in the .yml file just to
  display something different.
 
  Third, if our forms are a bit more complex. We need to copy most of
  the code from /cache dir and paste into the backend module actions
  file. Which makes it a bit tedious if we need to extend our
  application. Plus, we need to do this for every backend module that
  admin generator creates. And the same thing for templates!
 
  If I would have used doctrine generate (for example: symfony
  doctrine:generate-module --with-show --non-verbose-templates frontend
  user User) instead. I would have easy access to the templates folder.
  and the action files. Exactly the same way I would have it in the
  frontend app. Which in some ways, also keeps the coding structure
  consistent.
 
  Having admin generator only complicates the flow of things and defeats
  the purpose of keeping things convenient.
 
  I am starting to suspect that the admin generator is more for
  prototyping than anything
 
  What are your thoughts?

 --
 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


Re: [symfony-users] a good IDE for Symfony

2010-08-03 Thread Stéphane
Download the ScanOnDemand plugin, its a well know problem in NetBeans as it
is always scanning files whatever you do.
It might not be the solution, but give it a try.

Eclipse is a good one too.

You can try VIM too (really).

Cheers

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Aug 4, 2010 at 3:39 AM, Julian Reyes Escrigas 
julian.reyes.escri...@gmail.com wrote:

 I know, but help to write less , when netbens trouble me i use Gedit but i
 dont have a Linux well stup now i dont have time for that

 -Mensaje original-
 De: symfony-users@googlegroups.com [mailto:symfony-us...@googlegroups.com]
 En nombre de Eno
 Enviado el: martes, 03 de agosto de 2010 19:35
 Para: symfony-users@googlegroups.com
 Asunto: Re: [symfony-users] a good IDE for Symfony

 On Tue, 3 Aug 2010, Julian Reyes Escrigas wrote:

  I need help for find a new editor for PHP, I'm using Netbeans 6.9 but
  I don't know for what is slow, always start very well but when the
  project grows it's turns unstable

 You dont really need an IDE to write PHP code.



 --


 --
 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.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


Re: [symfony-users] Re: How to add new type to schema?

2010-08-02 Thread Stéphane
AFAIK Doctrine manages the Inet type when using pgSql.
http://www.symfony-project.org/doctrine/1_2/en/04-Schema-Files
Search for INET

I don't know if there is any inet type validator on the symfony-doctrine,
but that's not that difficult to code as a validator, then modify generator
form to add the validator as needed.

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


2010/8/3 Michał Piotrowski mkkp...@gmail.com

 2010/8/3 Rafał inad...@gmail.com:
  On Aug 3, 12:14 am, Michał Piotrowski mkkp...@gmail.com wrote:
  Hi,
 
  2010/8/3 Rafał inad...@gmail.com:
 
 
 
   Hi,
   I want to ask for help. I want to add new data type to my schema.yml.
   I have a field name IP (IP Address) in my application. My Postgresql
   database has 'inet' data type but I can't use it in my symfony.
 
   Could you help me and show some links how to do it?
 
  How about string(40) (or better string(64) because it is more round
 number)?
 
  It's IPv6 compliant ;)
 
 
  Thanx for very fast answer... but it's not good solution for me. I
  need 'inet' type in my postgres database.
 
  Is it very difficult to change some symfony core files in order to do
  it?

 Rather, you will need to start in your ORM code - Propel or Doctrine.
 I do not know if it is difficult. You have to ask on the
 doctrine-devel or propel-devel lists. In symfony part you may want to
 create a form field validator. Probably something else will need to be
 done.

 Regards,
 Michal

 --
 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


Re: [symfony-users] Re: symfony and Eclipse: I can not go to the function or class using F3.

2010-07-15 Thread Stéphane
What you can do when using eclipse is doing such:

In the declaration of the  $this-usuario property, add this comment bloc:
/**
 *
 * @var sf**Route
 */
Then Eclipse will know the type of this var.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, Jul 15, 2010 at 7:39 AM, Bernhard Schussek bschus...@gmail.comwrote:

 Hi Javier,

 That's because the return type of getRoute() is defined as sfRoute[1],
 which doesn't have a getObject() method. Eclipse can't know that this
 method returns a sfObjectRoute in this specific case.

 Bernhard

 [1]
 http://trac.symfony-project.org/browser/branches/1.4/lib/action/sfAction.class.php#L505

 --
 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


Re: [symfony-users] symfony and Eclipse: I can not go to the function or class using F3.

2010-07-12 Thread Stéphane
Right click on the folder and Build PathUse as source folder

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jul 12, 2010 at 1:43 PM, Javier Garcia tirengar...@gmail.comwrote:

 On 07/11/2010 05:58 PM, Stéphane wrote:

 Hi,

 Check that your lib folders are source folders.


 Thanks, but how can i check that?



 On 07/11/2010 06:49 PM, Mariano Sola wrote:

 sorry for the question, but why using eclipse?


 I tried NB but when i wanted to go the declaration of a method, it shows
 the list of the methods of all the classes with that name of the function,
 so it's not being aware of the class of the object that calls the method.
 Eclipse go directly to the method Im calling.

 --
 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


Re: [symfony-users] symfony and Eclipse: I can not go to the function or class using F3.

2010-07-11 Thread Stéphane
Hi,

Check that your lib folders are source folders.

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sun, Jul 11, 2010 at 5:56 PM, Javier Garcia tirengar...@gmail.comwrote:

 Hi,

 Im using Eclipse (Build id: 20090920-1017) to write my symfony web app
 and in many times I can not go to the declaration of functions or
 classes (you know placing the cursor where the class or the function
 is called and then pressing F3).

 For example: I have this class:

 class UsuarioFormFilter extends BaseUsuarioFormFilter{

 }

 When i try to go to BaseUsuarioFormFilter it doesn't work..

 Any idea?

 Javi

 Sf 1.3 and Ubuntu 8.04

 --
 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


Re: [symfony-users] Re: Create sfGuard user in production environment

2010-07-03 Thread Stéphane
Perhaps you can write php code to execute cli commands, put it on ftp and
call it to execute.

system('symfony doctrine:build --all --no-confirmation');
system('symfony guard:create-user .


Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, Jul 3, 2010 at 2:47 PM, Mariano Sola mariano.s...@gmail.com wrote:

 nope!
 I have run the create statements of the database tables doing a php file
 which invoke the database connection and shoot them. That's all permissions
 I have.

 thanks for your time!


 On Fri, Jul 2, 2010 at 6:17 PM, fRAnKEnSTEin shirkav...@gmail.com wrote:

 Mariano,

 Do you have access to the database? for example using phpmyadmin or
 something?

 Cheers

 --
 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.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


Re: [symfony-users] ahDoctrineEasyEmbeddedRelationsPlugin csrf

2010-06-15 Thread Stéphane
When you do $this-disableLocalCSRFProtection();
You have to do this too (AFAIK it works for my code) :

$this-getValidator('_csrf_token')-setOption('required', false);

Cheers,



Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Jun 15, 2010 at 5:24 PM, DC ciprian.dob...@gmail.com wrote:

 Hello.

 I`m using ahDoctrineEasyEmbeddedRelationsPlugin in the amin part of my
 app.
 My problem is I still get the CSRF attack errors whenever I want to
 save, even though I added

 $this-disableLocalCSRFProtection();

 to ALL of my form filters.

 Can anyone help?

 Also, I can`t figure out how to configure my form display part of the
 generator.yml without loosing the subforms.

 --
 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


Re: [symfony-users] ahDoctrineEasyEmbeddedRelationsPlugin csrf

2010-06-15 Thread Stéphane
You might need to do it for the embedded forms too.

Cheers,

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, Jun 15, 2010 at 5:27 PM, Stéphane stephane.er...@gmail.com wrote:

 When you do $this-disableLocalCSRFProtection();
 You have to do this too (AFAIK it works for my code) :

 $this-getValidator('_csrf_token')-setOption('required', false);

 Cheers,



 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!



 On Tue, Jun 15, 2010 at 5:24 PM, DC ciprian.dob...@gmail.com wrote:

 Hello.

 I`m using ahDoctrineEasyEmbeddedRelationsPlugin in the amin part of my
 app.
 My problem is I still get the CSRF attack errors whenever I want to
 save, even though I added

 $this-disableLocalCSRFProtection();

 to ALL of my form filters.

 Can anyone help?

 Also, I can`t figure out how to configure my form display part of the
 generator.yml without loosing the subforms.

 --
 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] Plugin post install processing

2010-06-14 Thread Stéphane ERARD
Hi list,

I'm creating a plugin. When user installs it, I need my plugin to do
some processing.
How do I do that ?

I've seen the plugin.post_install event, but where do I put the
connect ?


Thank you !

-- 
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


Re: [symfony-users] Plugin post install processing

2010-06-14 Thread Stéphane
Yes, I think the task is the best way, as the publish-assets is about
assets, and what I need is creating configurations files at the
project-level.

Thank you !

Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, Jun 14, 2010 at 4:33 PM, Eno symb...@gmail.com wrote:

 On Mon, 14 Jun 2010, Serkan Koyuncu wrote:

  I think, you have to create another task which user should run after
  installing your plugin.

 Probably you need to supply the CLI task 'plugin:publish-assets'.


 --


 --
 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: ckWebService for sf1.4

2010-06-06 Thread Stéphane ERARD
Up ?

On 2 juin, 17:45, Stéphane stephane.er...@gmail.com wrote:
 Another problem I see is this plugin doesnt take care of plugin modules.

 Anyone made anything for this to work for plugin modules ?

 Thank you !

 Cheers,

 Before Printing, Think about Your Environmental Responsibility!
 Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!

 On Wed, Jun 2, 2010 at 5:42 PM, Stéphane ERARD 
 stephane.er...@gmail.comwrote:



  Hi list,

  I'm using ckWebService on symfony 1.4 (using svn co; not cli
  plugin:install).

  I have to change a method in the ckWebServiceController.class.php/
  ckWebServiceController-getResultAdapter method

  Here is my own :

   /**
    * Gets the result adapter for the current action, if no instance
  exists, one is created.
    *
    * @return ckAbstractResultAdapter A result adapter for the current
  action
    */
   public function getResultAdapter()
   {
     if(is_null($this-resultAdapter))
     {

       $config = sfYaml::load(sfConfig::get('sf_app_module_dir') .
  DIRECTORY_SEPARATOR . $this-context-getModuleName() .
  DIRECTORY_SEPARATOR . 'config' . DIRECTORY_SEPARATOR . 'module.yml');
       $result = $config[sfConfig::get('sf_environment')][$this-
  context-getActionName()]['result'];

       //$result = sfConfig::get(sprintf('mod_%s_%s_result', $this-
  context-getModuleName(), $this-context-getActionName()), array());
       $class  = isset($result['class']) ? $result['class'] :
  'ckPropertyResultAdapter';
       $param  = isset($result['param']) ? $result['param'] : array();

       $adapter = new $class($param);

       $this-resultAdapter = $adapter instanceof
  ckAbstractResultAdapter ? $adapter : new ckPropertyResultAdapter();
     }

     return $this-resultAdapter;
   }

  And it is working.

  Hope this can be integrated in a new version for sf1.4 ?
  Hope I don't have made any mistake too... :-)

  Cheers,

  --
  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...@goog 
  legroups.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] dsExtDirectPlugin and plugins-modules

2010-06-02 Thread Stéphane ERARD
Hi list,

I have generated a plugin with a module and declared, using doc
annotations, a extdirect service.
It looks like the dsExtDirect task does not take care of the plugin
modules, so I guess this has been forgotten.

I'm going to change the task so it supports generating API specs for
plugins-modules (the ones declared as enabled in settings.yml).
Hope I'll make it work and can deliver it as enhancement.

Cheers,

-- 
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: dsExtDirectPlugin and plugins-modules

2010-06-02 Thread Stéphane ERARD
Aaah just found the answer; it is managed via the
app_ds_ext_direct_plugin_include_plugins :-)

Thank you !

On 2 juin, 11:14, Stéphane ERARD stephane.er...@gmail.com wrote:
 Hi list,

 I have generated a plugin with a module and declared, using doc
 annotations, a extdirect service.
 It looks like the dsExtDirect task does not take care of the plugin
 modules, so I guess this has been forgotten.

 I'm going to change the task so it supports generating API specs for
 plugins-modules (the ones declared as enabled in settings.yml).
 Hope I'll make it work and can deliver it as enhancement.

 Cheers,

-- 
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] ckWebService for sf1.4

2010-06-02 Thread Stéphane ERARD
Hi list,

I'm using ckWebService on symfony 1.4 (using svn co; not cli
plugin:install).

I have to change a method in the ckWebServiceController.class.php/
ckWebServiceController-getResultAdapter method

Here is my own :


  /**
   * Gets the result adapter for the current action, if no instance
exists, one is created.
   *
   * @return ckAbstractResultAdapter A result adapter for the current
action
   */
  public function getResultAdapter()
  {
if(is_null($this-resultAdapter))
{

  $config = sfYaml::load(sfConfig::get('sf_app_module_dir') .
DIRECTORY_SEPARATOR . $this-context-getModuleName() .
DIRECTORY_SEPARATOR . 'config' . DIRECTORY_SEPARATOR . 'module.yml');
  $result = $config[sfConfig::get('sf_environment')][$this-
context-getActionName()]['result'];

  //$result = sfConfig::get(sprintf('mod_%s_%s_result', $this-
context-getModuleName(), $this-context-getActionName()), array());
  $class  = isset($result['class']) ? $result['class'] :
'ckPropertyResultAdapter';
  $param  = isset($result['param']) ? $result['param'] : array();

  $adapter = new $class($param);

  $this-resultAdapter = $adapter instanceof
ckAbstractResultAdapter ? $adapter : new ckPropertyResultAdapter();
}

return $this-resultAdapter;
  }

And it is working.

Hope this can be integrated in a new version for sf1.4 ?
Hope I don't have made any mistake too... :-)

Cheers,

-- 
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


Re: [symfony-users] ckWebService for sf1.4

2010-06-02 Thread Stéphane
Another problem I see is this plugin doesnt take care of plugin modules.

Anyone made anything for this to work for plugin modules ?

Thank you !

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Wed, Jun 2, 2010 at 5:42 PM, Stéphane ERARD stephane.er...@gmail.comwrote:

 Hi list,

 I'm using ckWebService on symfony 1.4 (using svn co; not cli
 plugin:install).

 I have to change a method in the ckWebServiceController.class.php/
 ckWebServiceController-getResultAdapter method

 Here is my own :


  /**
   * Gets the result adapter for the current action, if no instance
 exists, one is created.
   *
   * @return ckAbstractResultAdapter A result adapter for the current
 action
   */
  public function getResultAdapter()
  {
if(is_null($this-resultAdapter))
{

  $config = sfYaml::load(sfConfig::get('sf_app_module_dir') .
 DIRECTORY_SEPARATOR . $this-context-getModuleName() .
 DIRECTORY_SEPARATOR . 'config' . DIRECTORY_SEPARATOR . 'module.yml');
  $result = $config[sfConfig::get('sf_environment')][$this-
 context-getActionName()]['result'];

  //$result = sfConfig::get(sprintf('mod_%s_%s_result', $this-
 context-getModuleName(), $this-context-getActionName()), array());
  $class  = isset($result['class']) ? $result['class'] :
 'ckPropertyResultAdapter';
  $param  = isset($result['param']) ? $result['param'] : array();

  $adapter = new $class($param);

  $this-resultAdapter = $adapter instanceof
 ckAbstractResultAdapter ? $adapter : new ckPropertyResultAdapter();
}

return $this-resultAdapter;
  }

 And it is working.

 Hope this can be integrated in a new version for sf1.4 ?
 Hope I don't have made any mistake too... :-)

 Cheers,

 --
 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


Re: [symfony-users] Нужен программис т в Москве на 1 неделю (Symphony PHP Framewo rk)

2010-05-31 Thread Stéphane
Please, english :o)


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


2010/5/31 Геоком Перово number...@gmail.com

 Приветствую!

 Нашей компании нужен программист на неделю (может чуть больше)
 подменить нашего штатного программиста.

 Есть куча разных мелочей, которые нужно доработать на сайте
 http://ts97.ru/
 и настроить синхронизацию баз с сайтом www.lk-broker.ru

 Работа в офисе на полный раб. день, район перово (Москва).

 На все выделяется 10 000р.  А если  опыт работы на  Django достаточно
 большой, можно будет переключиться на следующий проект...

 Дайте знать, если предложение Вам интересно. Андрей.

 --
 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


Re: [symfony-users] how to change text label attached to new link in embedRelation form

2010-05-27 Thread Stéphane
Hi,

$this-getWidget($uglyName)-setLabel('my smart label');

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, May 28, 2010 at 12:25 AM, Tofuwarrior p...@clearintent.co.ukwrote:

 I have successfully use embedRelation to embed a relation in my form
 BUT the new link at the bottom has a label next to it that says
 NewUglyLongPropelObjectName  .

 How can I change this, I haven't set any new link anywhere so I'm not
 sure how to change this.

 Is it a widget set somewhere.

 Anyone?
 Deadline tonight, really rather not have this ugly mess spoiling
 things.

 embedRelation - Very cool!

 --
 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


Re: [symfony-users] best practice to save nb_comments

2010-05-25 Thread Stéphane
Hi,

No, think about listeners on Doctrine_Record and the postInsert hook.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, May 25, 2010 at 2:34 AM, comb sa...@gmx.net wrote:

 Hi!

 I have a Commentable behavior.
 Now I want to add a new column nb_comments to a Record with this
 behavior for performance reasons.

public function setTableDefinition() {
$this-hasColumn('nb_comments', 'integer', null,
 array('default' =
 0));
 ...

 But where is the best place to increment/decrement the nb_comments
 attribute? in the Comment-Module-Actions during the processForm/
 executeDelete is a little dirty, isn't it??

 --
 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


Re: [symfony-users] Re: How to retrieve the value of a field in configure() function

2010-05-22 Thread Stéphane
Wouldn't it be good too to validate them as not required then use an
sfValidatorCallback using $this(form)-setPostValidator(new
sfValidatorCallback()) ? This is used when one field validation depends on
some others.

Another way is to make the $required of your validators being options, using
$this-getOption(). Then where you create your instance you'll give right
options, and in the configure method you'll call a configureValidators
method which will act according to the options.
The problem will be about message errors.

I've done this to control which fields to show or not according to the
action, then I added some other configuration options (hide, etc). This
needs to somehow overload the configuration class of the admin-gens (I have
used doctrine one).
Or you can add method for state methods to your form class (and why not, in
it, hardcoding the option array given to the form.

Another way is to make the form maleable : in fact it is, you can call
$form-getValidator('my_required_widget')-setOption('required', false).
Then after instanciation, just call a class (which will contains all the
different configuration strategies possible-needed for this particular form)
static method which will handle the correct setting of the form.

There are plenty ways of doing so, to say it clearly :-)


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, May 22, 2010 at 5:36 PM, Johannes 
johannes.schmitt...@googlemail.com wrote:

 You need to exchange the validator schema of the form with your own
 validator schema class, and overwrite the preClean() method there.

 This is the only way to ensure that your form behaves the same whether
 it is used standalone or embedded elsewhere.

 Johannes

 On 21 Mai, 15:04, kadia kadial...@gmail.com wrote:
  I want to set a validor for a field on configure (), but the field can
  be required or not, it depends on the value of another field. Now I
  need set the condition following the value of that filed but I can
  find the good function, for having that value.
 
  I have to use it one configure() function.
 
  class FormuleForm extends BaseFormuleForm
  {
 
public function configure()
{
 
  ///  I have tried this, but it's not ok
 
if ($this-getValue('idsitecompactage')==2)
{$this-validatorSchema['commentaire']=new
  sfValidatorString(array('required' = true));
}
  ***
 
  }
  }
 
  --
  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 athttp://
 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


-- 
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


Re: [symfony-users] MVC vs module in Symfony

2010-05-18 Thread Stéphane
Hi,

From what I understand :

Model: Doctrine/Propel
View: Partials, templates (sfPHPView engine)
Controler: Action, Component

Modules are containers for actions, to group them somehow.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Tue, May 18, 2010 at 8:33 AM, Benoit Montuelle 
benoit.montue...@gmail.com wrote:

 Hi,

 Sorry I've never seen such a diagram.
 There is an UML picture of symfony imternals.

 A module covers view and controller tiers in mvc, and yes you can define
 filters and forms on each module, or overload the generated ones, just pût
 them in module/lib folders.

 To disable filters in an admin module you should look at generator.yml file
 documentation.

 Regards



 Le 18 mai 2010 à 01:50, Dennis gear...@sbcglobal.net a écrit :


  So anyone seen a definitive pictogram that shows all the elements of
 Symfony in relation to an MVC implementation? Something like a Venn
 diagram showing which element of symfony belongs in which part of pure
 MVC?

 I'm kind of wondering  most of all:
What role in MVC does a module perform?
Is is possible to disable/enable/add filters per module?

 TIA, Dennis

 --
 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


 Hi,

 Sorry I've never seen



 Le 18 mai 2010 à 01:50, Dennis gear...@sbcglobal.net a écrit :


  So anyone seen a definitive pictogram that shows all the elements of
 Symfony in relation to an MVC implementation? Something like a Venn
 diagram showing which element of symfony belongs in which part of pure
 MVC?

 I'm kind of wondering  most of all:
What role in MVC does a module perform?
Is is possible to disable/enable/add filters per module?

 TIA, Dennis

 --
 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.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


Re: [symfony-users] plz unsubscribe me from this group

2010-05-15 Thread Stéphane
To unsubscribe from this group, send email to
symfony-users+unsubscr...@googlegroups.comsymfony-users%2bunsubscr...@googlegroups.com



Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Sat, May 15, 2010 at 2:56 PM, Vikram Patel viki2m...@yahoo.com wrote:

 plz unsubscribe me from this group .

  --
 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


Re: [symfony-users] Re: sf/doctrine performance

2010-05-07 Thread Stéphane
And do || processing on multiple servers if possible/needed.

Use stdin to retrieve to-compute xml parts for each segment. So you can pipe
your commands.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Fri, May 7, 2010 at 4:34 AM, ken marfillas...@gmail.com wrote:

 Or you can add optional argument offset and limit for your task. This
 however is not for sql but for the xml. The idea is to process only a
 part of the xml for a given run. This will allow you to run the task
 in many segments.

 On May 7, 10:17 am, dan dan.wil...@gmail.com wrote:
  Hmm - I don't think this is going to work.
 
  I ran the script and it got killed after 51 of 700+ games, with 21000
  TyperefGame relationship records. It was consuming over 1.5GB of RAM.
  I understand PDO is a memory hog, so may have to refactor using
  mysql_query() etc. :(
 
  Any ideas are more than welcome :)
 
  Cheers,
 
  Dan.
 
  On May 7, 8:31 am, dan dan.wil...@gmail.com wrote:
 
 
 
 
 
   Hi all,
 
   I have a large XML file (140+MB) which I'm parsing with an sf Task.
 
   It's a complicated structure, and contains some interesting
   relationships.
 
   The approach I'm using is to open the XML file with XMLReader, and
   when I find a node of interest, convert that node to a SimpleXML
   object, and then build my sf Records.
 
   Without going into too much detail, I have a few record types that are
   of primary interest; Game, Handset, Category.
 
   Relating Games to Categories is easy, however Games and Handsets are
   related via a Typeref, i.e. Games are published for certain Typerefs,
   while each handset supports one or two different Typerefs.
 
   So I've also created tables for Typeref, TyperefGame and
   TyperefHandset in order to manage the relationships.
 
   Here's my real question:
 
   As my Task parses each Game, it looks up each of the Typerefs (approx
   450 per game) associated with the game and creates the TyperefGame
   relationship record. With 700+ games, that's about 315000 records.
 
   As you can imagine, this takes some time, and I'm looking for every
   opportunity to speed it up.
 
   My first attempt was simply to create a new Doctrine Record for each
   Typeref, setting the necessary attributes and then saving it. This was
   slow. (around 450 save()s per game)
 
   My second attempt was to create a Typeref Doctrine Collection for each
   game, and then do one save() on the collection once all Typerefs had
   been parsed. I expected this to be faster that my first method, but if
   anything, it appears slower.
 
   What should my third attempt be?
 
   Should I be building a single large raw SQL statement for each game-
   load of Typerefs?
 
   Is there an even better way to approach this whole Task?
 
   Your thoughts and advice would be greatly appreciated.
 
   Cheers,
 
   Dan.
 
   --
   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 athttp://
 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 athttp://
 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


-- 
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


Re: [symfony-users] How I can share some functionality between models

2010-05-06 Thread Stéphane
Hi,

About models, it is a Doctrine concern I believe.

Take a look at Doctrine_Template.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Thu, May 6, 2010 at 11:41 AM, Alexandru-Emil Lupu
gang.al...@gmail.comwrote:

 ??? what exactly do you mean ?


 On Thu, May 6, 2010 at 11:40 AM, amit amit@gmail.com wrote:
  How I can share some functionality between models?
 
  --
  Amit
 
  --
  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
 



 --
 Have a nice day!

 Alecs
 Certified ScrumMaster

 P.S. If you are on a list, please don't contact me privatelly, unless
 i have allowed to. Further messages will be ignored.

 There are no cannibals alive! I have ate the last one yesterday ...
 I am on web:  http://www.alecslupu.ro/
 I am on twitter: http://twitter.com/alecslupu
 I am on linkedIn: http://www.linkedin.com/in/alecslupu
 Tel: (+4)0722 621 280

 --
 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] ckWebServicePlugin

2010-05-03 Thread Stéphane ERARD
Hi list,

I'd like to know if this plugin (ckWebServicePlugin) is usable for
sf1.4.4 and up ?
I'm trying to test it but can't make it working. Perhaps I've done
something wrong or doc is out of date according to sf1.3-1.4 changes.
Don't know.

Thanks !

-- 
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


Re: [symfony-users] Overriding Queries - Doctrine

2010-05-02 Thread Stéphane
Hi,

Look at DQL pre hooks. Looks like you want to add a preDqlSelect in a
listener. Look at the Doctrine documentation about this.

Cheers,


Before Printing, Think about Your Environmental Responsibility!
Avant d'Imprimer, Pensez à Votre Responsabilitée Environnementale!


On Mon, May 3, 2010 at 12:42 AM, Ozzy oye...@gmail.com wrote:

 Hello,
 I have a table which has the user list. I have an active column in
 the table which indicates the status of that user.

 I want to add all queries in my symfony project -andWhere('u.active =
 1'), in order to only list, count, etc. only active users. I do not
 want to do this by hand since I have lots of different actions using
 queries in the project.

 Can I do this by overriding a function in the UserTable model? If so,
 which function should I override and how?

 Thanks.

 --
 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


  1   2   3   >