How does Symfony2 handle inheritance ?
On May 4, 5:35 pm, Donald chekot...@gmail.com wrote:
Yes you can. The actual hiding would be carried out on the client
side with Javascript, by setting the display css attribute of the
field to none.
You would also need to implement proper validation in
Anyone !? :)
Added some comments to my code bellow .
On Wed, May 4, 2011 at 5:04 PM, seven seven sapt...@gmail.com wrote:
Hi everyone,
Let me be short. I have a class MainMenu and I want to override the
*renderLink()
*from MenuItem in *MyCustomMenuItem *class, but something is not working
2011/5/5 Matt Robinson m...@lazycat.org:
On 4 May 2011, at 23:57, Michał Piotrowski wrote:
2011/5/4 Marco Pivetta ocram...@gmail.com:
SQL is way faster than PHP processing. I would really go for a filtered
join. That's what SQL is there for :)
Just be sure to filter by index and to return a
On Thu, May 5, 2011 at 9:41 AM, Manu emmanuel.parf...@gmail.com wrote:
How does Symfony2 handle inheritance ?
This also interests me, what's the best way to make a form with
inheritance having multiple possibilities for data_class?
--
Vincent
--
If you want to report a vulnerability issue on
Awesome, thanks! Maybe possible to make a shortcut for this? Like: {{
form.name.value }}
On Wed, May 4, 2011 at 9:38 PM, Bernhard Schussek bschus...@gmail.com wrote:
Hi,
Try form.vars.value.
Bernhard
--
If you want to report a vulnerability issue on symfony, please send it to
security
2011/5/5 Don Pinkster d...@pinkster.eu:
Awesome, thanks! Maybe possible to make a shortcut for this? Like: {{
form.name.value }}
No, this would break consistency. Better documentation should solve
this problem.
Bernhard
--
If you want to report a vulnerability issue on symfony, please send
2011/5/5 Vincent Lechemin vincent.leche...@gmail.com:
On Thu, May 5, 2011 at 9:41 AM, Manu emmanuel.parf...@gmail.com wrote:
How does Symfony2 handle inheritance ?
This also interests me, what's the best way to make a form with
inheritance having multiple possibilities for data_class?
Do you
Thanks,
This DID work until I needed to have a connection per environment. It
now tries to use the dsn info from the prod: section in databases.yml,
even when running via frontend_dev.php. I have cleared caches etc.
Any ideas?
On Apr 15, 10:25 pm, ftassi tassi.france...@gmail.com wrote:
Does
On 5/5/11 11:29 AM, Bernhard Schussek wrote:
2011/5/5 Don Pinksterd...@pinkster.eu:
Awesome, thanks! Maybe possible to make a shortcut for this? Like: {{
form.name.value }}
No, this would break consistency. Better documentation should solve
this problem.
Can someone create a ticket so that
You put all the common stuff in a plugin, that is the proper way to reuse
components across different apps.
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
I'm with Matt on this. One thing we have done with one of our apps that
needs to build reports for example, is we created a summary table to reduce
the amount of data to extract from the database and therefore reduce the
amount of data to process as well. If you can think of ways to aggregate
many
The ticket is created: https://github.com/symfony/symfony/issues/784
On Thu, May 5, 2011 at 12:33 PM, Fabien Potencier
fabien.potenc...@symfony-project.com wrote:
On 5/5/11 11:29 AM, Bernhard Schussek wrote:
2011/5/5 Don Pinksterd...@pinkster.eu:
Awesome, thanks! Maybe possible to make a
Hi there,
I am receiving this error when I am trying to submit data from a contact
form :
*Fatal error*: Call to undefined function
Symfony\Component\Form\Extension\Core\DataTransformer\intl_is_failure() in*
On Wed, May 4, 2011 at 2:41 PM, Daniel Gomes daniel.go...@reset.pt wrote:
I'm using compass in the AsseticBundle for the CSS's. My question is, in
development it creates a temporary css file but in production it doesn't?
Is there other configuration that i need to do?
Thanks,
Try this:
It seems like you dont have the PHP intl extension installed.
http://nl.php.net/intl
On Thu, May 5, 2011 at 1:52 PM, seven seven sapt...@gmail.com wrote:
Hi there,
I am receiving this error when I am trying to submit data from a contact
form :
Fatal error: Call to undefined function
Hello sf users !
I'am an sf 1.4 user. I have heard what functional tests in sf2 will be/
are differents/deleted.
So, How will be functionals test in sf2 ?
Thank you and sorry for my french-english ^^
--
If you want to report a vulnerability issue on symfony, please send it to
security at
I'm in the same case of you, I would like to upgrade from 1.4.4 to
1.4.11 but I have some problem of generate config file in 1.4.11.
the routing file is empty and there is also csfr_token problem appear.
On May 4, 10:22 pm, Hesky Ji hji...@gmail.com wrote:
Could anyone please share some
Hi Bernard,
When I call form_errors(item.myfield) on an item within a collection
it doesn't display the validation error message that is associated
with that item. Instead the error messages display at the form
level. So in my example snippets the validation messages for fields
that belong to
This problem is not caused by old PHP version. With phpinfo() I see
that they are running PHP 5.3.6. It is something else.. But still
don't know what :(
On May 4, 10:45 pm, Greg Militello g...@thinkof.net wrote:
It would be impossible without rewriting it. Symfony2 relies on the
wonderful
Hi,
thanks for your answer.
i was already using security_check as action for my login form, no
problem here.
There is not the misunderstood between security_check and login_check
you that you mentionned. i just used the route name instead of the
route pattern to describe it to you ;-)
after all,
Is there any way to apply post validator only when setvalidator has no
validation to show.
I got this message fasd is not a number. Upper Slab Required . where
upper slab required is set through post validation i am doing this
because this is required depend on some conditon like percent or flat.
Hello everyone and sorry for my English.
I'm starting to learn symfony and I followed the first tutorial jobeet
ilo.
I'm working on XP, the project has created and I have also the page
Symfony Project Created,
but I do not find images and main.css is empty.
What did I do wrong?
thank you very
$this-setValidators(array(
'charge_type'= new
sfValidatorChoice(array('choices' = array(0 = 'percent', 1 =
'flat'), 'required' = false)),
'upper_slab' = new
sfValidatorNumber(array('min'=0,'required' = false)),
));
When there are errors in form validation, only field errors are
rendered (error message beside each field). Form errors
{{ form_errors(form) }} renders nothing for me.
I expected there all errors collected from all fields to be rendered.
Am I missing something?
--
If you want to report a
This problem is not caused by old PHP version. With phpinfo() I see
that they are running PHP 5.3.6. It is something else.. But still
don't know what :(
On May 4, 10:45 pm, Greg Militello g...@thinkof.net wrote:
It would be impossible without rewriting it. Symfony2 relies on the
wonderful
Hi,
I followed Symfony book and got the error: You have requested a non-existent
service registry
My code:
public function indexAction()
{
$em = $this-get('registry')-getEntityManager();
// ...
}
http://symfony.com/doc/2.0/book/doctrine/orm.html
# Doctrine Configuration
doctrine:
Le 05/05/2011 14:06, Leo Jokinen a écrit :
Hi,
I followed Symfony book and got the error: You have requested a non-existent service
registry
My code:
public function indexAction()
{
$em = $this-get('registry')-getEntityManager();
// ...
}
No , I don't have it . Isn't there another option , without the intl
extension ?
On Thu, May 5, 2011 at 3:03 PM, Don Pinkster d...@pinkster.eu wrote:
It seems like you dont have the PHP intl extension installed.
http://nl.php.net/intl
On Thu, May 5, 2011 at 1:52 PM, seven seven
I have just changed the type of one of the item fields to money and
the validation errors being thrown by
NumberToLocalizedStringTransformer are being rendered by
{{ form_errors( item.price ) }}. So it's the validation errors that
are on the POPO which are being rendered at the global form level.
Perhaps try using strlen() function instead of empty() function and see if
that makes a difference.
On Thu, May 5, 2011 at 7:27 AM, Raju yadavrajesh25j...@gmail.com wrote:
$this-setValidators(array(
'charge_type'= new
sfValidatorChoice(array('choices' = array(0 =
Le 05/05/2011 14:06, Leo Jokinen a écrit :
Hi,
I followed Symfony book and got the error: You have requested a non-
existent service registry
My code:
public function indexAction()
{
$em = $this-get('registry')-getEntityManager();
// ...
}
If you were on Linux I'd tell you to make a symlink to the correct location
for the symfony css and images but to be honest you don't really need that
css and images. Your own project css and images should sit in the web
directory and display fine within the project itself so just continue with
As far as I know, it's not possible to have multiple values for
data_class.
You would need a different FormType for each of the subclasses. I
would suggest having the user pick which type of thing they want to
create first, then displaying the correct form based on that choice.
Trying to have a
I assume you are on symfony 1? If so, put your form classes inside the
project_root/lib directory not the apps/app_name/lib directory and you can
then use it across apps.
On Thu, May 5, 2011 at 1:02 AM, OnDistantShores cameron.r...@gmail.comwrote:
Here's my scenario, I'm not sure what the best
You'll want to read the Doctrine documentation for info on
inheritance:
http://www.doctrine-project.org/docs/orm/2.0/en/reference/inheritance-mapping.html
On May 5, 2:41 am, Manu emmanuel.parf...@gmail.com wrote:
How does Symfony2 handle inheritance ?
On May 4, 5:35 pm, Donald
I think we have tracked down the issue to the DelegatingValidator.
The ConstrainViolation has a propertyPath of 'children[items]
[1].data.priceImmediate'
But none of the mappings created by the DelegatingValidator match this
path...
I will create a small bundle that replicates the problem.
On
Hi,
Hoped there was a method to do this within Form class !
Thanks for the solution, it works!
bye
On 05/05/2011 07:01, danielholmes wrote:
I would suggest trying something like this:
$request = $this-get('request');
if ($request-getMethod() === 'POST')
{
if
Hi,
How to post render a view with more than one form to show ?
I 'm running in trouble to do so because sf2 frameworks does perfom form
validation upon all binded forms.
Where doing a post render of my view bring me to bind all forms.
And so on to validate form's i don't want to, because
I'm not sure I understand. But from what I read it sounds like you don't
need to bind.
If you're just rendering a view, there should be nothing to bind at that
point. You only want to bind once data is submitted by the client.
On Thu, May 5, 2011 at 7:56 AM, maboiteaspam
Le 05/05/2011 14:34, Leo Jokinen a écrit :
That didn't work either.
This works in my controller:
$em = $this-get('doctrine.orm.entity_manager');
These not:
$em = $this-get('registry')-getEntityManager();
$em = $this-get('doctrine')-getEntityManager();
$em =
Thanks for your response.
I have my form component in libs (this was part of the generated
code). But the actual form display logic is part of the _form.php
partial, which is in the layouts directory, which is obviously
specific to a module. How can this be shared from the libs directory?
On May
Hi all,
I have two problems and I didn't find any solution reading
documentation, forums and googling.
I'm using Symfony2 Beta1. I have a page with a form that sends the
request to a Payment Service Provider (PSP).
The PSP accepts only HTTP POST request.
I want to create a controller action
Yep, Symfony 1 :-)
On May 5, 11:27 pm, OnDistantShores cameron.r...@gmail.com wrote:
Thanks for your response.
I have my form component in libs (this was part of the generated
code). But the actual form display logic is part of the _form.php
partial, which is in the layouts directory, which
On 5/5/11 2:34 PM, Leo Jokinen wrote:
Le 05/05/2011 14:06, Leo Jokinen a écrit :
Hi,
I followed Symfony book and got the error: You have requested a non-
existent service registry
The registry is only available as of beta2, which is to be released.
Fabien
My code:
public function
On Thu, May 5, 2011 at 6:30 AM, Laurus laurusgroup@gmail.com wrote:
This problem is not caused by old PHP version. With phpinfo() I see
that they are running PHP 5.3.6. It is something else.. But still
don't know what :(
Weird, everything I can find on their site suggests that the latest
Hi Bernhard,
Thank you so much for your reply. Everything works perfectly. There
was only one thing that needed to be changed. The data in the
preBind callback was an associative array instead of a ContactInfo
entity.
Thanks again, I struggled with this form component for a couple of
days but
Hi,
Im building a REST API for my application, and what i want to do is
use the form component to validate the input from the users..
But the problem is:
If i have a form class, really basic example:
public function buildForm(FormBuilder $builder, array $options))
{
-Original Message-
From: symfony-users@googlegroups.com [mailto:symfony-
us...@googlegroups.com] On Behalf Of Fabien Potencier
Sent: 5. toukokuuta 2011 16:34
To: symfony-users@googlegroups.com
Subject: Re: [symfony-users] Doctrine ORM: Non-existent service
registry
On 5/5/11 2:34
Why is this complicated?
As long as the FormType has a getName() method that returns register, the
Form will properly bind to the data when you call bindRequest().
On Thu, May 5, 2011 at 9:03 AM, Michael Holm ho...@hollo.dk wrote:
Hi,
Im building a REST API for my application, and what i
A redirect by it's very nature cannot send any POST data. It's not a
limitation of Symfony, but the HTTP protocol itself.
You have two ways to accomplish this:
1. Server side: Have the controller make the POST request, get the response,
and then relay that to the client.
2. Client side: Have a
i have a cms handling multiple domains.
I am not able to test it because when i create the 'login' test it
should find the domain which is requested, and then do stuff based
on the domain name,and the user passed.
The problem seems to be that it's not able to find the domain.
Is there a way to
You might also want to look into HTTP Response Code 307, but depending on
your implementation, and the Browser's you intend to support, it may not
work consistently.
On Thu, May 5, 2011 at 9:13 AM, Donald Tyler chekot...@gmail.com wrote:
A redirect by it's very nature cannot send any POST data.
Hi,
Thanks a lot for the quick reply.. but, its just my api, it would be
nice that i can expect the data:
curl http://localhost/rest/add/user -demail_address=ho...@hollo.dk
instead of:
curl http://localhost/rest/add/user -dregister[email_address]=ho...@hollo.dk
i have the same problem when i
It's possible to have anonymous forms, or at least it was before the Form
refactoring in Beta1. I never used them myself, but maybe that'll give you a
clue of where to look.
On Thu, May 5, 2011 at 9:15 AM, Michael Holm ho...@hollo.dk wrote:
Hi,
Thanks a lot for the quick reply.. but, its just
Fabrizio, I currently facing the same problem. How did you manage to solve
it (if it is solved)?
--
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
I noticed that after the Forms refactor in Beta1, that the code in
Form::bindRequest() gives the impression that it should now support PUT
data. But it still doesn't function correctly.
Doing a PUT with Symfony's test framework works correctly (which is even did
before the refactor), but doing a
Hi,
Doctrine2 has a cache system. But does Symfony2 use it?
I'm using FOS\UserBundle and on the page /user/{username}, if I'm logged
into test user and want to see /user/test, then 2 requests are executed.
And these two requests are exactly the same, namely something like
I am using Doctrine with SF2 and APC. I know that, in my case, the
class metadata is cached in the user cache. The class files
themselves would probably appear in the system cache. I found this by
looking at apc.php (if you're not sure about this look at the manual
on php.net)
To enable
Hi Donald,
Thank you very much for the help with the name at least.. i have
searched all that i could on google, and in the form source for
anonymous form, but i dont see it anywhere..
i think that i have tried everything that i can even think of..
i have seen that also the userbundle make the
Just create a plugin (I usually call it AppSharedPlugin or so), put
a module with your template inside and enable it in whatever apps you
want to share it in.
Daniel
On May 5, 6:30 am, OnDistantShores cameron.r...@gmail.com wrote:
Yep, Symfony 1 :-)
On May 5, 11:27 pm, OnDistantShores
for now I'm doing that too, multiple forms with different actions and
javascript to hide, but I was wondering if there was another solution
--
Vincent
--
If you want to report a vulnerability issue on symfony, please send it to
security at symfony-project.com
You received this message
to do that I redefined the template of the choice list
--
Vincent
--
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,
Opened a pull requests with a fix for this:
https://github.com/symfony/symfony/pull/793
On Thu, May 5, 2011 at 10:02 AM, Donald Tyler chekot...@gmail.com wrote:
I noticed that after the Forms refactor in Beta1, that the code in
Form::bindRequest() gives the impression that it should now
I'm using array caching for the moment. Shouldn't it work even with the
array driver for the cache? As it's in the same http request, array caching
must persist data from the first SQL request until the second one. But it
doesn't.
--
If you want to report a vulnerability issue on symfony,
Nobody ?
Don't understand why we can't manage the pattern for a date case field. The
only solution I see it to modify : DateTimeToLocalizedStringTransformer so
we can pass a pattern which will be used in getIntlDateFormatter...then
modify the DateType extension so it pass the pattern option to
All I can say is that I'd be interested in this issue too.. (haven't figured
out out either)..
Especially in case of i18n when other languages have a different formatting..
--
If you want to report a vulnerability issue on symfony, please send it to
security at symfony-project.com
You
Oh so I'd put the whole module in the plugin then? Do I then get the
chance to then override it within each app? Because otherwise I
wouldn't be able to make one editable and one create-only...
On May 6, 4:45 am, Richtermeister nex...@gmail.com wrote:
Just create a plugin (I usually call it
From the Doctrine documentation (21. Caching)
We also provide an ArrayCache driver which stores the data in a PHP
array. Obviously, the cache does not live between requests but this is
useful for testing in a development environment.
On May 5, 2:42 pm, winzou alexandre.ba...@gmail.com wrote:
I end up manually copying the new lib/vender folder. Also because I have
moved the lib/vendor/symfony/data/web folder to web/sf, I have to do it
again. But I'd assume there should be a proper way doing it?
--
If you want to report a vulnerability issue on symfony, please send it to
security
Exception: DateTimeZone::__construct() [datetimezone.--construct]:
Unknown or bad timezone (1024) in vendor/symfony/src/Symfony/Component/
Locale/Stub/StubIntlDateFormatter.php
Any idea how to solve this?
I have
date.timezone = Europe/Berlin
in php.ini
?
--
If you want to report a
I'm porting a routing component from sf1 which requires db access. I'm
having issues retrieving an entity manager instance from the generator
and matcher classes. Symfony seems to be like this by design, which
makes it very hard to extend some of the core features in any serious
way.
Is there a
Hi,
I am trying to read the contents of a public directory from my Model.
Currently I am doing this:
public function getFiles()
{
$dir = dir(__DIR__ . '/../../../../web/assets/');
( ... )
return $files;
}
... but that's pretty ugly.
There myst be a better way to do this - for
I have a similar problem in the implementation of a user provider.
The only solution I found is this hack.
Do you know any more right solution?
On Apr 27, 5:34 pm, A A kaupa...@gmail.com wrote:
@ seems to be a kludge :)
2011/4/27 Louardi Abdeltif louardi.abdel...@yahoo.fr
I
I have a similar problem in the implementation of a user provider.
The only solution I found is this hack.
return @serialize(array($this-user, $this-authenticated, $this-
roles, $this-attributes));
Do you know any more right solution?
On Apr 27, 5:34 pm, A A kaupa...@gmail.com wrote:
@ seems
ok thanks a lot Gareth
I thought maybe it was not successful installation.
I continued to read the tutorial and just now I realize they were
wrong slashes in the alias file httpd-vhosts.conf.
thank you very much
Joseph
On 5 Mag, 14:38, Gareth McCumskey gmccums...@gmail.com wrote:
If you
hello,
how can i remove my email from this group.
please, i receive all your email it's boring.
regards.
Mamadou Aliou Bobo Diallo
De : maboiteaspam maboiteas...@wanadoo.fr
À : symfony-users@googlegroups.com
Envoyé le : Jeu 5 mai 2011, 15h 01min 50s
Objet :
I assume you're using sf1. Use `sfConfig::get(sf_web_dir)` to get
the webroot directory.
On Thu, May 5, 2011 at 20:43, theinterned ned...@gmail.com wrote:
Hi,
I am trying to read the contents of a public directory from my Model.
Currently I am doing this:
public function getFiles()
{
Hi,
I try to use a custom validator, but i didn't found a way :)
First, i use xml for validation and I'm not sure how to add properly a
namespace in the config file.
I naively tried to do the same as for annotations or yml drivers:
validation:
enabled: true
annotations:
Le 05/05/2011 23:07, dbenjamin a écrit :
Hi,
I try to use a custom validator, but i didn't found a way :)
First, i use xml for validation and I'm not sure how to add properly a
namespace in the config file.
I naively tried to do the same as for annotations or yml drivers:
validation:
@roger
The ArrayCache will not store data from one request to another
request. It should, however, store data for a single request. Two
identical SQL requests that are cached should result in 1 query with
ArrayCache on.
@winzou
FOS/Userbundle is not symfony - it's an independently maintained
There is a Pull Request waiting to be merged that resolve our problem. I had
the same problem and applying this patch to my Symfony library did the
trick. You can check it out here:
https://github.com/symfony/symfony/pull/694. The problem right now is that
there is an option for the pattern
You can take a look at here : https://github.com/kriswallsmith/assetic
Grtz
--
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
82 matches
Mail list logo