Re: [symfony-devs] [Symfony2] About the _view variable in Twig templates

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 22:38, Fabien Potencier wrote: > Hi all, > > Now that Twig supports global variables and functions, I will rework the > TwigBundle (http://www.twig-project.org/doc/advanced.html). > > Global Variables > > > One thing I will add is global variables for common

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 22:04, Lukas Kahwe Smith wrote: > > On 19.12.2010, at 21:15, Bulat Shakirzyanov wrote: > >> err, nevermind:) >> I misread your reply. >> I dunno about that case, but it seems weird, >> why would you create a parameter that is referencing another parameter, >> I don't think its

[symfony-devs] [Symfony2] About the _view variable in Twig templates

2010-12-19 Thread Fabien Potencier
Hi all, Now that Twig supports global variables and functions, I will rework the TwigBundle (http://www.twig-project.org/doc/advanced.html). Global Variables One thing I will add is global variables for common things like the request and the user (like symfony1 has). The q

Re: [symfony-devs] [Symfony2] how to negate ifrole in twig?

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 22:12, Fabien Potencier wrote: > > On 12/14/10 2:49 PM, Lukas Kahwe Smith wrote: >> >> On 12.12.2010, at 18:48, Jordi Boggiano wrote: >> >>> On Thu, Dec 9, 2010 at 2:40 PM, Fabien Potencier >>> wrote: > this sounds incredibly unpractical to me. maybe a good tutorial >>>

Re: [symfony-devs] [Symfony2] how to negate ifrole in twig?

2010-12-19 Thread Fabien Potencier
On 12/14/10 2:49 PM, Lukas Kahwe Smith wrote: On 12.12.2010, at 18:48, Jordi Boggiano wrote: On Thu, Dec 9, 2010 at 2:40 PM, Fabien Potencier wrote: this sounds incredibly unpractical to me. maybe a good tutorial on how to do this could make this seem like of a burden. but i fail to see th

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 21:15, Bulat Shakirzyanov wrote: > err, nevermind:) > I misread your reply. > I dunno about that case, but it seems weird, > why would you create a parameter that is referencing another parameter, > I don't think its allowed by design and for good reasons. i am pretty sure its

Re: [symfony-devs] [Symfony2] ParamConverter

2010-12-19 Thread Fabien Potencier
On 12/19/10 7:23 PM, Henrik Bjornskov wrote: I have just taken a look at documentation for FrameworkExtraBundle and it have a feature called ParamConverter that listens to core.controller and converts Controller Action parameters that are typecast

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Bulat Shakirzyanov
err, nevermind:) I misread your reply. I dunno about that case, but it seems weird, why would you create a parameter that is referencing another parameter, I don't think its allowed by design and for good reasons. On Sun, Dec 19, 2010 at 3:14 PM, Bulat Shakirzyanov wrote: > Lukas, > > > https://g

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Bulat Shakirzyanov
Lukas, https://github.com/fabpot/symfony/blob/master/src/Symfony/Component/DependencyInjection/ParameterBag/ParameterBag.php#L123 On Sun, Dec 19, 2010 at 2:24 PM, Lukas Kahwe Smith wrote: > > On 19.12.2010, at 20:17, Bulat Shakirzyanov wrote: > > > Lukas, > > > > $this->parameterBag->resolveValu

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 20:17, Bulat Shakirzyanov wrote: > Lukas, > > $this->parameterBag->resolveValue($definition->getFile()); > > the resolveValue function is recursive. where is the recursion when I call $this->parameterBag->resolveValue('%swiftmailer.init_file%'); ? public function resolv

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Bulat Shakirzyanov
Lukas, $this->parameterBag->resolveValue($definition->getFile()); the resolveValue function is recursive. $this->parameterBag->resolveValue($this->parameterBag->resolveValue($definition->getFile())); On Sun, Dec 19, 2010 at 2:06 PM, Lukas Kahwe Smith wrote: > Ahoi, > > So the following patch f

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
Ahoi, So the following patch fixes the issue. diff --git a/src/Symfony/Component/DependencyInjection/ContainerBuilder.php b/src/Symfony/Component/DependencyInjection/ContainerBuilder.php index a7d9013..fd8f354 100644 --- a/src/Symfony/Component/DependencyInjection/ContainerBuilder.php +++ b/src/

[symfony-devs] [Symfony2] ParamConverter

2010-12-19 Thread Henrik Bjornskov
I have just taken a look at documentation for FrameworkExtraBundle and it have a feature called ParamConverter that listens to core.controller and converts Controller Action parameters that are typecasted into a instance of that object which is pr

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 16:36, Lukas Kahwe Smith wrote: > Hi, > > I am just using interface injection for the first time. But this causes: > ( ! ) Fatal error: Uncaught exception 'ReflectionException' with message > 'Class Swift_Transport_SpoolTransport does not exist' in > /Users/lsmith/htdocs/liip

Re: [symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
On 19.12.2010, at 16:36, Lukas Kahwe Smith wrote: > I tried to fix things with: > http://pastie.org/1389934 seems like pastie is down atm: diff --git a/src/Symfony/Component/DependencyInjection/ContainerBuilder.php b/src/Symfony/Component/DependencyInjection/ContainerBuilder.php index a7d9013

[symfony-devs] [Symfony2] interface injection failing for services that load files

2010-12-19 Thread Lukas Kahwe Smith
Hi, I am just using interface injection for the first time. But this causes: ( ! ) Fatal error: Uncaught exception 'ReflectionException' with message 'Class Swift_Transport_SpoolTransport does not exist' in /Users/lsmith/htdocs/liip/foo/src/vendor/symfony/src/Symfony/Component/DependencyInjectio

Re: [symfony-devs] [Symfony2] Form PropertyPath allow ArrayCollection

2010-12-19 Thread gordonslondon
that's was fixed, but since yesterday i still have this issue, here's my property path: *object*(*Symfony\Component\Form\PropertyPath*)[*432*] *protected* 'elements' => *array* 0 => string '0' *(length=1)* *protected* 'length' => int 1 *protected* 'isIndex' => *array*

[symfony-devs] Re: [Symfony2] adding services very cumbersome

2010-12-19 Thread Leon van der Ree
Thanks for your fast responses! Fabien and Ryan, this was the thing I missed, but was looking for. Great! Konstantin and Lukas, I agree with both of you that you should activate the functionality per application and that it isn't that much code that had to be written, but if felt redundant, since