[symfony-users] Re: Overriding Bundle Templates doesn't work

2011-03-24 Thread Pirate Bob
Hello,

Seems similarly broken in PR8, noticed this while trying to override
FrameworkBundle error templates.

On Mar 10, 8:42 am, Brocco  wrote:
> Hello,
> I confirm it doesn't work with PR7. Should we report the bug
> somewhere?
>
> On 9 mar, 11:52, Christophe COEVOET  wrote:
>
> > Le 02/03/2011 11:33, Brocco a crit :
>
> > > Hello,
> > > I'm writing a bundle for symfony2 and I would like tooverridesome of
> > > itstemplatein my app. I tried doing what's written in the doc there:
> > >http://docs.symfony-reloaded.org/master/guides/templating.html#overri...
> > > But it doesn't work.
>
> > > My bundletemplateis in MyBundle/Resources/views/Foo/bar.html.twig
> > > And I copied it and modified it in app/views/MyBundle/Foo/
> > > bar.html.twig
>
> > > But symfony uses thetemplatefrom the bundle. And if I delete it from
> > > the bundle, symfony tells me that it can't find thetemplateI'm
> > > trying to render. The code I'm using:
> > > $this->render('MyBundle:Foo:bar.html.twig'));
>
> > > Is it a bug or a problem in my configuration?
> > > thanks
>
> > This is a bug
>
> > --
> > Christophe | Stof

-- 
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: Experience in building news site in symfony?

2010-05-27 Thread Bob
I am working in the company, where we recently had the similar
situation, so we had to make a decision for building news site. Our
team experience was Drupal, and we are not quite happy about its
complexity and OOP-less.
The solution which we choice was Diem. Mostly because of ease for
development (admin interface and inline editing are on place), good
documentation, fairy large community. Media management is one of the
thing we might be able to extend Diem with help of symfony plugins (we
are not quite there yet).


On May 26, 11:49 pm, Daniel  wrote:
> Hi!
>
> I'm the CTO of a media group company in Sweden. Since almost 2 years
> we have used symfony in most of our web projects.
> Right now I'm in the position of making a decision about one of our
> biggest news web sites. Today we use one of the most known CMS tools
> in the Swedish market. It's built on .NET/C#, which give us headache
> though we have most power in the field of the LAMP stack.
>
> Since we have good experience in using symfony I'm evaluation the
> option of porting this site to a symfony based application.
>
> I'm looking for cases and knowledge from others who have been through
> similar projects before.
>
> In this process I also plan to look into the CMF:s that has been
> developed in meeting the need of easily building a nice CMS on
> symfony. It would also be appreiated to hear from experiences in using
> this tools as well. I'm thinking of using Diem, Apostrophe and Sympal
> among others.
>
> This is some questions and challenging task that I can see is needed
> to be solved efficient for the editors:
>
> 1. How to build an admin/backend from which the editors easily can
> publish articles.
> 2. Let the editors choose from a set of layouts/designs that the
> article will be published with.
> 3. Build functions to handle media, images and be able to publish
> those.
> 4. How to efficient handle image varieties. The varieties in how an
> article can be shown in category pages demand different image sizes.
>
> To achieve this I'm thinking of; A. To build everything from scratch
> on symfony. B. To build it on symfony and use one of the CMF plugins
> mentioned above. C. Build it using a more CMS-like framework like
> Drupal.
>
> Hope any of you have ideas/knwoledge/experience to share about this.
>
> 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.com
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en


[symfony-users] Re: sfAction Different In 1.4?

2010-02-25 Thread Bob
Function name should be like "executeIndex", but not just "execute".

On Feb 25, 7:07 pm, Darren884  wrote:
> I get this error:
> Fatal error: Declaration of homeAction::execute() must be compatible
> with that of sfComponent::execute() in /var/www/vhosts/blackhawk.biz/
> symfony/apps/frontend/modules/pages/actions/homeAction.class.php  on
> line 11
>
> When I use this code:
> 
> /**
>  * home action.
>  *
>  * @package    Black Hawk Tobacco
>  * @subpackage pages
>  * @author     Darren Labey
>  * @version    SVN: $Id: actions.class.php 23810 2009-11-12 11:07:44Z
> Kris.Wallsmith $
>  */
> class homeAction extends sfAction
> {
>   public function execute(sfWebRequest $request)
>   {
>   }
>
> }
>
> My action is named homeAction.class.php
>
> Am I forgetting something in 1.4? Or has this changed or somethign?
> Does anyone know?
>
> Thanks,
> Darren

-- 
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: Symfony for newspaper site

2010-01-12 Thread Bob
Right, but I need to use PHP in any way, so have to find if there is
django-in-php-world.

