Re: [symfony-users] Application Desktop

2010-08-20 Thread Jochen Daum
Hi, On Fri, Aug 20, 2010 at 7:43 PM, Christopher Schnell < christopher.schn...@mda.ch> wrote: > This would be also very interesting to me. > > > > What I like to know is: Is there a way to transfer a symfony app (online > running on apache with MySQL) with small efford to a small local webserver

[symfony-users] Introduction

2010-08-20 Thread Jochen Daum
Hi, my name is Jochen Daum, I just wanted to introduce myself before I start to deluge everyone with posts here. I run a small web development here in Auckland, New Zealand and only have minimal Symfony experience. I have however build and run my own in house development framework which does

[symfony-users] correlated subquery in orderbY()

2010-08-20 Thread Jochen Daum
Hi all, here is a problem I am stuck with: I have a table supplier and would like to use a correlated subquery for ordering of the results from this table: $query->orderBy("(SELECT AVG( supplier_rating_id ) FROM rating WHERE rating.supplier_id = supplier.id) DESC"); Doctrine rewrites this to SE

Re: [symfony-users] headers already sent

2010-08-20 Thread Jochen Daum
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. -- If you want to report a vulnerability issue on sym

[symfony-users] Re: correlated subquery in orderbY()

2010-08-21 Thread Jochen Daum
Hi, figured it out myself. Couple of lines before my ->orderBy(), there is a line creating the query: $query = Doctrine::getTable('Supplier') ->createQuery('a'); > $query->orderBy("(SELECT AVG( supplier_rating_id ) FROM rating WHERE > rating.supplier_id = supplier.id) DESC"); > The

Re: [symfony-users] Application Desktop

2010-08-23 Thread Jochen Daum
> > > You could achieve this with various commercial solutions, like those quoted > by Jochem. Others exists but as far as I know none for free or opensource. > > Another option is to go with a redistribuale VM (appliance) or create a > custom ubuntu bootable cd that start ser

[symfony-users] Doctrine/MySQL: double up of id index

2010-08-23 Thread Jochen Daum
t wondering for big tables, if the index wouldn't eat up unnecessary buffer space. Can this be configured to create only the PRIMARY index? Kind Regards, Jochen Daum Chief Automation Officer Automatem Ltd Phone: 09 630 3425 Mobile: 021 567 853 Email: j...@automatem.co.nz Skype

[symfony-users] resubmit login on certain module actions, every x minutes

2010-08-23 Thread Jochen Daum
Hi, I have an application that requires an additional resubmission of login, if you are accessing certain personal information - similar to some online banking when you make certain transactions. I'd like it to prompt a login, if you haven't accessed specific sections for say 5 minutes. Is there

Re: [symfony-users] Send Mails

2010-08-23 Thread Jochen Daum
Hi, On Tue, Aug 24, 2010 at 10:51 AM, vero wrote: > I have tried configuring my computer to use the fuction mail() . > I have tried use Zend Framework,, exactly like in jobeet. > But nothing works. The code was compiled, but no email was send. > > Please, help me! I need e-mails in my project.

Re: [symfony-users] Re: Doctrine/MySQL: double up of id index

2010-08-23 Thread Jochen Daum
Usually a PK ID is autogenerated for a given table if none was > specified. for example this: ReferralSource: columns: id: { type: integer(4), notnull: true, unique: true, primary: true, autoincrement: true } name: { type: string(100) } Kind Regards, Jochen Daum -- If you wa

[symfony-users] Please advice code structure for Google Maps auto-correct of address

2010-08-23 Thread Jochen Daum
Hi, for my application here I need to "auto-correct" an address with Google Maps. What I mean by that is someone may enter 1 Wellington street, Herne bay, Auckland but because of suburb dependent business logic I need 1 Wellington Street, Freemans Bay, Auckland, 1011 which would be returned fr

[symfony-users] How to validate: "required: true" for foreign key

