If you use schema.yml it will be just like you write it...
sfDtPage:
actAs:
Timestampable:
columns:
.
Page:
actAs:
Timestampable:
columns:
.
First will create class sfDtPage, the second Page.
On 23 kvě, 18:36, Tofuwst will create a class sfDtPage, second
Page.ar
Using sfContext::getInstance()->set('form_signin', $this->form);
On 05/25/2010 08:08 AM, Gareth McCumskey wrote:
How did you set the variable? Was it as a session variable in an action by
using $this->getUser()->setAttribute()? Or as a value stored in a config file
like the app.yml?
On Tuesday
How did you set the variable? Was it as a session variable in an action by
using $this->getUser()->setAttribute()? Or as a value stored in a config file
like the app.yml?
On Tuesday 25 May 2010 07:03:30 Javier Garcia wrote:
> Hi,
>
> i have this code:
>
> if(sfContext::getInstance()->get('form
Hi,
i have this code:
if(sfContext::getInstance()->get('form_signin')){
//...
}
but im getting this error:
The "form_signin" object does not exist in the current context.
Any right way to check if a variable saved in sfContext is set or not ?
--
Javi
Ubuntu 8.04 - Symfony 1.3
-
I agree,
but in my specific case, I would like other users (and not
developpers) to be able to add/edit this content easily. Yaml fixtures
files would have be a nice choice ;-)
But if it's not possible, I'm gonna look for another way !
--
Adrien
On May 24, 4:45 pm, Pietrino Atzeni wrote:
> Hi,
On Mon, 24 May 2010, Oleg Sverdlov wrote:
> > primary key has unique value. The database server is supposed to raise an
> error when someone tries to enter duplicate value. It's up to software to
> process this type of errors.
So, after you have thousands of rows in the table, will you users keep
On Mon, 24 May 2010, Samuel Morhaim wrote:
> mysite.com/account/profile/5
>
> What prevents me from switching the /5 for a /4 /3 .. etc.. to call the
> profile for other Id's? How do you prevent this from happening?
You should never use real database IDs, use slugs:
http://www.symfony-project
Hi!!
i have a table on MySQL with a created_at field :
...
created_at | datetime
...
In my symfony project i just begin working with Filters (FormFilter).
I have this:
[CODE]
$this->setWidgets(array(
'created_at' => new sfWidgetFormFilterDate(array(
'from_date' => new
I was cleaning out some old papers, from some earlier development projects.
I found this:
http://www.facebook.com/album.php?aid=62549&id=1355017447&saved#!/photo.php?pid=1276055&id=1355017447
It's from 2004, and it kind of looks like Symfony and all the other MVCs.
;-)
Back then, I desperatel
Hi guys,
I'm trying to write some methods into my peer class's using a propel
behavior
(http://www.propelorm.org/wiki/Documentation/1.5/
Behaviors#WritingaBehavior)
But I seem to be having no luck, is there a plugin or any examples
around that you could point me towards?
Thanks!
--
If you wan
I would try having a check in the action like
$profile = $this->getRoute()->getObject();
$this->getUser() == $profile->getUser();
other ideas ?
cheers phil
2010/5/25 Samuel Morhaim :
> If I have something such as
>
> mysite.com/account/profile/5
>
> What prevents me from switching the /5 for a
I think you have to replace the security filter (apps/frontend/config/
factories.yml) with your own filter.
Just copy the one from symfony/lib/filter/
sfBasicSecurityFilter.class.php and make the necessary
changes to do redirects instead of internal forward operation.
gabriel
On May 24, 4:39
You could do it either at object->save() or better at object->set*()
something like:
public function setDescription($value)
{
parent::setDescription(strip_tags($value));
}
gabriel
On May 24, 11:56 pm, Tom Haskins-Vaughan
wrote:
> Hi all,
>
> I need to call strip_tags() on a form field b
If I have something such as
mysite.com/account/profile/5
What prevents me from switching the /5 for a /4 /3 .. etc.. to call the
profile for other Id's? How do you prevent this from happening?
thanks.
--
If you want to report a vulnerability issue on symfony, please send it to
security at
i noticed both of those plugins use sf_guard_user_profile table with
different columns. how can i use it then? i got already the database
configured for sfForkedDoctrineApplyPlugin and want to install
sfFacebookConnectPlugin.
--
If you want to report a vulnerability issue on symfony, please send
Hi all,
I need to call strip_tags() on a form field before I put it in my
database, only allowing and tags. I've done this by
creating a custom validator (see below). It works fine, but is there a
better way to do this?
Thanks,
Tom
protected function doClean($value)
{
return strip_tags($val
Simone,
As soon as one uses a function in the SELECT clause, the result is no
longer an object made persistent in the database, it's a new class (a
subclass (not yet defined) of DoctrineObject).
Because you are using SUM, there is no unique key for the result
(except in the situation where only o
Beautiful! Thank you!
On Mon, May 24, 2010 at 1:25 AM, Tom Ptacnik wrote:
> "I can't check in the changes" means, that you can't update the plugin
> via svn?
>
> I fso, than you can do your changes in the model/doctrine/
> sfDoctrineGuardPlugin sfGuardUser.class.php don't you? .. then this
> pro
On Mon, May 24, 2010 at 7:30 PM, Richtermeister wrote:
>
> the tag to product argument makes no sense to me... What are you
> attaching tags to if not the product's ID's?
>
to product IDs which are not auto-generated but indeed user-generated codes
entered from a catalog.
> In your version, yo
Hi,
there is this code below in sfDoctrineGuardPlugin.
$a = sfConfig::get('app_sf_guard_plugin_success_signin_url');
var_dump($a);
$signinUrl = sfConfig::get('app_sf_guard_plugin_success_signin_url',
$user->getReferer($request->getReferer()));
var_dump($signinUrl);
var_dump($user->getRefe
Hey Oleg,
the tag to product argument makes no sense to me... What are you
attaching tags to if not the product's ID's?
In your version, you want to edit product ids.. so what happens to the
references in the product_to_tags table? You have to update them
accordingly?
If you just went with autoin
On May 24, 6:20 pm, Philipp Mohrenweiser
wrote:
> Not a collection ? so you should probably use a limit 1 statement ...
> but if you want to get back multiple entrys the collection should be
> the right thing !?
As you can see I've SUM in my select so I want an object with the sum
of the found
Not a collection ? so you should probably use a limit 1 statement ...
but if you want to get back multiple entrys the collection should be
the right thing !?
2010/5/24 Simone Fumagalli :
> Hello. I'm trying to write this SQL statement in DQL !
>
> The SQL looks like :
>
> SELECT SUM(col1), SUM(
Hello. I'm trying to write this SQL statement in DQL !
The SQL looks like :
SELECT SUM(col1), SUM(col2), SUM(col3)
FROM slave_table
WHERE master_id = ?
AND
(
(year = ? and month < ? and priority = ?)
OR
(year = ? and month > ? and priority = ?)
)
I also would to get back a SlaveTable object and
On Sat, May 22, 2010 at 6:52 PM, Ricign wrote:
> Hi,
> What is the best way to do pagination for list of object.
> The objects are't come from database.
>
try sfDataSourcePlugin [0], isn't released but trunk is good ;)
[0] http://www.symfony-project.org/plugins/sfDataSourcePlugin
> Thanks,
>
>
Hi,
UPDATE
The same problem happens with edit/update not just new/create.
Both objects save but FK becomes 1 whatever it was before.
P
Anyone?
On May 24, 1:47 pm, Tofuwarrior wrote:
> Hi Tom,
>
> Thanks for replying. My problem has moved on.
>
> I can render the forms fine now but when
Hi,
I don't think it's easy, but... why would you do that? I think it's best
to create a specific task to accomplish this, since data-load reloads
everything in the db and it's really slow when it comes to load a lot of
data.
Hope this helps,
Pietro
Hi all,
I would like to store a set of i
On Mon, May 24, 2010 at 3:57 PM, Eno wrote:
> > I do not agree. It may be simply of indicator of people relying too much
> on
> > belowed MySQL AUTO_INCREMENT feature.
>
> Beloved? AUTO_INCREMENT was designed to be used this way. If humans
> assigned IDs, how do you guarantee uniqueness when ther
Hi there,
I started with a form, which is made by hand because of it's
complexity (it's a javascript modified form, with sortable parts,
etc). The problem is that now I need to do the validation, and it's a
total mess to do it from scratch in the action using the sfValidator*
classes.
So, I am th
Hi,
I am desgining and developing an e-Learning system for which i am
using symfony 1.4 with doctrine ORM.
I am using doctrine form to upload video with mime_type validation as
$this->validatorSchema['file']->setOption('mime_types', array('video/
mpeg','video/mpg','video/mp4','video/flv'));
$thi
Hi,
by default, using sfDGP, when i try to execute an action of an
application with security activated, the signin form appears but the URL
doesn't change to "frontend_dev.php/login".
So, what should i do to get changing the URL to "frontend_dev.php/login" ?
--
Javi
Ubuntu 8.04 - Symfony 1
On Mon, 24 May 2010, Oleg Sverdlov wrote:
> I do not expect problems with partial restore/merge, since the tag name is
> always operator-assigned and unique. In my experience, numeric ID often is a
> problem when doing partial restore.
That's why they need to be assigned by the database and manag
Hi Tom,
Thanks for replying. My problem has moved on.
I can render the forms fine now but when I save in new mode the system
saves the parent(storyteller) and the child (contact_details) objects
but doesn't put the right FK reference in the parent so all of the
parent objects I save have a chil
Thanks Olivier for your answer. When you say that the different values
can be stored in a config file, which file do you think of ? I know I
can use app.yml to store some constants, but I don't see how I can
save an array of values. And other question : you suggest to use maybe
a database table to
Hi all,
I would like to store a set of items into a YML fixture file, a list
of "Group" to apply for each new "User" that will be created.
And thus I would like to write something like this :
Group_1:
label: My first group
user:
Group2:
label: My second group
user:
And I w
Of course :D
so atm i changed the standard action behaviour of the renderer used in
sympal to fetch only the partial if theres a xmlhttprequest ... dunno
if its too nice
afterwards i process the parts i need with jquery ..
is there another comfortable way?
cheers phil
2010/5/24 Tom Ptacnik :
>
Calling redirect() means browser redirection, meaning a new context.
Save the variable in the session, using
$this->getUser()->setAttribute(), or use forward(), that forwards
internally.
On Mon, May 24, 2010 at 12:36, Javier Garcia wrote:
> Hi,
>
> i have these methods in module1/actions/actions.
Hi,
i have these methods in module1/actions/actions.class.php:
public function executeMethod1(sfWebRequest $request){
$a = 10;
sfContext::getInstance()->set('a', $a);
return $this->redirect('module1/method2');
}
public function executeMethod2(sfWebRequest $request){
Hi all,
Fabien just tweeted about this and I am very pleased to see it come to
fruition. I remember starting a mailing list post about the Definitive Guide to
symfony not being "ported" over for 1.4 and a discussion ensued whereby Fabien
said he'd look into getting that done as it would a valua
http://groups.google.com/group/symfony-users/browse_thread/thread/e0be57c3d4074d85/f2b58a604f51ae99?lnk=gst&q=ecommerce#f2b58a604f51ae99
On 05/24/2010 02:09 AM, bretth wrote:
Thanks for the reply Javi,
can you point me to the thread? The only recent one I can find on
Google Groups about shoppin
Hi,
In the routing.yml, I would like to use an underscore as a separator
for the parameter.
rule_sample:
url: /article/:info-:datePublished_:id.html
param:{ module: cms, action: test }
options:
segment_separators: ['-', '/', '.', '_']
requirements:
info: ^([A-Za-z0-9\-]+)
I can't imagine how to get it via ajax without an action :)
On 21 kvě, 02:10, phiamo wrote:
> Hi,
> i think i have a common thing here but searching newsgroups and docs
> didnt help.
>
> i have a component which depents on various request parameter (not
> directly but classes used depend on that
Where do they come from?
On 22 kvě, 23:52, Ricign wrote:
> Hi,
> What is the best way to do pagination for list of object.
> The objects are't come from database.
>
> Thanks,
>
> Rick
>
> --
> If you want to report a vulnerability issue on symfony, please send it to
> security at symfony-projec
I think callback is the right way.
http://blog.rajatpandit.com/2010/01/01/using-sfvalidatorcallback/
On 22 kvě, 17:48, Stéphane wrote:
> Wouldn't it be good too to validate them as not required then use an
> sfValidatorCallback using $this(form)->setPostValidator(new
> sfValidatorCallback()) ?
It's strange. I embed all my subforms in the configure method.
// Embed paymentinfo form
$this->embedForm('paymentinfo', new PaymentinfoForm($this->getObject()-
>getMyPaymentinfo()));
On 23 kvě, 13:01, Tofuwarrior wrote:
> UPDATE: I've found that the problem seems to be because I have mbedded
>
So the problem is, that symfony always write the autoincrement id or
it doesn't insert id at all?
On 21 kvě, 19:51, Mihai Rusoaie wrote:
> Hello!
>
> When I insert an new object in the database, I want the id to be
> assigned automatically (autoincrement).
>
> In the edit form, however, I want t
"I can't check in the changes" means, that you can't update the plugin
via svn?
I fso, than you can do your changes in the model/doctrine/
sfDoctrineGuardPlugin sfGuardUser.class.php don't you? .. then this
problem will be solved.
On 21 kvě, 18:12, ashton wrote:
> I have a question regarding du
at default the id is sfWidgetFormInputHidden() ... change it to
sfWidgetFormInputText or create some sfWidgetFormPlain (http://
code.google.com/p/uninformed/source/browse/trunk/lib/
sfWidgetFormPlain.class.php?spec=svn112&r=112)
On 21 kvě, 17:03, safa boubekri wrote:
> hello
> in my forms i have
Show some code of how you embed the form.
On 21 kvě, 16:26, Tofuwarrior wrote:
> Hi,
>
> Anyone give me any pointers? I'm stumped and not really sure where to
> look. Would really appreciate any help anyone could give, deadline is
> looming :-(
>
> I have an embedded form that works fine for th
49 matches
Mail list logo