On Jan 11, 8:59 pm, "Fred Grott(shareme)" 
wrote:
> Django was developed with newspapers in mind, in fact the main coding
> team is still in the newspaper it business..
>
> On Jan 11, 11:20 am, Bob  wrote:
>
>
>
> > Hi all,
>
> > Collecting information about important points why Symfony can be
> > beneficial for newspapers web-sites (in comparison to Drupal6, where
> > time for hacking is large, but end-code is "not nice". I found some
> > good points here already 
> > -http://lacot.org/public/symfony/symfony-day-2009-symfony-vs-integrati...
> > , but I guess somebody has more to say).
>
> > Maybe somebody could give working examples of large, popular
> > newspapers sites built on Symfony?
>
> > All relative information is highly appreciated.
>
> > Anton.
-- 
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-us...@googlegroups.com.
To unsubscribe from this group, send email to 
symfony-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en.




[symfony-users] Re: Symfony for newspaper site

2010-01-12 Thread Bob
To my mind Wordpress (as well as Drupal6) is not a good option for my
case, because there is no control of development roadmap (who knows
what incompatible changes will bring next WP release, which fix
critical issues and provide new features?). Wordpress is still not
framework, but blogging platform and I believe it takes longer time to
develop new features (and test properly) than using framework which
aim to solve regular tasks for web-application.


On Jan 12, 1:02 am, Jake Barnes  wrote:
> > Collecting information about important points why Symfony can be
> > beneficial for newspapers web-sites (in comparison to Drupal6, where
> > time for hacking is large, but end-code is "not nice". I found some
> > good points here already 
> > -http://lacot.org/public/symfony/symfony-day-2009-symfony-vs-integrati...
> > , but I guess somebody has more to say).
>
> You can use WordPress for most newspaper sites. More and more
> journalists are resorting to newspaper-oriented WordPress themes. An
> example of a newspaper theme:
>
> http://www.darrenhoyt.com/2009/05/20/a-wordpress-theme-for-writers-an...
>
> You should prefer Symfony over WordPress only if:
>
> 1.) you will need a complex user security system with multiple levels
> and bundles (groups) of permissions
>
> or:
>
> 2.) you will have multiple types of digital content (text, images,
> video, etc) which you will need to sort and organize on a large scale
>
> On Jan 11, 12:20 pm, Bob  wrote:
>
>
>
> > Hi all,
>
> > Collecting information about important points why Symfony can be
> > beneficial for newspapers web-sites (in comparison to Drupal6, where
> > time for hacking is large, but end-code is "not nice". I found some
> > good points here already 
> > -http://lacot.org/public/symfony/symfony-day-2009-symfony-vs-integrati...
> > , but I guess somebody has more to say).
>
> > Maybe somebody could give working examples of large, popular
> > newspapers sites built on Symfony?
>
> > All relative information is highly appreciated.
>
> > Anton.
-- 
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-us...@googlegroups.com.
To unsubscribe from this group, send email to 
symfony-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en.




[symfony-users] Symfony for newspaper site

2010-01-11 Thread Bob
Hi all,

Collecting information about important points why Symfony can be
beneficial for newspapers web-sites (in comparison to Drupal6, where
time for hacking is large, but end-code is "not nice". I found some
good points here already -
http://lacot.org/public/symfony/symfony-day-2009-symfony-vs-integrating-products-xavier-lacot-clever-age.pdf
, but I guess somebody has more to say).

Maybe somebody could give working examples of large, popular
newspapers sites built on Symfony?

All relative information is highly appreciated.

Anton.
-- 
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-us...@googlegroups.com.
To unsubscribe from this group, send email to 
symfony-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en.




[symfony-users] Problem with where() in DbFinderPlugin / Doctrine.

2009-03-02 Thread Bob

Hi!

I have DbFinderPlugin on SF 1.2 with just Doctrine ORM (no mention of
Propel in code, no Propel plugins installed).

The problem begins when I have where() statement in code like this:
$this->article = DbFinder::from('BlogPost')->
leftJoin('BlogComment')->
where('Title', $this->getRequestParameter('title'))->
groupBy('BlogPost.Id')->
withColumn('COUNT(BlogComment.Id)', 'Comments')->
findOne();

The error message is:
Fatal error: Class 'Criteria' not found in /Users/Bob/Sites/
massagesession/plugins/DbFinderPlugin/lib/sfModelFinder.php on line
223
Line #223 in /DbFinderPlugin/lib/sfModelFinder.php contains Propel-
related code: $comparison = Criteria::EQUAL;

And when I remove where() from first code in above it starts works
fine.