2010-08-26 Thread Jochen Daum
Hi, I have schema.yml (extract) as follows: Person: columns: id: { type: integer(4), notnull: true, unique: true, primary: true, autoincrement: true } name: { type: string(100), notnull: true } hnr_street: { type: string(200), notnull: true } suburb: { type: string(50), notnull:

Re: [symfony-users] Re: missing field names in posted form --> Unexpected extra form field "0" ...

2010-08-26 Thread Jochen Daum
Hi, this could have to do with the suhosin patch that ships with Ubuntu and Debian systems. It may be configured stricter on your server than on your dev PC. Or, if you somehow manually installed PHP on your dev machine, you may not have it ay all. I can;t recall your error message though from ru

Re: [symfony-users] Re: How to validate: "required: true" for foreign key

2010-08-26 Thread Jochen Daum
Hi Raphael, On Thu, Aug 26, 2010 at 11:07 PM, Raphael Schumacher wrote: > This is quite easy. The validator that the (Doctrine-generated) class > BaseOrganisationForm is setting up, is fine and doesn't need to be > replaced. Just add the required option to that validator, such as > follows: > >

[symfony-users] difference of route_prefix on apps/app/config/routing.yml and apps/app/modules/module/config/generator.yml

2010-09-01 Thread Jochen Daum
Hi, out of interest, why does a generator.yml driven module ignore the route settings in config/route.yml and needs the settings defined in apps/app/modules/module/config/generator.yml - also the setting in generator.yml appears to be somehow wrong Example: I have in apps/backend/config/routing

[symfony-users] Can't get app.yml working for me

2010-09-01 Thread Jochen Daum
Hi, I have /config/app.yml: # You can find more information about this file on the symfony website: # http://www.symfony-project.org/reference/1_4/en/11-App # default values all: mbc: organisation_id: 1 mail: method: native and in a doctrine form class, use: $x = sfConfig::get('a

Re: [symfony-users] Can't get app.yml working for me

2010-09-01 Thread Jochen Daum
wrote: >> >> Untested, but I believe this is what you need: >> # default values >> all: >>   .mbc: >>     organisation_id: 1 >> >>   .mail: >>     method: native >> >> and then: >> >> $x = sfConfig::get('app_mbc_organiz

[symfony-users] sfValidatorDate for accepting 11.12.1973 and 11 Dec 1973 from sfWidgetFormInput()

2010-09-01 Thread Jochen Daum
Hi, I'd like to collect a birth date from a normal input field (I *hate* date dropdowns, especially for birthdays) So I've tried this regex for the date_format, but it doesn't work: $this->setValidator('dob',new sfValidatorDate(array('required'=>true, 'date_format' => "=(?P[0-9]{1,2})(\.|/|\s)"

Re: [symfony-users] Re: CLI sf Task, allowed memory issue

2010-09-01 Thread Jochen Daum
Hi, We've implemented a number of crawlers ourselves and the benefit of using PHP is that they are easier to maintain if they are built in a language a larger range of people cah use. To solve your specific problems build a queue system. Create a list table, which lists urls that you want to scr

[symfony-users] Re: sfValidatorDate for accepting 11.12.1973 and 11 Dec 1973 from sfWidgetFormInput()

2010-09-01 Thread Jochen Daum
Actually, answering my own question: On Thu, Sep 2, 2010 at 3:14 PM, Jochen Daum wrote: > Hi, > > I'd like to collect a birth date from a normal input field (I *hate* > date dropdowns, especially for birthdays) $this->setValidator('dob', new sfValidatorOr(arra

[symfony-users] overriding model->createQuery causes "The "default" context does not exist." on doctrine:data-dump

2010-09-02 Thread Jochen Daum
Hi, in an application I'm building here we use a person table for staff, 3rd parties as well as patients. Because of the sensitivity of the data, I thought it makes sense to control the access rights to this table at model level, so I wrote this: class PersonTable extends Doctrine_Table { p

Re: [symfony-users] File Download too big for memory

2010-09-02 Thread Jochen Daum
Hi, if you create the file yourself, you just need to start browser output while you are working on the file and clear the memory of any lines you have produced. I had the same problem, using an array to store all CSV lines, so I count how many lines I have and if it goes over a limit, I print th

[symfony-users] sfWidgetFormDoctrineChoice display lookup of a lookup

2010-09-03 Thread Jochen Daum
Hi, I got a table scheme which can be shortened to this: Person: columns: id: { type: integer(4), notnull: true, unique: true, primary: true, autoincrement: true } user_id: { type: integer(20) } name: { type: string(100), notnull: true } contract_id: { type: integer(4) } relat

[symfony-users] find out if user has credentials for route

2010-09-07 Thread Jochen Daum
Hi all, I have a backend application with various access cerdentials for a variety of modules. I'd like to build a navigation list, which should obviously be adjusted depending on what access rights you have. Is there a reasonably easy way to find out if the current user can access a route? If it

[symfony-users] Re: find out if user has credentials for route

2010-09-08 Thread Jochen Daum
Hi, On Wed, Sep 8, 2010 at 2:01 PM, Jochen Daum wrote: > Hi all, > > I have a backend application with various access cerdentials for a > variety of modules. > > I'd like to build a navigation list, which should obviously be > adjusted depending on what access r

Re: [symfony-users] Re: How to remove "send.x" and "send.y" parameters from GET url?

2010-09-10 Thread Jochen Daum
Hi, On Fri, Sep 10, 2010 at 7:20 AM, ScherlOMatic wrote: > Thanks for the info. > > So as I guess it's impossible to remove them. > > Do you know if the problem is the same with 'button' tag? The button tag won't have the problem -- If you want to report a vulnerability issue on symfony, plea

Re: [symfony-users] demo site - seperate db connection?

2010-09-10 Thread Jochen Daum
Hi John, On Thu, Sep 9, 2010 at 9:46 PM, Tofuwarrior wrote: > Hi, > > I want to do a demo of our site and to reset the database every 30 > minutes. > > Would it be better to run the demo using a different database > connection and a separate database or can anyone think of a way to do > it within

[symfony-users] surprising Doctrine fix #1868 applied to query

2010-09-22 Thread Jochen Daum
: status_id } ClosedByStaff: { class: Person, local: closed_by, foreignAlias: CloserPeerList } PeerNumber: columns: id: { type: integer(4), notnull: true, unique: true, primary: true, autoincrement: true } ps_number: { type: string(5), notnull: true } contract_id: { type: int

Re: [symfony-users] Re: multiple problems with Symfony 1.4 installation - msg#00943

2011-02-09 Thread Jochen Daum
often Session issues were caused by the suhosin module, which comes with many Ubuntu based hosts. Try to turn session encryption off and see if it helps. I found for example that sometimes the Document Root is part of the encryption and it may not always work as expected. HTH Kind Regards