PS: I have been using the same code with DbFinder/Propel 3 days ago,
but looks that there is a problem with DbFinder/Doctrine someWHERE() :)
--~--~-~--~~~---~--~~
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: checking for duplicate entry while validating

2009-02-19 Thread Bob

Use postvalidator in form class like this:
$this->validatorSchema->setPostValidator(
new sfValidatorAnd(
array(
new sfValidatorPropelUnique(array('model' =>
'sfGuardUser', 'column' => array('username')), array("invalid" =>
"Such %column% is already exists")),
new sfValidatorPropelUnique(array('model' =>
'sfGuardUserProfile', 'column' => array('email')), array("invalid" =>
"Such %column% is already exists"))
)
)
);


On Feb 18, 11:03 pm, Iltar  wrote:
> How can I add a validation for fields that have a unique index?
--~--~-~--~~~---~--~~
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: How to: Conditional validation?

2009-02-18 Thread Bob

The solution is found. Have to use postvalidators.

Thanks to IRC users of #symfony :)

On Feb 18, 3:35 pm, Bob  wrote:
> Hi!
>
> Sure it is rather often problem, but nevertheless no easy solution
> found for symfony 1.2.
>
> I have a register form with 10 fields and a radio button (membership
> option), when user ticks to "Pro" half of fields hide on fly (using
> jquery).
>
> The question is: How can I make a form validation of ALL fields when
> membership is set to "Pro", and validate 5 regular fields if
> membership is "Free"? I guess there probably should be smth with
> sfValidatorAnd, sfValidatorOr.
>
> Thanks.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to 
symfony-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en
-~--~~~~--~~--~--~---



[symfony-users] How to: Conditional validation?

2009-02-18 Thread Bob

Hi!

Sure it is rather often problem, but nevertheless no easy solution
found for symfony 1.2.

I have a register form with 10 fields and a radio button (membership
option), when user ticks to "Pro" half of fields hide on fly (using
jquery).

The question is: How can I make a form validation of ALL fields when
membership is set to "Pro", and validate 5 regular fields if
membership is "Free"? I guess there probably should be smth with
sfValidatorAnd, sfValidatorOr.

Thanks.
--~--~-~--~~~---~--~~
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] Repopulate radios and form fields values in view

2009-02-13 Thread Bob

Forms, symfony 1.2:

I have radiobuttons like these:
 "radio")); ?>
 "radio")); ?>

and I need the first radiobutton to be checked by default, if nothing
else defined in memberships radios, but how?

Also how can I get access (in the view!) to the fields values and get
to know which radiobutton has been checked when user submits form?
Right now after I click submit button none of radios are repopulated
(form is binded).

PS: Who knows is it better to use radiobutton_tag or input_tag("name",
'title', array("type" => "radio")) in any terms (speed, bug-free,
etc)?

--~--~-~--~~~---~--~~
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: sf1.2: sfWidgetFormPropelChoiceMany custom form output

2009-02-13 Thread Bob

It was really easy after you replied with this. Thank you!



On Feb 12, 4:49 am, jukea  wrote:
> Hi Anton,
>
> Here's how I did exactly that in three easy steps !   It's not
> super clean /optimal / configurable code,but it works.
>
> (region_list is the widget name for a 1..n relation in my model)
>
> == 1 ==
>
> I made a static method helper
>
> class espUtils
> {
>
>   static public function fourColumnsUlformatter($widget, $inputs)
>   {
>     $rows = array();
>     foreach ($inputs as $input)
>     {
>       $rows[] = ''.$input
> ['input'].chr(13).$input['label'].'';
>     }
>     return ''.implode(chr(13), $rows).'';
>   }
>
>   static public function fourColumnsTrformatter($widget, $inputs)
>   {
>     $rows = array();
>     $cnt=0;
>     foreach ($inputs as $input)
>     {
>       $cnt++;
>       $rows[] = ''.$input['input'].chr
> (13).$input['label'].'';
>       if($cnt==3)
>       {
>         $res[] = ''.implode(chr(13),$rows).'';
>         $rows=array();
>         $cnt=0;
>       }
>     }
>     if($cnt)
>     {
>       while($cnt++<3)
>         $rows[] = '';
>       $res[] = ''.implode(chr(13),$rows).'';
>     }
>     return implode(chr(13),$res);
>   }
>
>   public static function displayTrChoices($elem,$options=array())
>   {
>     echo '';
>     echo ' colspan="3">'.(!in_array('no_label',$options)?$elem->renderLabel():"").$elem->renderError();
>
>     echo '';
>     echo '';
>     echo $elem;
>   }
>
> }
>
>  2 =
>
> class VisitorContactFormRegistration extends BaseVisitorContactForm
> {
>     public function configure()
>     {
>       $formatter_tr_option = array('formatter'=>array
> ('espUtils','fourColumnsTrFormatter'));
>
>       $this->widgetSchema['regions_list']->setOption('expanded',true);
>       $this->widgetSchema['regions_list']->setOption
> ('renderer_options',$formatter_tr_option);
>
> .
>
> 3 =
>
> in the View :
>
> 
>
> I thought the espUtils::displayTrChoices pseudo-helper would make this
> a little more reusable.
>
> voilà !
>
> Julien
>
> On Feb 11, 3:36 pm, Bob  wrote:
>
> > I have a form with text fields and hundreds of checkboxes populated
> > using model "Therapy", like this:
>
> > public function configure()
> > {
> >     $this->setWidgets(array(
> >             'therapies'   => new sfWidgetFormPropelChoiceMany(array
> > ('model' => 'Therapy', 'expanded' => true))
> >     );
>
> > }
>
> > As somebody said on the forum it is a big pain in the ass to decorate
> > output of the forms, but nevertheless I have to figure out how to
> > display all checkboxes in two columns using my custom formatter.
>
> > Is there any way to split hundreds of choices into several arrays, so
> > I can make a two-column template and put values there manually?
>
> > Thanks,
> > Anton.
>
>
--~--~-~--~~~---~--~~
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] sf1.2: sfWidgetFormPropelChoiceMany custom form output

2009-02-11 Thread Bob

I have a form with text fields and hundreds of checkboxes populated
using model "Therapy", like this:

public function configure()
{
$this->setWidgets(array(
'therapies'   => new sfWidgetFormPropelChoiceMany(array
('model' => 'Therapy', 'expanded' => true))
);
}

As somebody said on the forum it is a big pain in the ass to decorate
output of the forms, but nevertheless I have to figure out how to
display all checkboxes in two columns using my custom formatter.

Is there any way to split hundreds of choices into several arrays, so
I can make a two-column template and put values there manually?

Thanks,
Anton.
--~--~-~--~~~---~--~~
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: $form->save() in two models from one form consecutively

2009-02-11 Thread Bob

Thanks! It works. :)


On Feb 9, 9:30 pm, "Yevgeniy A. Viktorov" 
wrote:
> Just try $this->form = new sfGuardUserForm(); instead, in your code.
>
> p.s.
> the sfGuardUserProfileForm will be embed automatically if exists, e.g.
> you will have username, password, password again and all fields of
> your sfGuardUserProfileForm.
>
> On Mon, 2009-02-09 at 11:58 -0800, Bob wrote:
> > Hi!
>
> > I am using sfGuardUser (with Profile) plugin for user management and
> > have a complex registration form with fields which are in two models:
> > sfGuardUser and sfGuardUserProfile.
>
> > The question is - How can I pass the user_id (which is a foreign key)
> > from sfGuardUser() before sfGuardUserProfileForm saves.
>
> > I have these lines in "userActions":
>
> >         $this->form = new sfGuardUserProfileForm();
>
> > 
>
> >         if ($form->isValid())
> >         {
> >             $user = new sfGuardUser();
> >             $user->setUsername($form->getValue('username'));
> >             $user->setPassword($this->generatePassword());
> >             $user->setIsActive(false);
> >             $user->save();
>
> >             // I guess, here should be smth like:
> >             // $profile = new sfGuardUserProfile();
> >             // $profile->setUserId($user->getId());
>
> >             $this->user = $form->save();
> >         }
>
>
--~--~-~--~~~---~--~~
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] $form->save() in two models from one form consecutively

2009-02-09 Thread Bob

Hi!

I am using sfGuardUser (with Profile) plugin for user management and
have a complex registration form with fields which are in two models:
sfGuardUser and sfGuardUserProfile.

The question is - How can I pass the user_id (which is a foreign key)
from sfGuardUser() before sfGuardUserProfileForm saves.

I have these lines in "userActions":

$this->form = new sfGuardUserProfileForm();



if ($form->isValid())
{
$user = new sfGuardUser();
$user->setUsername($form->getValue('username'));
$user->setPassword($this->generatePassword());
$user->setIsActive(false);
$user->save();

// I guess, here should be smth like:
// $profile = new sfGuardUserProfile();
// $profile->setUserId($user->getId());

$this->user = $form->save();
}

--~--~-~--~~~---~--~~
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] Messenger skins for everybody

2008-06-09 Thread bob

Messenger Plus! Live is an add-on for Windows Live Messenger that adds
tons of features and extras to the software. Extend the possibilities
of Messenger and make your experience a lot more entertaining!

For more on this subject check out this cool site www.msgpluslive.net
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en
-~--~~~~--~~--~--~---