[symfony-users] Re: VOIP integration

2009-03-24 Thread Gareth McCumskey
Thats kind of an arbitrary question. VOIP isn't a web application
technology in the vein of symfony and PHP. You will need far more than a
plugin for symfony to employ VOIP. Your best bet is to see if the likes of
Skype have released a Java Applet or Flash SWF that might run its VOIP
network from a website.

Your question is like asking if we can get a plugin to run our own
television channel on a website. Its a seperate technology with its own
needs and wants and not just another feature that can be included.

Good luck!

On Tue, Mar 24, 2009 at 5:51 AM, nidheesh nidheeshhasm...@gmail.com wrote:


 Hi all,

  Does anybody has any idea how can we implement phone call in a web
 application. How can we imlement voip in symfony, is there any plugin
 availble.

 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] Re: Best practice for multiple dynamic databases using symfony and Doctrine

2009-03-24 Thread David Herrmann

Hi Filipe,

bue...@gmail.com wrote:
 I'm having the same problem, if you already resolve please tell.

I haven't worked on it yet since I wrote that post, but by now I'm sure 
that I will have to create a custom route handler that cuts the first 
part from the route, creates the databases connection based on the cut 
part and continues using the remaining part of the route as if it was a 
normal sfRoute/sfObjectRoute/sfDoctrineRoute/sfPropelRoute/whatever.

The only part I don't know yet how to do is creating the database 
connection, but it can't be very hard.

Perhaps someone else here can tell us how to modifiy a connection to use 
a specific database name during run-time?

David

 
 On Feb 12, 11:07 am, David Herrmann d...@okto.tv wrote:
 I'm currently planning a large project where I need a quite tricky setup:

 There is a main database holding customers and business cases. Each
 customer may create unlimited business cases which are represented by
 an actual application. The database of a business case application will
 consist of 25+ tables.

 I want a nice URI/routing schema providing something like this:

 /:businesscaseid/module/action/:ids/:whatever

 So the route has to be parsed for the business case first, because the
 business case holds the database connection information for the actual
 application that comes afterwards in the route.

 I see 2 primary solutions for the database setup:
 *) a single database for each business case as described
 *) all business cases in 1 database with table prefixes - but I don't
 think Doctrine is capable of inserting general table prefixes at a low level

 Considering the multiple databases as the better option I would create a
 basic database.yml like this (taken from the symfony+Doctrine book
 chapter 2):

 all:
main:
  class: sfDoctrineDatabase
  param:
dsn: 'mysql:host=localhost;dbname=maindb'
username: user
password: secret
businesscase:
  class: sfDoctrineDatabase
  param:
dsn: 'mysql:host=localhost;dbname=businesscasedb'
username: user
password: secret

 I would store the actual information of the database connection inside
 the main database, since I don't think dynamically altering the
 databases.yml is a good idea. The action flow would then require
 something like this:

 pre-parse the route
= get business case id
= get business case db connection from main db
= replace businesscase connection dbname, user and password
   (access the settings array?)
= parse the rest of the route using the businesscase
   connection as default for everything that remains

 I think I need to keep the databases apart because there might be
 plugins or modules in the future that are only applied to a limited set
 of business cases/customers.

 What do you think of this setup? What would be the best way to modify
 the second database connection on the fly before the actual connection
 is created? Where should I hook the pre-parsing?

 Would it perhaps be easiest to create a new routing class similar to
 sfDoctrineRoute and scan for the businesscaseid in there? Then I could
 use the standard sfDoctrineRoute features (which I would really like to
 have).

 Or is it better to keep all database connections in the databases.yml
 file and create them using a somehow triggered task? Then I might have
 to adapt the model schema for each business case.


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: Re : [symfony-users] sfGuardExtraPlugin

2009-03-24 Thread gimler

the doctrine version sfDoctrineGuardExtraPlugin work 100% with
doctrine is testet and i use it in my live projects.

the propel version sfGuardExtraPlugin didn't work i will fix it this
week.

greetings
Gimler

On 23 Mrz., 21:56, ckemmler ckemm...@gmail.com wrote:
 Hi Gimler,

 Good to know you're the plugin's owner :-)
 If I understand well, you have written the plugin, then ported it to
 propel without really testing it. Am I right?
 I don't really understand the dependencies to propel actually, please
 forgive my ignorance. So why/how was it working outside of propel?
 What was the original/primary intent of developing this plugin in the
 first place?

 I have awkardly posted a second post on only the registerPlugin
 problems that I have. I'll cross-post here for the record.

 I'm trying to have this module to work. Being new to symfony/php (from
 a java background), I'm also suprised that this module isn't more
 integrated into the platform.

 1. to make it work at all I had to manually uncomment the if(...)
 clause in the sfGuardExtraPlugin config so it now reads:
   $this-dispatcher-connect('routing.load_configuration', array
 ('sfGuardExtraRouting', 'listenToRoutingLoadConfigurationEvent'));

 2. The only things I could get now is a simplistic register form (w/o
 captcha); when I hit the request button though, I'm having this
 exception:

 You must pass an array parameter to the clean() method (this validator
 can only be used as a post validator).

 I could get rid of it by commenting out some validators in
 BasesfGuardFormRegister.class.php, but I don't know why they wouldn't
 work

 - 3. new exception:

 Call to undefined method BasesfGuardUser::merge

 So this is referring to the other plugin, sfGuardPlugin, and seems to
 indicate that the two plugins are not sync'd. Is it possible?

 Your help will be welcomed with extreme gratefulness!

 Candide
--~--~-~--~~~---~--~~
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 textmate bundle

2009-03-24 Thread gestadieu

How about some command to run sf command line from within Textmate?

On Mar 13, 1:12 am, Dennis Benkert spinecras...@googlemail.com
wrote:
 I'm going to take over the maintenance of symfony's textmate bundle to
 add and update some features. For this I would ask everybody who is
 using textmate to give me some feature request.

 From the discussion on the developers list (http://groups.google.com/
 group/symfony-devs/browse_thread/thread/8f10a6141df2427f) we already
 have the following features:
  - add snippets for sfForms
  - support for common tasks
  - drop tif and tforeach. (already handled by the php bundle)
  - enhance the overall flow and shortcuts (i.e. the snippet shortcuts)

 Feel free to add suggestions in this discussion.

 - Dennis
--~--~-~--~~~---~--~~
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: Problem loading URLs like /some_folder/some_file.php with symfony 1.2

2009-03-24 Thread esion

Put your file in /web directory then to link from symfony use for
example :
link_to('My file', public_path('/uploads/myfile.whatyouwwant'))

Don't forget to start with / this does a reference to /web/ (this
should be the root of a virtualhost)

On Mar 23, 4:23 pm, Lee Bolding l...@leesbian.net wrote:
 Sorry, I should have made myself clearer.

 If the file/directory exists in the web directory, it will get served  
 by the webserver, not Symfony.

 On 23 Mar 2009, at 13:56, Eno wrote:



  On Mon, 23 Mar 2009, Lee Bolding wrote:

  If the file/directory exists in the web directory, it will get  
  served.

  Yeah, but my understanding (perhaps erroneous) is that the original
  poster does NOT want symfony to handle that file...

  --

--~--~-~--~~~---~--~~
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] pls reply me urgent

2009-03-24 Thread sachin jain
this is one partial name as
_home.php
?php
$myvalue = array(
'value' = 5,
'valueDescription' = 'nice to hear',
name='kk');
?

div class=couponValueTopLeft$?php echo $myvalue['value']; ?/div

div class=valueDescription$?php echo $featuredCoupon['value'].'
'.$featuredCoupon['valueDescription']; ?/div

?
now one more file is there index.php

where I have done like that

div id=couponHeader
?php include_partial(homePageFeatured);?
/div

I need to acess the name value of _home in this how to do I have tried many
things not working

pls help me

--~--~-~--~~~---~--~~
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] i18n does not work in functional tests ?

2009-03-24 Thread Loïc Vernet
The second parameter of the get URL is :sf_culture:

 1 - Recuperation d'un contenu
# get /ws/en/content/get.xml
   1.1 - Type xml
ok 1 - request parameter module is content
ok 2 - request parameter action is get
ok 3 - request format is xml
   1.2 - Recuperation de la traduction en
ok 4 - user culture is en
ok 5 - status code is 200
ok 6 - response selector response exists
ok 7 - response contains result![CDATA[true]]/result
ok 8 - response selector value exists
ok 9 - response contains THE
# get /ws/fr/content/get.xml
   1.3 - Recuperation de la traduction fr
ok 10 - user culture is fr
ok 11 - request parameter module is content
ok 12 - request parameter action is get
ok 13 - request format is xml
ok 14 - status code is 200
ok 15 - response selector response exists
ok 16 - response contains result![CDATA[true]]/result
ok 17 - response selector value exists
not ok 18 - response contains LA
# Failed test (C:\wamp\www\project\lib\vendor\symfony\lib\test\sfTesterRes
onse.class.php at line 243)
# '?xml version=1.0 encoding=UTF-8 standalone=no ?
response
  result![CDATA[true]]/result
  content
value![CDATA[THE ...]]/value
  /content
/response'
#   doesn't match '/LA/'

The same traduction is returned while it works when doing the test manually
with a browser. Same effect, if i force the user culture in the test. 
(or with an additional Browser restart)

Bug or did i miss something ?

++ COil



  
--~--~-~--~~~---~--~~
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: pls reply me urgent

2009-03-24 Thread Gareth McCumskey
Where in your module/project directory structure is _home.php stored?

If it is in /apps/app_name/templates then:

div id=couponHeader
?php include_partial(global/home);?
/div

If it is in a module directory such as
/apps/app_name/modules/module_name/templates/ then:

div id=couponHeader
?php include_partial(module_name/home);?
/div

Hope that helps. If not I highly recommend you do the tutorials (Jobeet for
symfony 1.2 and Askeet for symfony 1.0) to learn more about how the symfony
framework works because I think you may have rushed into using it and read a
few lines about partials without understanding the framework fully

Gareth


On Tue, Mar 24, 2009 at 12:17 PM, sachin jain jainsachi...@gmail.comwrote:

 this is one partial name as
 _home.php
 ?php
 $myvalue = array(
 'value' = 5,
 'valueDescription' = 'nice to hear',
 name='kk');
 ?

 div class=couponValueTopLeft$?php echo $myvalue['value']; ?/div

 div class=valueDescription$?php echo $featuredCoupon['value'].'
 '.$featuredCoupon['valueDescription']; ?/div

 ?
 now one more file is there index.php

 where I have done like that

 div id=couponHeader
 ?php include_partial(homePageFeatured);?
 /div

 I need to acess the name value of _home in this how to do I have tried many
 things not working

 pls help me






 


--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Paolo Mainardi
On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey gmccums...@gmail.comwrote:

 Thats kind of an arbitrary question. VOIP isn't a web application
 technology in the vein of symfony and PHP. You will need far more than a
 plugin for symfony to employ VOIP. Your best bet is to see if the likes of
 Skype have released a Java Applet or Flash SWF that might run its VOIP
 network from a website.


I disagree.

There are a lot of possibilities to using Voip SERVER on top of web
application, for example the Asterisk API:

http://code.google.com/p/asterisk-php-api/





 Your question is like asking if we can get a plugin to run our own
 television channel on a website. Its a seperate technology with its own
 needs and wants and not just another feature that can be included.


No, it's not the same, if we are integrating opensource technology, it's not
like embed a tv channel in a web application, otherwise other kind of
integration (IM ?) wouldn't ever possible.



-- 
Paolo Mainardi

CTO Twinbit
Blog: http://www.paolomainardi.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: pls reply me urgent

2009-03-24 Thread sachin jain
actually _home.php is in frontend/modules/home/template folder

I can use as per us instruction but what I asked now suppose I need to print
the value of array name in indexsucess.php how can i use that one ..


On 3/24/09, Gareth McCumskey gmccums...@gmail.com wrote:

 Where in your module/project directory structure is _home.php stored?

 If it is in /apps/app_name/templates then:

 div id=couponHeader
 ?php include_partial( global/home);?
 /div

 If it is in a module directory such as
 /apps/app_name/modules/module_name/templates/ then:

 div id=couponHeader
 ?php include_partial( module_name/home);?
 /div

 Hope that helps. If not I highly recommend you do the tutorials (Jobeet for
 symfony 1.2 and Askeet for symfony 1.0) to learn more about how the symfony
 framework works because I think you may have rushed into using it and read a
 few lines about partials without understanding the framework fully

 Gareth


 On Tue, Mar 24, 2009 at 12:17 PM, sachin jain jainsachi...@gmail.comwrote:

 this is one partial name as
 _home.php
 ?php
 $myvalue = array(
 'value' = 5,
 'valueDescription' = 'nice to hear',
 name='kk');
 ?

 div class=couponValueTopLeft$?php echo $myvalue['value']; ?/div

 div class=valueDescription$?php echo $featuredCoupon['value'].'
 '.$featuredCoupon['valueDescription']; ?/div

 ?
 now one more file is there index.php

 where I have done like that

 div id=couponHeader
 ?php include_partial(homePageFeatured);?
 /div

 I need to acess the name value of _home in this how to do I have tried
 many things not working

 pls help me









 


--~--~-~--~~~---~--~~
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] Select a column

2009-03-24 Thread kusum

Hi,
 I want to select data from a table list.I want to select all rows
and only one column from this table using symfony api method.How we
can select only one column.


Thanks,
Kusum
--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Sid Bachtiar

Hmm, but can you make VOIP chat web application just using HTML/XHTML,
CSS, Javascript, PHP 5, and Symfony Framework? How can you access the
computer's microphone to get the voice?

As I'm aware, it is currently only possible using signed applet or
signed flash/SWF.

Am I wrong?

On Tue, Mar 24, 2009 at 11:35 PM, Paolo Mainardi
paolomaina...@gmail.com wrote:


 On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey gmccums...@gmail.com
 wrote:

 Thats kind of an arbitrary question. VOIP isn't a web application
 technology in the vein of symfony and PHP. You will need far more than a
 plugin for symfony to employ VOIP. Your best bet is to see if the likes of
 Skype have released a Java Applet or Flash SWF that might run its VOIP
 network from a website.

 I disagree.

 There are a lot of possibilities to using Voip SERVER on top of web
 application, for example the Asterisk API:

 http://code.google.com/p/asterisk-php-api/




 Your question is like asking if we can get a plugin to run our own
 television channel on a website. Its a seperate technology with its own
 needs and wants and not just another feature that can be included.

 No, it's not the same, if we are integrating opensource technology, it's not
 like embed a tv channel in a web application, otherwise other kind of
 integration (IM ?) wouldn't ever possible.



 --
 Paolo Mainardi

 CTO Twinbit
 Blog: http://www.paolomainardi.com

 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Paolo Mainardi
On Tue, Mar 24, 2009 at 12:04 PM, Sid Bachtiar sid.bacht...@gmail.comwrote:


 Hmm, but can you make VOIP chat web application just using HTML/XHTML,
 CSS, Javascript, PHP 5, and Symfony Framework? How can you access the
 computer's microphone to get the voice?


For example you can put your number in a simple input text field to get in
touch with other side, the call goes in 2 side, like Jaxtr or other services
like this.



 As I'm aware, it is currently only possible using signed applet or
 signed flash/SWF.

 Am I wrong?


Read upper






 On Tue, Mar 24, 2009 at 11:35 PM, Paolo Mainardi
 paolomaina...@gmail.com wrote:
 
 
  On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey gmccums...@gmail.com
  wrote:
 
  Thats kind of an arbitrary question. VOIP isn't a web application
  technology in the vein of symfony and PHP. You will need far more than a
  plugin for symfony to employ VOIP. Your best bet is to see if the likes
 of
  Skype have released a Java Applet or Flash SWF that might run its VOIP
  network from a website.
 
  I disagree.
 
  There are a lot of possibilities to using Voip SERVER on top of web
  application, for example the Asterisk API:
 
  http://code.google.com/p/asterisk-php-api/
 
 
 
 
  Your question is like asking if we can get a plugin to run our own
  television channel on a website. Its a seperate technology with its own
  needs and wants and not just another feature that can be included.
 
  No, it's not the same, if we are integrating opensource technology, it's
 not
  like embed a tv channel in a web application, otherwise other kind of
  integration (IM ?) wouldn't ever possible.
 
 
 
  --
  Paolo Mainardi
 
  CTO Twinbit
  Blog: http://www.paolomainardi.com
 
  
 



 --
 Blue Horn Ltd - System Development
 http://bluehorn.co.nz

 



-- 
Paolo Mainardi

CTO Twinbit
Blog: http://www.paolomainardi.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: VOIP integration

2009-03-24 Thread Gareth McCumskey
-SIGH-

I never said it was totally impossible to achieve. I simply said that
expecting it to be as easy as a plugin is expecting far too much. And Sid is
right, its not possible to get PHP/JavaScript to take input from a users
microphone to allow VOIP so right now...

Your best bet is to see if the likes of Skype have released a Java Applet
or Flash SWF that might run its VOIP network from a website. - My Previous
email

Please don't read into my comments that which is not there.

Gareth

On Tue, Mar 24, 2009 at 12:35 PM, Paolo Mainardi paolomaina...@gmail.comwrote:



 On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey gmccums...@gmail.comwrote:

 Thats kind of an arbitrary question. VOIP isn't a web application
 technology in the vein of symfony and PHP. You will need far more than a
 plugin for symfony to employ VOIP. Your best bet is to see if the likes of
 Skype have released a Java Applet or Flash SWF that might run its VOIP
 network from a website.


 I disagree.

 There are a lot of possibilities to using Voip SERVER on top of web
 application, for example the Asterisk API:

 http://code.google.com/p/asterisk-php-api/





 Your question is like asking if we can get a plugin to run our own
 television channel on a website. Its a seperate technology with its own
 needs and wants and not just another feature that can be included.


 No, it's not the same, if we are integrating opensource technology, it's
 not like embed a tv channel in a web application, otherwise other kind of
 integration (IM ?) wouldn't ever possible.



 --
 Paolo Mainardi

 CTO Twinbit
 Blog: http://www.paolomainardi.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: pls reply me urgent

2009-03-24 Thread Sid Bachtiar

 I can use as per us instruction but what I asked now suppose I need to print
 the value of array name in indexsucess.php how can i use that one ..

As far as I know, you can't do that. You should push the value from
indexSuccess.php, for example, your indexSuccess.php should look like:

?php
$myvalue = array(
'value' = 5,
'valueDescription' = 'nice to hear',
name='kk');
?
div id=couponHeader
?php include_partial(module_name/home, array('myvalue' = $myvalue));?
/div

Then your _home.php should look like:

div class=couponValueTopLeft$?php echo $myvalue['value']; ?/div

div class=valueDescription$?php echo $featuredCoupon['value'].'
'.$featuredCoupon['valueDescription']; ?/div

So, you're passing myvalue from indexSuccess.php to _home.php ... you
can't do the other way around ...


On Tue, Mar 24, 2009 at 11:51 PM, sachin jain jainsachi...@gmail.com wrote:
 actually _home.php is in frontend/modules/home/template folder

 I can use as per us instruction but what I asked now suppose I need to print
 the value of array name in indexsucess.php how can i use that one ..


 On 3/24/09, Gareth McCumskey gmccums...@gmail.com wrote:

 Where in your module/project directory structure is _home.php stored?

 If it is in /apps/app_name/templates then:

 div id=couponHeader
 ?php include_partial(
 global/home);?
 /div

 If it is in a module directory such as
 /apps/app_name/modules/module_name/templates/ then:

 div id=couponHeader
 ?php include_partial(
 module_name/home);?
 /div
 Hope that helps. If not I highly recommend you do the tutorials (Jobeet
 for symfony 1.2 and Askeet for symfony 1.0) to learn more about how the
 symfony framework works because I think you may have rushed into using it
 and read a few lines about partials without understanding the framework
 fully

 Gareth


 On Tue, Mar 24, 2009 at 12:17 PM, sachin jain jainsachi...@gmail.com
 wrote:

 this is one partial name as
 _home.php
 ?php
 $myvalue = array(
 'value' = 5,
 'valueDescription' = 'nice to hear',
 name='kk');
 ?

 div class=couponValueTopLeft$?php echo $myvalue['value']; ?/div

 div class=valueDescription$?php echo $featuredCoupon['value'].'
 '.$featuredCoupon['valueDescription']; ?/div

 ?
 now one more file is there index.php

 where I have done like that

 div id=couponHeader
 ?php include_partial(homePageFeatured);?
 /div

 I need to acess the name value of _home in this how to do I have tried
 many things not working

 pls help me










 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Paolo Mainardi
On Tue, Mar 24, 2009 at 12:22 PM, Sid Bachtiar sid.bacht...@gmail.comwrote:


 I think I understand now. They're talking about VOIP
 service/management (like Jaxtr), not developing VOIP client like Skype
 using Symfony Framework.

 Well, Symfony plugin is easy to develop, just need someone with
 experience in VOIP service :)


Yes, and could be a very nice plugin to write for Symfony, another little
piece of external world integration (like the last Jabber plugin).







 On Wed, Mar 25, 2009 at 12:19 AM, Gareth McCumskey gmccums...@gmail.com
 wrote:
  -SIGH-
 
  I never said it was totally impossible to achieve. I simply said that
  expecting it to be as easy as a plugin is expecting far too much. And Sid
 is
  right, its not possible to get PHP/JavaScript to take input from a users
  microphone to allow VOIP so right now...
 
  Your best bet is to see if the likes of Skype have released a Java
 Applet
  or Flash SWF that might run its VOIP network from a website. - My
 Previous
  email
 
  Please don't read into my comments that which is not there.
 
  Gareth
 
  On Tue, Mar 24, 2009 at 12:35 PM, Paolo Mainardi 
 paolomaina...@gmail.com
  wrote:
 
 
  On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey gmccums...@gmail.com
 
  wrote:
 
  Thats kind of an arbitrary question. VOIP isn't a web application
  technology in the vein of symfony and PHP. You will need far more than
 a
  plugin for symfony to employ VOIP. Your best bet is to see if the likes
 of
  Skype have released a Java Applet or Flash SWF that might run its VOIP
  network from a website.
 
  I disagree.
 
  There are a lot of possibilities to using Voip SERVER on top of web
  application, for example the Asterisk API:
 
  http://code.google.com/p/asterisk-php-api/
 
 
 
 
  Your question is like asking if we can get a plugin to run our own
  television channel on a website. Its a seperate technology with its own
  needs and wants and not just another feature that can be included.
 
  No, it's not the same, if we are integrating opensource technology, it's
  not like embed a tv channel in a web application, otherwise other kind
 of
  integration (IM ?) wouldn't ever possible.
 
 
 
  --
  Paolo Mainardi
 
  CTO Twinbit
  Blog: http://www.paolomainardi.com
 
 
 
 
  
 



 --
 Blue Horn Ltd - System Development
 http://bluehorn.co.nz

 



-- 
Paolo Mainardi

CTO Twinbit
Blog: http://www.paolomainardi.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: Select a column

2009-03-24 Thread Sid Bachtiar

Try something like this:

$c = new Criteria();

$c-clearSelectColumns();
$c-addSelectColumn(SomePeer::SOME_COLUMN);

$rs = MyModelPeer::doSelectRS($c);

while ($rs-next())
{
  echo $rs-get(0); // value of SOME_COLUMN
}

On Tue, Mar 24, 2009 at 11:51 PM, kusum kusumdhin...@gmail.com wrote:

 Hi,
     I want to select data from a table list.I want to select all rows
 and only one column from this table using symfony api method.How we
 can select only one column.


 Thanks,
 Kusum
 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: Best practice for multiple dynamic databases using symfony and Doctrine

2009-03-24 Thread Filipe Costa
see this
http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59

On Tue, Mar 24, 2009 at 7:34 AM, David Herrmann d...@okto.tv wrote:


 Hi Filipe,

 bue...@gmail.com wrote:
  I'm having the same problem, if you already resolve please tell.

 I haven't worked on it yet since I wrote that post, but by now I'm sure
 that I will have to create a custom route handler that cuts the first
 part from the route, creates the databases connection based on the cut
 part and continues using the remaining part of the route as if it was a
 normal sfRoute/sfObjectRoute/sfDoctrineRoute/sfPropelRoute/whatever.

 The only part I don't know yet how to do is creating the database
 connection, but it can't be very hard.

 Perhaps someone else here can tell us how to modifiy a connection to use
 a specific database name during run-time?

 David

 
  On Feb 12, 11:07 am, David Herrmann d...@okto.tv wrote:
  I'm currently planning a large project where I need a quite tricky
 setup:
 
  There is a main database holding customers and business cases. Each
  customer may create unlimited business cases which are represented by
  an actual application. The database of a business case application will
  consist of 25+ tables.
 
  I want a nice URI/routing schema providing something like this:
 
  /:businesscaseid/module/action/:ids/:whatever
 
  So the route has to be parsed for the business case first, because the
  business case holds the database connection information for the actual
  application that comes afterwards in the route.
 
  I see 2 primary solutions for the database setup:
  *) a single database for each business case as described
  *) all business cases in 1 database with table prefixes - but I don't
  think Doctrine is capable of inserting general table prefixes at a low
 level
 
  Considering the multiple databases as the better option I would create a
  basic database.yml like this (taken from the symfony+Doctrine book
  chapter 2):
 
  all:
 main:
   class: sfDoctrineDatabase
   param:
 dsn: 'mysql:host=localhost;dbname=maindb'
 username: user
 password: secret
 businesscase:
   class: sfDoctrineDatabase
   param:
 dsn: 'mysql:host=localhost;dbname=businesscasedb'
 username: user
 password: secret
 
  I would store the actual information of the database connection inside
  the main database, since I don't think dynamically altering the
  databases.yml is a good idea. The action flow would then require
  something like this:
 
  pre-parse the route
 = get business case id
 = get business case db connection from main db
 = replace businesscase connection dbname, user and password
(access the settings array?)
 = parse the rest of the route using the businesscase
connection as default for everything that remains
 
  I think I need to keep the databases apart because there might be
  plugins or modules in the future that are only applied to a limited set
  of business cases/customers.
 
  What do you think of this setup? What would be the best way to modify
  the second database connection on the fly before the actual connection
  is created? Where should I hook the pre-parsing?
 
  Would it perhaps be easiest to create a new routing class similar to
  sfDoctrineRoute and scan for the businesscaseid in there? Then I could
  use the standard sfDoctrineRoute features (which I would really like to
  have).
 
  Or is it better to keep all database connections in the databases.yml
  file and create them using a somehow triggered task? Then I might have
  to adapt the model schema for each business case.


 


--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Sid Bachtiar

I was not aware of that jabber plugin! A very nice plugin ... thank
you for making me aware of it :-)

On Wed, Mar 25, 2009 at 12:27 AM, Paolo Mainardi
paolomaina...@gmail.com wrote:


 On Tue, Mar 24, 2009 at 12:22 PM, Sid Bachtiar sid.bacht...@gmail.com
 wrote:

 I think I understand now. They're talking about VOIP
 service/management (like Jaxtr), not developing VOIP client like Skype
 using Symfony Framework.

 Well, Symfony plugin is easy to develop, just need someone with
 experience in VOIP service :)

 Yes, and could be a very nice plugin to write for Symfony, another little
 piece of external world integration (like the last Jabber plugin).





 On Wed, Mar 25, 2009 at 12:19 AM, Gareth McCumskey gmccums...@gmail.com
 wrote:
  -SIGH-
 
  I never said it was totally impossible to achieve. I simply said that
  expecting it to be as easy as a plugin is expecting far too much. And
  Sid is
  right, its not possible to get PHP/JavaScript to take input from a users
  microphone to allow VOIP so right now...
 
  Your best bet is to see if the likes of Skype have released a Java
  Applet
  or Flash SWF that might run its VOIP network from a website. - My
  Previous
  email
 
  Please don't read into my comments that which is not there.
 
  Gareth
 
  On Tue, Mar 24, 2009 at 12:35 PM, Paolo Mainardi
  paolomaina...@gmail.com
  wrote:
 
 
  On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey
  gmccums...@gmail.com
  wrote:
 
  Thats kind of an arbitrary question. VOIP isn't a web application
  technology in the vein of symfony and PHP. You will need far more than
  a
  plugin for symfony to employ VOIP. Your best bet is to see if the
  likes of
  Skype have released a Java Applet or Flash SWF that might run its VOIP
  network from a website.
 
  I disagree.
 
  There are a lot of possibilities to using Voip SERVER on top of web
  application, for example the Asterisk API:
 
  http://code.google.com/p/asterisk-php-api/
 
 
 
 
  Your question is like asking if we can get a plugin to run our own
  television channel on a website. Its a seperate technology with its
  own
  needs and wants and not just another feature that can be included.
 
  No, it's not the same, if we are integrating opensource technology,
  it's
  not like embed a tv channel in a web application, otherwise other kind
  of
  integration (IM ?) wouldn't ever possible.
 
 
 
  --
  Paolo Mainardi
 
  CTO Twinbit
  Blog: http://www.paolomainardi.com
 
 
 
 
  
 



 --
 Blue Horn Ltd - System Development
 http://bluehorn.co.nz





 --
 Paolo Mainardi

 CTO Twinbit
 Blog: http://www.paolomainardi.com

 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Sid Bachtiar

I think I understand now. They're talking about VOIP
service/management (like Jaxtr), not developing VOIP client like Skype
using Symfony Framework.

Well, Symfony plugin is easy to develop, just need someone with
experience in VOIP service :)

On Wed, Mar 25, 2009 at 12:19 AM, Gareth McCumskey gmccums...@gmail.com wrote:
 -SIGH-

 I never said it was totally impossible to achieve. I simply said that
 expecting it to be as easy as a plugin is expecting far too much. And Sid is
 right, its not possible to get PHP/JavaScript to take input from a users
 microphone to allow VOIP so right now...

 Your best bet is to see if the likes of Skype have released a Java Applet
 or Flash SWF that might run its VOIP network from a website. - My Previous
 email

 Please don't read into my comments that which is not there.

 Gareth

 On Tue, Mar 24, 2009 at 12:35 PM, Paolo Mainardi paolomaina...@gmail.com
 wrote:


 On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey gmccums...@gmail.com
 wrote:

 Thats kind of an arbitrary question. VOIP isn't a web application
 technology in the vein of symfony and PHP. You will need far more than a
 plugin for symfony to employ VOIP. Your best bet is to see if the likes of
 Skype have released a Java Applet or Flash SWF that might run its VOIP
 network from a website.

 I disagree.

 There are a lot of possibilities to using Voip SERVER on top of web
 application, for example the Asterisk API:

 http://code.google.com/p/asterisk-php-api/




 Your question is like asking if we can get a plugin to run our own
 television channel on a website. Its a seperate technology with its own
 needs and wants and not just another feature that can be included.

 No, it's not the same, if we are integrating opensource technology, it's
 not like embed a tv channel in a web application, otherwise other kind of
 integration (IM ?) wouldn't ever possible.



 --
 Paolo Mainardi

 CTO Twinbit
 Blog: http://www.paolomainardi.com




 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: Select a column

2009-03-24 Thread Dheeraj Kumar Aggarwal
hi

if you are using Propel1.3 then try this because Propel 1.3 now works on PDO


$c = new Criteria();
.
.
.
.
$c-clearSelectColumns();
$c-addSelectColumn(SomePeer::SOME_COLUMN);
$stmt = MyModelPeer::doSelectStmt($c);
$results = array();
while($row = $stmt-fetch(PDO::FETCH_NUM))
{
  $result[ ] = $stmt-fetchColumn(0);
}

hope this should work for u

On Tue, Mar 24, 2009 at 4:57 PM, Sid Bachtiar sid.bacht...@gmail.comwrote:


 Try something like this:

$c = new Criteria();

$c-clearSelectColumns();
$c-addSelectColumn(SomePeer::SOME_COLUMN);

$rs = MyModelPeer::doSelectRS($c);

while ($rs-next())
{
  echo $rs-get(0); // value of SOME_COLUMN
 }

 On Tue, Mar 24, 2009 at 11:51 PM, kusum kusumdhin...@gmail.com wrote:
 
  Hi,
  I want to select data from a table list.I want to select all rows
  and only one column from this table using symfony api method.How we
  can select only one column.
 
 
  Thanks,
  Kusum
  
 



 --
 Blue Horn Ltd - System Development
 http://bluehorn.co.nz

 



-- 
Regards,
Dheeraj

--~--~-~--~~~---~--~~
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] Download files - broken pdf

2009-03-24 Thread Tomasz Ignatiuk

Hi, I use this code for downloading files. If I download image, it
works, but if I download pdf, after downloading when I try to open it,
it is broken.

  if (is_file($sciezka))
  {
// Enforce full download and prevent 
caching
session_cache_limiter('none');

// No layout needed for file downloads
$this-setLayout(false);
sfConfig::set('sf_web_debug', false);

// Prepare http headers
$fileType = 
$file-getFormat()-getNazwa();

$response = $this-getResponse();
$response-clearHttpHeaders();
$response-setHttpheader('Pragma: 
public', true);

$response-addCacheControlHttpHeader('Cache-Control', 'must-
revalidate');
$response-setHttpHeader('Expires', 
'Sat, 26 Jul 1997 05:00:00
GMT');

$response-setHttpHeader(Last-Modified, gmdate(D, d M Y
H:i:s) .  GMT);

$response-setContentType($fileType,true);

$response-setHttpHeader('Content-Description', 'File Transfer');

$response-setHttpHeader('Content-Transfer-Encoding', 'binary',
true);

$response-setHttpHeader('Content-Length', filesize('' . (string)
utf8_decode($sciezka . '')));

$response-setHttpHeader('Content-Disposition', 'attachment;
filename=' . str_replace( , _, utf8_decode($file-
getFileNazwaOrginalna())) );

// Unlock session in order to prevent 
php session warnings
$this-getUser()-shutdown();

// Send http headers to user client
$response-sendHttpHeaders();

// Send file to user client

//$response-setContent(readfile(utf8_decode($sciezka)));

$response-setContent(readfile($sciezka));

//$response-setContent(file_get_contents(utf8_decode($file-
getPath(;
$response-sendContent();

// Exit without a template
return sfView::NONE;


This line gives a proper mime type
$response-setContentType($fileType, true);

fileType is taken from DB. These are: application/pdf and image/jpeg

It is strange because locally on apache on windows it works, but not
on production server. Locally when I upload file its pdf mime type is
application/x-download. On production server it is application/pdf

Any ideas what is the problem?
--~--~-~--~~~---~--~~
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: Best practice for multiple dynamic databases using symfony and Doctrine

2009-03-24 Thread David Herrmann

Filipe Costa wrote:
 see this 
 http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59

This looks interesting... I think the way to go for me will be to 
manipulate the databases in sfDatabaseManager while the routing is done. 
As soon as I have some code to share I'll post a snippet or write a blog 
post (might still be a few weeks until then).

Thanks

David

--~--~-~--~~~---~--~~
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: Best practice for multiple dynamic databases using symfony and Doctrine

2009-03-24 Thread Filipe Costa
I already right the code but it doesn't work on symfony 1.2. will you help
me?

cumps

On Tue, Mar 24, 2009 at 11:59 AM, David Herrmann d...@okto.tv wrote:


 Filipe Costa wrote:
  see this
 
 http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59

 This looks interesting... I think the way to go for me will be to
 manipulate the databases in sfDatabaseManager while the routing is done.
 As soon as I have some code to share I'll post a snippet or write a blog
 post (might still be a few weeks until then).

 Thanks

 David

 


--~--~-~--~~~---~--~~
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: sfGuardExtraPlugin

2009-03-24 Thread Tom Boutell

I am curious... has anyone evaluated both this plugin and my own
sfDoctrineApplyPlugin? How do they compare?

-- 
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.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: VOIP integration

2009-03-24 Thread Pablo Godel
I have experience with VOIP and will probably be looking into developing
some integration between symfony and Asterisk, but it may be months away.
And by the way, I am the developer of the Jabber plugin :) I will post an
announcement since it looks like most people are not aware.

Pablo

On Tue, Mar 24, 2009 at 7:32 AM, Sid Bachtiar sid.bacht...@gmail.comwrote:


 I was not aware of that jabber plugin! A very nice plugin ... thank
 you for making me aware of it :-)

 On Wed, Mar 25, 2009 at 12:27 AM, Paolo Mainardi
 paolomaina...@gmail.com wrote:
 
 
  On Tue, Mar 24, 2009 at 12:22 PM, Sid Bachtiar sid.bacht...@gmail.com
  wrote:
 
  I think I understand now. They're talking about VOIP
  service/management (like Jaxtr), not developing VOIP client like Skype
  using Symfony Framework.
 
  Well, Symfony plugin is easy to develop, just need someone with
  experience in VOIP service :)
 
  Yes, and could be a very nice plugin to write for Symfony, another little
  piece of external world integration (like the last Jabber plugin).
 
 
 
 
 
  On Wed, Mar 25, 2009 at 12:19 AM, Gareth McCumskey 
 gmccums...@gmail.com
  wrote:
   -SIGH-
  
   I never said it was totally impossible to achieve. I simply said that
   expecting it to be as easy as a plugin is expecting far too much. And
   Sid is
   right, its not possible to get PHP/JavaScript to take input from a
 users
   microphone to allow VOIP so right now...
  
   Your best bet is to see if the likes of Skype have released a Java
   Applet
   or Flash SWF that might run its VOIP network from a website. - My
   Previous
   email
  
   Please don't read into my comments that which is not there.
  
   Gareth
  
   On Tue, Mar 24, 2009 at 12:35 PM, Paolo Mainardi
   paolomaina...@gmail.com
   wrote:
  
  
   On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey
   gmccums...@gmail.com
   wrote:
  
   Thats kind of an arbitrary question. VOIP isn't a web application
   technology in the vein of symfony and PHP. You will need far more
 than
   a
   plugin for symfony to employ VOIP. Your best bet is to see if the
   likes of
   Skype have released a Java Applet or Flash SWF that might run its
 VOIP
   network from a website.
  
   I disagree.
  
   There are a lot of possibilities to using Voip SERVER on top of web
   application, for example the Asterisk API:
  
   http://code.google.com/p/asterisk-php-api/
  
  
  
  
   Your question is like asking if we can get a plugin to run our own
   television channel on a website. Its a seperate technology with its
   own
   needs and wants and not just another feature that can be included.
  
   No, it's not the same, if we are integrating opensource technology,
   it's
   not like embed a tv channel in a web application, otherwise other
 kind
   of
   integration (IM ?) wouldn't ever possible.
  
  
  
   --
   Paolo Mainardi
  
   CTO Twinbit
   Blog: http://www.paolomainardi.com
  
  
  
  
   
  
 
 
 
  --
  Blue Horn Ltd - System Development
  http://bluehorn.co.nz
 
 
 
 
 
  --
  Paolo Mainardi
 
  CTO Twinbit
  Blog: http://www.paolomainardi.com
 
  
 



 --
 Blue Horn Ltd - System Development
 http://bluehorn.co.nz

 


--~--~-~--~~~---~--~~
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] Announcement of sfJabberJaxlPlugin availability - connect to Jabber servers from symfony applications

2009-03-24 Thread Pablo Godel

Hello,

I wanted to announce the availability of a new symfony plugin that
allows your application to interact with Jabber based instant
messaging services like GoogleTalk. It lets you send and receive
instant messages, and monitor the status of contacts (ie. view their
online status).

To communicate with Jabber servers, it uses the library Jaxl
(http://code.google.com/p/jaxl/) created by Abhinav Singh.

sfJabberJaxlPlugin provides a model to store incoming/outgoing
messages, roster and contact statuses. It also provides a set of CLI
tasks to send messages and to run a daemon that listens for incoming
messages and other commands coming from a Jabber server.

The plugin can be found at
http://www.symfony-project.org/plugins/sfJabberJaxlPlugin

More information about the announcement can be found at
http://blog.servergrove.com/2009/03/20/symfony-plugin-sfjabberjaxl-released-to-the-public/

Please feel free to send any comments or feature suggestions.

Regards,
Pablo

--~--~-~--~~~---~--~~
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] Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread Campezzi

Hello there,

I've been a PHP developer for some time now, and recently I began
exploring the world of Symfony. So far, I like what I see, but there's
one thing that I still haven't quite figured out: in a real-world
environment, what are the basic advantages and drawbacks of Propel and
Doctrine?

I think the only way of getting a realistic answer is to ask people
who are clearly more experienced with real projects using sf than me.
So, if you feel like it, please share a quick view on what you love
and hate about Propel and Doctrine! :)

Cheers!
--~--~-~--~~~---~--~~
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: Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread Dheeraj Kumar Aggarwal
Hi

A comparison between LightORM, Propel and Doctrine is given at this link

http://phplightorm.wiki.sourceforge.net/LightOrm+vs+Propel+vs+Doctrine+benchmark

On Tue, Mar 24, 2009 at 6:28 PM, Campezzi campe...@gmail.com wrote:


 Hello there,

 I've been a PHP developer for some time now, and recently I began
 exploring the world of Symfony. So far, I like what I see, but there's
 one thing that I still haven't quite figured out: in a real-world
 environment, what are the basic advantages and drawbacks of Propel and
 Doctrine?

 I think the only way of getting a realistic answer is to ask people
 who are clearly more experienced with real projects using sf than me.
 So, if you feel like it, please share a quick view on what you love
 and hate about Propel and Doctrine! :)

 Cheers!
 



-- 
Regards,
Dheeraj

--~--~-~--~~~---~--~~
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] Recursive routing

2009-03-24 Thread Evert Harmeling | fh
How can I define/create a route that matches recursive parameters?

Let's say I have cat1, subcat1, subsubcat1, subsubsubcat1
My url would be http://mydomain.com/cat1/subcat1/subsubcat1/subsubsubcat1

But I don't want to make seperate routes for them... because my categories are 
recursive. 

I've tried to use the segment_seperators option, but that didn't work out... 
When I use the route (defined at the end) '/*', how do I fetch my parameter 
then?

Thanks in advance,
Evert Harmeling

--~--~-~--~~~---~--~~
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 textmate bundle

2009-03-24 Thread Gareth McCumskey
On Mon, Mar 23, 2009 at 8:43 PM, hsteckylf j...@jncissler.com wrote:



 Also, a larger task might be doing an autocomplete of model getter and
 setter functions.

 You mean just like Eclipse PDT can already do? :P

--~--~-~--~~~---~--~~
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: sfGuardExtraPlugin

2009-03-24 Thread gimler

the both plugin are for the same thing but not 100% the same.

with sfGuardExtraPlugin you don't need swift mailer or the guard user
profile.

it is a quite simple plugin and it works 100% with doctrine you can
simple add a email column to your sf_guard_user table and don't need a
join for a login.

i have started the plugin development in 2008 at this time there
exists no plugin to fit user registration and password requests.
i simple port some code from the 1.0 version of the
sfDoctrineGuardPlugin.


greetings
Gimler

On 24 Mrz., 13:44, Tom Boutell t...@punkave.com wrote:
 I am curious... has anyone evaluated both this plugin and my own
 sfDoctrineApplyPlugin? How do they compare?

 --
 Tom Boutell
 P'unk Avenue
 215 755 1330
 punkave.com
 window.punkave.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: Pre-set filter in admin generator

2009-03-24 Thread Szabolcs Sulik

hi

the problem is that every filter form have its own name formats, and
csrf protection enabled by default.

if you want to use your previous filters by url, you have to set
'filters[%s]' name format in your filter forms, and disable csrf
protection (http://www.symfony-project.org/jobeet/1_2/Propel/en/
22#chapter_22_forms_in_cache).

bests
Szabolcs

On Mar 18, 10:16 am, HAUSa
jeroen_heeft_behoefte_aan_r...@hotmail.com wrote:
 I refer to the Symfony 
 documentation:http://www.symfony-project.org/book/1_2/14-Generators#chapte
 r_14_sub_creating_a_custom_header_and_footer
 A bit down is a gray block telling me something about presetting a
 filter by use of the URL.

 Now, in Symfony 1.2 this doesn't work any more. If my admin module is
 called content, I can't just use this URL any more:
 content?filter=filterfilters[page_id]=1

 I saw that since Symfony 1.2 filters have been submitted to this URL
 prefix:
 content/filter/action

 So, I put my filter values behind that URL:
 content/filter/action?filter=filterfilters[page_id]=1

 But now I get an error message, telling me that the _csrf_token field
 is required. I keep receiving that message, even if I use this URL:
 content/filter/action?filter=filterfilters[page_id]=1a
 mp;_csrf_token=118fc4b7df48fc1a4ad056343f17c22f

 And now I'm desperate Razz
 Does anyone know how to pre-set admin filters in Symfony 1.2?

--~--~-~--~~~---~--~~
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: sfGuardExtraPlugin

2009-03-24 Thread Tom Boutell

You have a point re: merging the email field into the users table.
Hopefully a future version of sfDoctrineGuardPlugin will offer column
aggregation inheritance to allow this kind of thing to be done more
elegantly.

Does your approach handle account verification and so on?

Symfony 1.2 doesn't have a built-in mailer. What did you use instead
of SwiftMailer? Zend?

-- 
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.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: sfGuardExtraPlugin

2009-03-24 Thread gimler

yes. email verification for register and password reset.

simple add to your sfGuardUser.class.php and you have a extra email
column

public function setTableDefinition()
{
  parent::setTableDefinition();

  $this-hasColumn('email', 'string', 80, array('notnull' = true,
'unique' = true));
}

i simple use the mail function ;) so i set a smtp relay in my php.ini.
but you can use any other mailer like Zend_Mail or SwiftMailer simple
create a sfGuardExtraMail in your lib folder with a static function
send

static public function send(array $params)

greetings
Gimler

On 24 Mrz., 15:42, Tom Boutell t...@punkave.com wrote:
 You have a point re: merging the email field into the users table.
 Hopefully a future version of sfDoctrineGuardPlugin will offer column
 aggregation inheritance to allow this kind of thing to be done more
 elegantly.

 Does your approach handle account verification and so on?

 Symfony 1.2 doesn't have a built-in mailer. What did you use instead
 of SwiftMailer? Zend?

 --
 Tom Boutell
 P'unk Avenue
 215 755 1330
 punkave.com
 window.punkave.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 textmate bundle

2009-03-24 Thread Dennis Benkert

Hey all,

I just wanted to inform you about the state of the bundle. I did some
refactoring on the tab shortcuts and they are much shorter now. To
give you a little teaser I will list some of them:

'gro' + tab: will produce $this-getRoute()-getObject();
'gp' + tab: will produce $this-getRequest()-getRequestParameter('id');
'rgp' + tab: will produce $request-getParameter('id');
'user' + tab: will produce $this-getUser()

There are of course even more shortcuts for different parts of symfony
(actions, models, views, forms, etc.). Maybe i can give you a full
list of them after the next weekend.

 How about some command to run sf command line from within Textmate?
I'm working on this already. My idea is to execute the common symfony
tasks within textmate (e.g. symfony cc) and show the output as a nice
html popup. As for now you can run 'cc', '-V', 'test:all',
'propel:build-all', 'propel:build-model' and 'propel:build-forms' via
the key binding 'strg' + 's'.

 Also, a larger task might be doing an autocomplete of model getter and
 setter functions.
I'm not sure if textmate has the functionality to do that and i'm also
not sure if textmate is the right editor for this feature. :)

To give you all access to my working copy I'm also thinking about
putting the bundle on github. Are there any concerns about this? If
you have any other suggestions (even for key bindings or tab
shortcuts) feel free to post them here.

- Dennis

2009/3/24 Gareth McCumskey gmccums...@gmail.com:


 On Mon, Mar 23, 2009 at 8:43 PM, hsteckylf j...@jncissler.com wrote:


 Also, a larger task might be doing an autocomplete of model getter and
 setter functions.

 You mean just like Eclipse PDT can already do? :P

 


--~--~-~--~~~---~--~~
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] constructor in symfony

2009-03-24 Thread dziobacz

How can I make constructor in symfony ? I have tried:

class see_userActions extends sfActions
{
  private $id;

  public function initialize()
  {
 $id=2;
  }
.
}

Error:
Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
() should be compatible with that of sfAction::initialize()
Call to a member function notify() on a non-object

Why ??
--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Dheeraj Kumar Aggarwal
hi

i think us should use the symfony
preExecutehttp://www.symfony-project.org/api/1_2/sfAction#method_preexecute()
function.
Executes an application defined process prior to execution of this sfAction
object.

On Tue, Mar 24, 2009 at 8:41 PM, dziobacz aaabbbcccda...@gmail.com wrote:


 How can I make constructor in symfony ? I have tried:

 class see_userActions extends sfActions
 {
  private $id;

  public function initialize()
  {
 $id=2;
  }
 .
 }

 Error:
 Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
 () should be compatible with that of sfAction::initialize()
 Call to a member function notify() on a non-object

 Why ??
 



-- 
Regards,
Dheeraj

--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Fási Gábor

You can use __construct(), just like anywhere else in php. Remember to
call parent::__construct().

On Tue, Mar 24, 2009 at 16:11, dziobacz aaabbbcccda...@gmail.com wrote:

 How can I make constructor in symfony ? I have tried:

 class see_userActions extends sfActions
 {
  private $id;

  public function initialize()
  {
         $id=2;
  }
 .
 }

 Error:
 Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
 () should be compatible with that of sfAction::initialize()
 Call to a member function notify() on a non-object

 Why ??
 


--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread dziobacz

It doesn't work for me:

class see_userActions extends sfActions
{
  private $ident;

  public function __construct()
  {
parent::__construct();
$ident=2;
  }
.
}


What can be the reason ?


On 24 Mar, 16:41, Fási Gábor maerl...@gmail.com wrote:
 You can use __construct(), just like anywhere else in php. Remember to
 call parent::__construct().

 On Tue, Mar 24, 2009 at 16:11, dziobacz aaabbbcccda...@gmail.com wrote:

  How can I make constructor in symfony ? I have tried:

  class see_userActions extends sfActions
  {
   private $id;

   public function initialize()
   {
          $id=2;
   }
  .
  }

  Error:
  Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
  () should be compatible with that of sfAction::initialize()
  Call to a member function notify() on a non-object

  Why ??


--~--~-~--~~~---~--~~
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 textmate bundle

2009-03-24 Thread Jacob Coby

On Mar 24, 2009, at 11:04 AM, Dennis Benkert wrote:


 Hey all,

 I just wanted to inform you about the state of the bundle. I did some
 refactoring on the tab shortcuts and they are much shorter now. To
 give you a little teaser I will list some of them:

 'gro' + tab: will produce $this-getRoute()-getObject();
 'gp' + tab: will produce $this-getRequest()- 
 getRequestParameter('id');
 'rgp' + tab: will produce $request-getParameter('id');
 'user' + tab: will produce $this-getUser()

Nice.  Much easier to invoke.  FWIW, I've mapped getRequestParameter()  
to ^P to match the Rails  bundle.  It's such a common thing that it  
deserves to be easy to insert.  Ideally, the bundle would detect sf =  
1.1 and automatically use $request-getParameter() instead of $this- 
 getRequest()-getParameter().


 There are of course even more shortcuts for different parts of symfony
 (actions, models, views, forms, etc.). Maybe i can give you a full
 list of them after the next weekend.

 How about some command to run sf command line from within Textmate?
 I'm working on this already. My idea is to execute the common symfony
 tasks within textmate (e.g. symfony cc) and show the output as a nice
 html popup. As for now you can run 'cc', '-V', 'test:all',
 'propel:build-all', 'propel:build-model' and 'propel:build-forms' via
 the key binding 'strg' + 's'.

strg?  is that command?

 Also, a larger task might be doing an autocomplete of model getter  
 and
 setter functions.
 I'm not sure if textmate has the functionality to do that and i'm also
 not sure if textmate is the right editor for this feature. :)

There is a php code completion bundle already available.  I've never  
used it though.  All in all, TM just doesn't seem to have very good  
support for code completion.

 To give you all access to my working copy I'm also thinking about
 putting the bundle on github. Are there any concerns about this? If
 you have any other suggestions (even for key bindings or tab
 shortcuts) feel free to post them here.

Please do.  I'll probably send a couple of pull requests your way.   
The other option is to try and get it into the macromates svn  
repository.  I don't know the process for that though.


 - Dennis

 2009/3/24 Gareth McCumskey gmccums...@gmail.com:


 On Mon, Mar 23, 2009 at 8:43 PM, hsteckylf j...@jncissler.com wrote:


 Also, a larger task might be doing an autocomplete of model getter  
 and
 setter functions.

 You mean just like Eclipse PDT can already do? :P




 

--
Jacob Coby







--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Fási Gábor
What's 'broken'? You mean you can't open it with adobe reader/other
pdf viewer? If you check the contents of the file, does it look like a
valid pdf?

On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk tomek.ignat...@gmail.com wrote:

 Hi, I use this code for downloading files. If I download image, it
 works, but if I download pdf, after downloading when I try to open it,
 it is broken.

          if (is_file($sciezka))
          {
                                        // Enforce full download and prevent 
 caching
                                        session_cache_limiter('none');

                                        // No layout needed for file downloads
                                        $this-setLayout(false);
                                        sfConfig::set('sf_web_debug', false);

                                        // Prepare http headers
                                        $fileType = 
 $file-getFormat()-getNazwa();

                                        $response = $this-getResponse();
                                        $response-clearHttpHeaders();
                                        $response-setHttpheader('Pragma: 
 public', true);
                                        
 $response-addCacheControlHttpHeader('Cache-Control', 'must-
 revalidate');
                                        $response-setHttpHeader('Expires', 
 'Sat, 26 Jul 1997 05:00:00
 GMT');
                                        
 $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
 H:i:s) .  GMT);
                                        
 $response-setContentType($fileType,true);
                                        
 $response-setHttpHeader('Content-Description', 'File Transfer');
                                        
 $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
 true);
                                        
 $response-setHttpHeader('Content-Length', filesize('' . (string)
 utf8_decode($sciezka . '')));
                                        
 $response-setHttpHeader('Content-Disposition', 'attachment;
 filename=' . str_replace( , _, utf8_decode($file-
getFileNazwaOrginalna())) );

                                        // Unlock session in order to prevent 
 php session warnings
                                        $this-getUser()-shutdown();

                                        // Send http headers to user client
                                        $response-sendHttpHeaders();

                                        // Send file to user client
                                        
 //$response-setContent(readfile(utf8_decode($sciezka)));
                                        
 $response-setContent(readfile($sciezka));
                                        
 //$response-setContent(file_get_contents(utf8_decode($file-
getPath(;
                                        $response-sendContent();

                                        // Exit without a template
                                        return sfView::NONE;


 This line gives a proper mime type
 $response-setContentType($fileType, true);

 fileType is taken from DB. These are: application/pdf and image/jpeg

 It is strange because locally on apache on windows it works, but not
 on production server. Locally when I upload file its pdf mime type is
 application/x-download. On production server it is application/pdf

 Any ideas what is the problem?
 


--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Tomasz Ignatiuk
File is damaged and it couldn't be repaired - this shows while I try to
open it with adobe acrobat/reader. I don;t know how to check it in a
different way.

2009/3/24 Fási Gábor maerl...@gmail.com

 What's 'broken'? You mean you can't open it with adobe reader/other
 pdf viewer? If you check the contents of the file, does it look like a
 valid pdf?

 On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk tomek.ignat...@gmail.com
 wrote:
 
  Hi, I use this code for downloading files. If I download image, it
  works, but if I download pdf, after downloading when I try to open it,
  it is broken.
 
   if (is_file($sciezka))
   {
 // Enforce full download and
 prevent caching
 session_cache_limiter('none');
 
 // No layout needed for file
 downloads
 $this-setLayout(false);
 sfConfig::set('sf_web_debug',
 false);
 
 // Prepare http headers
 $fileType =
 $file-getFormat()-getNazwa();
 
 $response = $this-getResponse();
 $response-clearHttpHeaders();
 $response-setHttpheader('Pragma:
 public', true);
 
  $response-addCacheControlHttpHeader('Cache-Control', 'must-
  revalidate');
 
  $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
  GMT');
 
  $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
  H:i:s) .  GMT);
 
  $response-setContentType($fileType,true);
 
  $response-setHttpHeader('Content-Description', 'File Transfer');
 
  $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
  true);
 
  $response-setHttpHeader('Content-Length', filesize('' . (string)
  utf8_decode($sciezka . '')));
 
  $response-setHttpHeader('Content-Disposition', 'attachment;
  filename=' . str_replace( , _, utf8_decode($file-
 getFileNazwaOrginalna())) );
 
 // Unlock session in order to
 prevent php session warnings
 $this-getUser()-shutdown();
 
 // Send http headers to user
 client
 $response-sendHttpHeaders();
 
 // Send file to user client
 
  //$response-setContent(readfile(utf8_decode($sciezka)));
 
  $response-setContent(readfile($sciezka));
 
  //$response-setContent(file_get_contents(utf8_decode($file-
 getPath(;
 $response-sendContent();
 
 // Exit without a template
 return sfView::NONE;
 
 
  This line gives a proper mime type
  $response-setContentType($fileType, true);
 
  fileType is taken from DB. These are: application/pdf and image/jpeg
 
  It is strange because locally on apache on windows it works, but not
  on production server. Locally when I upload file its pdf mime type is
  application/x-download. On production server it is application/pdf
 
  Any ideas what is the problem?
  
 

 


--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Pierre

$this-ident ... ever heard of $this? ;)

On 24 Mrz., 17:06, dziobacz aaabbbcccda...@gmail.com wrote:
 It doesn't work for me:

 class see_userActions extends sfActions
 {
   private $ident;

   public function __construct()
   {
         parent::__construct();
         $ident=2;
   }
 .

 }

 What can be the reason ?

 On 24 Mar, 16:41, Fási Gábor maerl...@gmail.com wrote:

  You can use __construct(), just like anywhere else in php. Remember to
  call parent::__construct().

  On Tue, Mar 24, 2009 at 16:11, dziobacz aaabbbcccda...@gmail.com wrote:

   How can I make constructor in symfony ? I have tried:

   class see_userActions extends sfActions
   {
    private $id;

    public function initialize()
    {
           $id=2;
    }
   .
   }

   Error:
   Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
   () should be compatible with that of sfAction::initialize()
   Call to a member function notify() on a non-object

   Why ??
--~--~-~--~~~---~--~~
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: Pre-set filter in admin generator

2009-03-24 Thread cleve

what about overriding the addSortCriteria method:

  protected function addSortCriteria($c)
  {
  //check to see if filter exists

  //if not add your own
  $c-add();

  parent::addSortCriteria($c);
  }

If anybodies got a cleaner method I like to know too?
--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread dziobacz

Heh - ok so:

private $ident;

  public function __construct()
  {
 parent::__construct();
$this-ident=2;
  }

but I have still errors:
Missing argument 1 for sfComponent::__construct()
Missing argument 2 for sfComponent::__construct()
Missing argument 3 for sfComponent::__construct()
Undefined variable: context
Undefined variable: moduleName
Undefined variable: actionName
Call to a member function getEventDispatcher() on a non-object

I don't have this errors without constructor.


On 24 Mar, 17:16, Pierre p...@pierre-minnieur.de wrote:
 $this-ident ... ever heard of $this? ;)

 On 24 Mrz., 17:06, dziobacz aaabbbcccda...@gmail.com wrote:

  It doesn't work for me:

  class see_userActions extends sfActions
  {
    private $ident;

    public function __construct()
    {
          parent::__construct();
          $ident=2;
    }
  .

  }

  What can be the reason ?

  On 24 Mar, 16:41, Fási Gábor maerl...@gmail.com wrote:

   You can use __construct(), just like anywhere else in php. Remember to
   call parent::__construct().

   On Tue, Mar 24, 2009 at 16:11, dziobacz aaabbbcccda...@gmail.com wrote:

How can I make constructor in symfony ? I have tried:

class see_userActions extends sfActions
{
 private $id;

 public function initialize()
 {
        $id=2;
 }
.
}

Error:
Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
() should be compatible with that of sfAction::initialize()
Call to a member function notify() on a non-object

Why ??


--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Yevgeniy A. Viktorov


Open it as raw file, for example with the help of vim.

Tomasz Ignatiuk wrote:
 File is damaged and it couldn't be repaired - this shows while I try
 to open it with adobe acrobat/reader. I don;t know how to check it in
 a different way.

 2009/3/24 Fási Gábor maerl...@gmail.com mailto:maerl...@gmail.com

 What's 'broken'? You mean you can't open it with adobe reader/other
 pdf viewer? If you check the contents of the file, does it look like a
 valid pdf?

 On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk
 tomek.ignat...@gmail.com mailto:tomek.ignat...@gmail.com wrote:
 
  Hi, I use this code for downloading files. If I download image, it
  works, but if I download pdf, after downloading when I try to
 open it,
  it is broken.
 
   if (is_file($sciezka))
   {
 // Enforce full download
 and prevent caching
   
  session_cache_limiter('none');
 
 // No layout needed for
 file downloads
 $this-setLayout(false);
   
  sfConfig::set('sf_web_debug', false);
 
 // Prepare http headers
 $fileType =
 $file-getFormat()-getNazwa();
 
 $response =
 $this-getResponse();
   
  $response-clearHttpHeaders();
   
  $response-setHttpheader('Pragma: public', true);
   
  $response-addCacheControlHttpHeader('Cache-Control', 'must-
  revalidate');
   
  $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
  GMT');
   
  $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
  H:i:s) .  GMT);
   
  $response-setContentType($fileType,true);
   
  $response-setHttpHeader('Content-Description', 'File Transfer');
   
  $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
  true);
   
  $response-setHttpHeader('Content-Length', filesize('' . (string)
  utf8_decode($sciezka . '')));
   
  $response-setHttpHeader('Content-Disposition', 'attachment;
  filename=' . str_replace( , _, utf8_decode($file-
 getFileNazwaOrginalna())) );
 
 // Unlock session in
 order to prevent php session warnings
 $this-getUser()-shutdown();
 
 // Send http headers to
 user client
 $response-sendHttpHeaders();
 
 // Send file to user client
   
  //$response-setContent(readfile(utf8_decode($sciezka)));
   
  $response-setContent(readfile($sciezka));
   
  //$response-setContent(file_get_contents(utf8_decode($file-
 getPath(;
 $response-sendContent();
 
 // Exit without a template
 return sfView::NONE;
 
 
  This line gives a proper mime type
  $response-setContentType($fileType, true);
 
  fileType is taken from DB. These are: application/pdf and image/jpeg
 
  It is strange because locally on apache on windows it works, but not
  on production server. Locally when I upload file its pdf mime
 type is
  application/x-download. On production server it is application/pdf
 
  Any ideas what is the problem?
  
 




 

--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Tomasz Ignatiuk
I opened with a VIM. Many strange alphanumeric stuff inside but in the end
there is a warning few times:


bWarning/b:  Cannot modify header information - headers already sent by
(output started at
/home//apps/backend/modules/dokument/actions/actions.class.php:592) in
b/home/../symfony/1.2/lib/response/sfWebResponse.class.php/b on line
b335/bbr /

592 line is: $response-setContent(readfile($sciezka));





2009/3/24 Yevgeniy A. Viktorov w...@osmonitoring.com



 Open it as raw file, for example with the help of vim.

 Tomasz Ignatiuk wrote:
  File is damaged and it couldn't be repaired - this shows while I try
  to open it with adobe acrobat/reader. I don;t know how to check it in
  a different way.
 
  2009/3/24 Fási Gábor maerl...@gmail.com mailto:maerl...@gmail.com
 
  What's 'broken'? You mean you can't open it with adobe reader/other
  pdf viewer? If you check the contents of the file, does it look like
 a
  valid pdf?
 
  On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk
  tomek.ignat...@gmail.com mailto:tomek.ignat...@gmail.com wrote:
  
   Hi, I use this code for downloading files. If I download image, it
   works, but if I download pdf, after downloading when I try to
  open it,
   it is broken.
  
if (is_file($sciezka))
{
  // Enforce full download
  and prevent caching
  
   session_cache_limiter('none');
  
  // No layout needed for
  file downloads
  $this-setLayout(false);
  
   sfConfig::set('sf_web_debug', false);
  
  // Prepare http headers
  $fileType =
  $file-getFormat()-getNazwa();
  
  $response =
  $this-getResponse();
  
   $response-clearHttpHeaders();
  
   $response-setHttpheader('Pragma: public', true);
  
   $response-addCacheControlHttpHeader('Cache-Control', 'must-
   revalidate');
  
   $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
   GMT');
  
   $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
   H:i:s) .  GMT);
  
   $response-setContentType($fileType,true);
  
   $response-setHttpHeader('Content-Description', 'File Transfer');
  
   $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
   true);
  
   $response-setHttpHeader('Content-Length', filesize('' . (string)
   utf8_decode($sciezka . '')));
  
   $response-setHttpHeader('Content-Disposition', 'attachment;
   filename=' . str_replace( , _, utf8_decode($file-
  getFileNazwaOrginalna())) );
  
  // Unlock session in
  order to prevent php session warnings
  
  $this-getUser()-shutdown();
  
  // Send http headers to
  user client
  
  $response-sendHttpHeaders();
  
  // Send file to user client
  
   //$response-setContent(readfile(utf8_decode($sciezka)));
  
   $response-setContent(readfile($sciezka));
  
   //$response-setContent(file_get_contents(utf8_decode($file-
  getPath(;
  $response-sendContent();
  
  // Exit without a template
  return sfView::NONE;
  
  
   This line gives a proper mime type
   $response-setContentType($fileType, true);
  
   fileType is taken from DB. These are: application/pdf and
 image/jpeg
  
   It is strange because locally on apache on windows it works, but
 not
   on production server. Locally when I upload file its pdf mime
  type is
   application/x-download. On production server it is application/pdf
  
   Any ideas what is the problem?
   
  
 
 
 
 
  

 


--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Paolo Mainardi
On Tue, Mar 24, 2009 at 5:46 PM, Tomasz Ignatiuk
tomek.ignat...@gmail.comwrote:

 I opened with a VIM. Many strange alphanumeric stuff inside but in the end
 there is a warning few times:


 bWarning/b:  Cannot modify header information - headers already sent by
 (output started at
 /home//apps/backend/modules/dokument/actions/actions.class.php:592) in
 b/home/../symfony/1.2/lib/response/sfWebResponse.class.php/b on line
 b335/bbr /

 592 line is: $response-setContent(readfile($sciezka));



Try to export without the _dev frontend enabled.







 2009/3/24 Yevgeniy A. Viktorov w...@osmonitoring.com



 Open it as raw file, for example with the help of vim.

 Tomasz Ignatiuk wrote:
  File is damaged and it couldn't be repaired - this shows while I try
  to open it with adobe acrobat/reader. I don;t know how to check it in
  a different way.
 
  2009/3/24 Fási Gábor maerl...@gmail.com mailto:maerl...@gmail.com
 
  What's 'broken'? You mean you can't open it with adobe reader/other
  pdf viewer? If you check the contents of the file, does it look like
 a
  valid pdf?
 
  On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk
  tomek.ignat...@gmail.com mailto:tomek.ignat...@gmail.com wrote:
  
   Hi, I use this code for downloading files. If I download image, it
   works, but if I download pdf, after downloading when I try to
  open it,
   it is broken.
  
if (is_file($sciezka))
{
  // Enforce full download
  and prevent caching
  
   session_cache_limiter('none');
  
  // No layout needed for
  file downloads
  $this-setLayout(false);
  
   sfConfig::set('sf_web_debug', false);
  
  // Prepare http headers
  $fileType =
  $file-getFormat()-getNazwa();
  
  $response =
  $this-getResponse();
  
   $response-clearHttpHeaders();
  
   $response-setHttpheader('Pragma: public', true);
  
   $response-addCacheControlHttpHeader('Cache-Control', 'must-
   revalidate');
  
   $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
   GMT');
  
   $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
   H:i:s) .  GMT);
  
   $response-setContentType($fileType,true);
  
   $response-setHttpHeader('Content-Description', 'File Transfer');
  
   $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
   true);
  
   $response-setHttpHeader('Content-Length', filesize('' . (string)
   utf8_decode($sciezka . '')));
  
   $response-setHttpHeader('Content-Disposition', 'attachment;
   filename=' . str_replace( , _, utf8_decode($file-
  getFileNazwaOrginalna())) );
  
  // Unlock session in
  order to prevent php session warnings
  
  $this-getUser()-shutdown();
  
  // Send http headers to
  user client
  
  $response-sendHttpHeaders();
  
  // Send file to user client
  
   //$response-setContent(readfile(utf8_decode($sciezka)));
  
   $response-setContent(readfile($sciezka));
  
   //$response-setContent(file_get_contents(utf8_decode($file-
  getPath(;
  $response-sendContent();
  
  // Exit without a template
  return sfView::NONE;
  
  
   This line gives a proper mime type
   $response-setContentType($fileType, true);
  
   fileType is taken from DB. These are: application/pdf and
 image/jpeg
  
   It is strange because locally on apache on windows it works, but
 not
   on production server. Locally when I upload file its pdf mime
  type is
   application/x-download. On production server it is application/pdf
  
   Any ideas what is the problem?
   
  
 
 
 
 
  




 



-- 
Paolo Mainardi

CTO Twinbit
Blog: http://www.paolomainardi.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: Download files - broken pdf

2009-03-24 Thread Tomasz Ignatiuk
It worked, thank you very much!!! But how did you know? Why it is happening?

2009/3/24 Paolo Mainardi paolomaina...@gmail.com



 On Tue, Mar 24, 2009 at 5:46 PM, Tomasz Ignatiuk tomek.ignat...@gmail.com
  wrote:

 I opened with a VIM. Many strange alphanumeric stuff inside but in the end
 there is a warning few times:


 bWarning/b:  Cannot modify header information - headers already sent
 by (output started at
 /home//apps/backend/modules/dokument/actions/actions.class.php:592) in
 b/home/../symfony/1.2/lib/response/sfWebResponse.class.php/b on line
 b335/bbr /

 592 line is: $response-setContent(readfile($sciezka));



 Try to export without the _dev frontend enabled.







 2009/3/24 Yevgeniy A. Viktorov w...@osmonitoring.com



 Open it as raw file, for example with the help of vim.

 Tomasz Ignatiuk wrote:
  File is damaged and it couldn't be repaired - this shows while I try
  to open it with adobe acrobat/reader. I don;t know how to check it in
  a different way.
 
  2009/3/24 Fási Gábor maerl...@gmail.com mailto:maerl...@gmail.com
 
  What's 'broken'? You mean you can't open it with adobe reader/other
  pdf viewer? If you check the contents of the file, does it look
 like a
  valid pdf?
 
  On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk
  tomek.ignat...@gmail.com mailto:tomek.ignat...@gmail.com
 wrote:
  
   Hi, I use this code for downloading files. If I download image,
 it
   works, but if I download pdf, after downloading when I try to
  open it,
   it is broken.
  
if (is_file($sciezka))
{
  // Enforce full download
  and prevent caching
  
   session_cache_limiter('none');
  
  // No layout needed for
  file downloads
  $this-setLayout(false);
  
   sfConfig::set('sf_web_debug', false);
  
  // Prepare http headers
  $fileType =
  $file-getFormat()-getNazwa();
  
  $response =
  $this-getResponse();
  
   $response-clearHttpHeaders();
  
   $response-setHttpheader('Pragma: public', true);
  
   $response-addCacheControlHttpHeader('Cache-Control', 'must-
   revalidate');
  
   $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
   GMT');
  
   $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
   H:i:s) .  GMT);
  
   $response-setContentType($fileType,true);
  
   $response-setHttpHeader('Content-Description', 'File Transfer');
  
   $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
   true);
  
   $response-setHttpHeader('Content-Length', filesize('' . (string)
   utf8_decode($sciezka . '')));
  
   $response-setHttpHeader('Content-Disposition', 'attachment;
   filename=' . str_replace( , _, utf8_decode($file-
  getFileNazwaOrginalna())) );
  
  // Unlock session in
  order to prevent php session warnings
  
  $this-getUser()-shutdown();
  
  // Send http headers to
  user client
  
  $response-sendHttpHeaders();
  
  // Send file to user
 client
  
   //$response-setContent(readfile(utf8_decode($sciezka)));
  
   $response-setContent(readfile($sciezka));
  
   //$response-setContent(file_get_contents(utf8_decode($file-
  getPath(;
  $response-sendContent();
  
  // Exit without a template
  return sfView::NONE;
  
  
   This line gives a proper mime type
   $response-setContentType($fileType, true);
  
   fileType is taken from DB. These are: application/pdf and
 image/jpeg
  
   It is strange because locally on apache on windows it works, but
 not
   on production server. Locally when I upload file its pdf mime
  type is
   application/x-download. On production server it is
 application/pdf
  
   Any ideas what is the problem?
   
  
 
 
 
 
  








 --
 Paolo Mainardi

 CTO Twinbit
 Blog: http://www.paolomainardi.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 textmate bundle

2009-03-24 Thread Dennis Benkert

 FWIW, I've mapped getRequestParameter()
 to ^P to match the Rails  bundle.  It's such a common thing that it
 deserves to be easy to insert.  Ideally, the bundle would detect sf =
 1.1 and automatically use $request-getParameter() instead of $this-
  getRequest()-getParameter().

I try to add it without doubling the code. But if I create a github
repository you can just send me a pull request. I'll see what I can do
about the lookup of the projects symfony version.

 strg?  is that command?

Whoops. 'strg' is the german version of 'ctrl'. :) So it's 'ctrl' +
's' (or ^S) to open the cli menu.

- Dennis

2009/3/24 Jacob Coby jc...@portallabs.com:

 On Mar 24, 2009, at 11:04 AM, Dennis Benkert wrote:


 Hey all,

 I just wanted to inform you about the state of the bundle. I did some
 refactoring on the tab shortcuts and they are much shorter now. To
 give you a little teaser I will list some of them:

 'gro' + tab: will produce $this-getRoute()-getObject();
 'gp' + tab: will produce $this-getRequest()-
 getRequestParameter('id');
 'rgp' + tab: will produce $request-getParameter('id');
 'user' + tab: will produce $this-getUser()

 Nice.  Much easier to invoke.  FWIW, I've mapped getRequestParameter()
 to ^P to match the Rails  bundle.  It's such a common thing that it
 deserves to be easy to insert.  Ideally, the bundle would detect sf =
 1.1 and automatically use $request-getParameter() instead of $this-
  getRequest()-getParameter().


 There are of course even more shortcuts for different parts of symfony
 (actions, models, views, forms, etc.). Maybe i can give you a full
 list of them after the next weekend.

 How about some command to run sf command line from within Textmate?
 I'm working on this already. My idea is to execute the common symfony
 tasks within textmate (e.g. symfony cc) and show the output as a nice
 html popup. As for now you can run 'cc', '-V', 'test:all',
 'propel:build-all', 'propel:build-model' and 'propel:build-forms' via
 the key binding 'strg' + 's'.

 strg?  is that command?

 Also, a larger task might be doing an autocomplete of model getter
 and
 setter functions.
 I'm not sure if textmate has the functionality to do that and i'm also
 not sure if textmate is the right editor for this feature. :)

 There is a php code completion bundle already available.  I've never
 used it though.  All in all, TM just doesn't seem to have very good
 support for code completion.

 To give you all access to my working copy I'm also thinking about
 putting the bundle on github. Are there any concerns about this? If
 you have any other suggestions (even for key bindings or tab
 shortcuts) feel free to post them here.

 Please do.  I'll probably send a couple of pull requests your way.
 The other option is to try and get it into the macromates svn
 repository.  I don't know the process for that though.


 - Dennis

 2009/3/24 Gareth McCumskey gmccums...@gmail.com:


 On Mon, Mar 23, 2009 at 8:43 PM, hsteckylf j...@jncissler.com wrote:


 Also, a larger task might be doing an autocomplete of model getter
 and
 setter functions.

 You mean just like Eclipse PDT can already do? :P




 

 --
 Jacob Coby







 


--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Eno

On Tue, 24 Mar 2009, dziobacz wrote:

 I don't have this errors without constructor.

If you just need to set a variable before an action method is called then 
use PreExecute() as someone else suggested earlier. That's the normal way 
to do it.



-- 



--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Fási Gábor

Most probably because the sfComponent's constructor needs 3 parameters.

On Tue, Mar 24, 2009 at 17:25, dziobacz aaabbbcccda...@gmail.com wrote:

 Heh - ok so:

 private $ident;

  public function __construct()
  {
         parent::__construct();
        $this-ident=2;
  }

 but I have still errors:
 Missing argument 1 for sfComponent::__construct()
 Missing argument 2 for sfComponent::__construct()
 Missing argument 3 for sfComponent::__construct()
 Undefined variable: context
 Undefined variable: moduleName
 Undefined variable: actionName
 Call to a member function getEventDispatcher() on a non-object

 I don't have this errors without constructor.


 On 24 Mar, 17:16, Pierre p...@pierre-minnieur.de wrote:
 $this-ident ... ever heard of $this? ;)

 On 24 Mrz., 17:06, dziobacz aaabbbcccda...@gmail.com wrote:

  It doesn't work for me:

  class see_userActions extends sfActions
  {
    private $ident;

    public function __construct()
    {
          parent::__construct();
          $ident=2;
    }
  .

  }

  What can be the reason ?

  On 24 Mar, 16:41, Fási Gábor maerl...@gmail.com wrote:

   You can use __construct(), just like anywhere else in php. Remember to
   call parent::__construct().

   On Tue, Mar 24, 2009 at 16:11, dziobacz aaabbbcccda...@gmail.com wrote:

How can I make constructor in symfony ? I have tried:

class see_userActions extends sfActions
{
 private $id;

 public function initialize()
 {
        $id=2;
 }
.
}

Error:
Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
() should be compatible with that of sfAction::initialize()
Call to a member function notify() on a non-object

Why ??


 


--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Paolo Mainardi
On Tue, Mar 24, 2009 at 5:54 PM, Tomasz Ignatiuk
tomek.ignat...@gmail.comwrote:

 It worked, thank you very much!!! But how did you know? Why it is
 happening?


Because the prod controller, strip out all the php error reporting.

Check your action, probably there are some errors on Header generation code.

P.








 2009/3/24 Paolo Mainardi paolomaina...@gmail.com



 On Tue, Mar 24, 2009 at 5:46 PM, Tomasz Ignatiuk 
 tomek.ignat...@gmail.com wrote:

 I opened with a VIM. Many strange alphanumeric stuff inside but in the
 end there is a warning few times:


 bWarning/b:  Cannot modify header information - headers already sent
 by (output started at
 /home//apps/backend/modules/dokument/actions/actions.class.php:592) in
 b/home/../symfony/1.2/lib/response/sfWebResponse.class.php/b on line
 b335/bbr /

 592 line is: $response-setContent(readfile($sciezka));



 Try to export without the _dev frontend enabled.







 2009/3/24 Yevgeniy A. Viktorov w...@osmonitoring.com



 Open it as raw file, for example with the help of vim.

 Tomasz Ignatiuk wrote:
  File is damaged and it couldn't be repaired - this shows while I try
  to open it with adobe acrobat/reader. I don;t know how to check it in
  a different way.
 
  2009/3/24 Fási Gábor maerl...@gmail.com mailto:maerl...@gmail.com
 
  What's 'broken'? You mean you can't open it with adobe
 reader/other
  pdf viewer? If you check the contents of the file, does it look
 like a
  valid pdf?
 
  On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk
  tomek.ignat...@gmail.com mailto:tomek.ignat...@gmail.com
 wrote:
  
   Hi, I use this code for downloading files. If I download image,
 it
   works, but if I download pdf, after downloading when I try to
  open it,
   it is broken.
  
if (is_file($sciezka))
{
  // Enforce full download
  and prevent caching
  
   session_cache_limiter('none');
  
  // No layout needed for
  file downloads
  $this-setLayout(false);
  
   sfConfig::set('sf_web_debug', false);
  
  // Prepare http headers
  $fileType =
  $file-getFormat()-getNazwa();
  
  $response =
  $this-getResponse();
  
   $response-clearHttpHeaders();
  
   $response-setHttpheader('Pragma: public', true);
  
   $response-addCacheControlHttpHeader('Cache-Control', 'must-
   revalidate');
  
   $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
   GMT');
  
   $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
   H:i:s) .  GMT);
  
   $response-setContentType($fileType,true);
  
   $response-setHttpHeader('Content-Description', 'File Transfer');
  
   $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
   true);
  
   $response-setHttpHeader('Content-Length', filesize('' . (string)
   utf8_decode($sciezka . '')));
  
   $response-setHttpHeader('Content-Disposition', 'attachment;
   filename=' . str_replace( , _, utf8_decode($file-
  getFileNazwaOrginalna())) );
  
  // Unlock session in
  order to prevent php session warnings
  
  $this-getUser()-shutdown();
  
  // Send http headers to
  user client
  
  $response-sendHttpHeaders();
  
  // Send file to user
 client
  
   //$response-setContent(readfile(utf8_decode($sciezka)));
  
   $response-setContent(readfile($sciezka));
  
   //$response-setContent(file_get_contents(utf8_decode($file-
  getPath(;
  $response-sendContent();
  
  // Exit without a
 template
  return sfView::NONE;
  
  
   This line gives a proper mime type
   $response-setContentType($fileType, true);
  
   fileType is taken from DB. These are: application/pdf and
 image/jpeg
  
   It is strange because locally on apache on windows it works, but
 not
   on production server. Locally when I upload file its pdf mime
  type is
   application/x-download. On production server it is
 application/pdf
  
   Any ideas what is the problem?
   
  
 
 
 
 
  








 --
 Paolo Mainardi

 CTO Twinbit
 Blog: http://www.paolomainardi.com





 



-- 
Paolo Mainardi

CTO Twinbit
Blog: http://www.paolomainardi.com

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
symfony users group.
To post 

[symfony-users] Re: symfony textmate bundle

2009-03-24 Thread Fási Gábor

 strg?  is that command?


Ctrl

--~--~-~--~~~---~--~~
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: Best practice for multiple dynamic databases using symfony and Doctrine

2009-03-24 Thread Filipe Costa
I spend the all day with this and nothing, if you can give your igm contact
so i can talk abou it i will apreciate

cums

On Tue, Mar 24, 2009 at 11:59 AM, David Herrmann d...@okto.tv wrote:


 Filipe Costa wrote:
  see this
 
 http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59

 This looks interesting... I think the way to go for me will be to
 manipulate the databases in sfDatabaseManager while the routing is done.
 As soon as I have some code to share I'll post a snippet or write a blog
 post (might still be a few weeks until then).

 Thanks

 David

 


--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Tomasz Ignatiuk

No erros in log, but this headers already sent is strange.

On 24 Mar, 18:32, Paolo Mainardi paolomaina...@gmail.com wrote:
 On Tue, Mar 24, 2009 at 5:54 PM, Tomasz Ignatiuk
 tomek.ignat...@gmail.comwrote:

  It worked, thank you very much!!! But how did you know? Why it is
  happening?

 Because the prod controller, strip out all the php error reporting.

 Check your action, probably there are some errors on Header generation code.

 P.





  2009/3/24 Paolo Mainardi paolomaina...@gmail.com

  On Tue, Mar 24, 2009 at 5:46 PM, Tomasz Ignatiuk 
  tomek.ignat...@gmail.com wrote:

  I opened with a VIM. Many strange alphanumeric stuff inside but in the
  end there is a warning few times:

  bWarning/b:  Cannot modify header information - headers already sent
  by (output started at
  /home//apps/backend/modules/dokument/actions/actions.class.php:592) in
  b/home/../symfony/1.2/lib/response/sfWebResponse.class.php/b on line
  b335/bbr /

  592 line is: $response-setContent(readfile($sciezka));

  Try to export without the _dev frontend enabled.

  2009/3/24 Yevgeniy A. Viktorov w...@osmonitoring.com

  Open it as raw file, for example with the help of vim.

  Tomasz Ignatiuk wrote:
   File is damaged and it couldn't be repaired - this shows while I try
   to open it with adobe acrobat/reader. I don;t know how to check it in
   a different way.

   2009/3/24 Fási Gábor maerl...@gmail.com mailto:maerl...@gmail.com

       What's 'broken'? You mean you can't open it with adobe
  reader/other
       pdf viewer? If you check the contents of the file, does it look
  like a
       valid pdf?

       On Tue, Mar 24, 2009 at 12:51, Tomasz Ignatiuk
       tomek.ignat...@gmail.com mailto:tomek.ignat...@gmail.com
  wrote:

        Hi, I use this code for downloading files. If I download image,
  it
        works, but if I download pdf, after downloading when I try to
       open it,
        it is broken.

                 if (is_file($sciezka))
                 {
                                               // Enforce full download
       and prevent caching

        session_cache_limiter('none');

                                               // No layout needed for
       file downloads
                                               $this-setLayout(false);

        sfConfig::set('sf_web_debug', false);

                                               // Prepare http headers
                                               $fileType =
       $file-getFormat()-getNazwa();

                                               $response =
       $this-getResponse();

        $response-clearHttpHeaders();

        $response-setHttpheader('Pragma: public', true);

        $response-addCacheControlHttpHeader('Cache-Control', 'must-
        revalidate');

        $response-setHttpHeader('Expires', 'Sat, 26 Jul 1997 05:00:00
        GMT');

        $response-setHttpHeader(Last-Modified, gmdate(D, d M Y
        H:i:s) .  GMT);

        $response-setContentType($fileType,true);

        $response-setHttpHeader('Content-Description', 'File Transfer');

        $response-setHttpHeader('Content-Transfer-Encoding', 'binary',
        true);

        $response-setHttpHeader('Content-Length', filesize('' . (string)
        utf8_decode($sciezka . '')));

        $response-setHttpHeader('Content-Disposition', 'attachment;
        filename=' . str_replace( , _, utf8_decode($file-
       getFileNazwaOrginalna())) );

                                               // Unlock session in
       order to prevent php session warnings

   $this-getUser()-shutdown();

                                               // Send http headers to
       user client

   $response-sendHttpHeaders();

                                               // Send file to user
  client

        //$response-setContent(readfile(utf8_decode($sciezka)));

        $response-setContent(readfile($sciezka));

        //$response-setContent(file_get_contents(utf8_decode($file-
       getPath(;
                                               $response-sendContent();

                                               // Exit without a
  template
                                               return sfView::NONE;

        This line gives a proper mime type
        $response-setContentType($fileType, true);

        fileType is taken from DB. These are: application/pdf and
  image/jpeg

        It is strange because locally on apache on windows it works, but
  not
        on production server. Locally when I upload file its pdf mime
       type is
        application/x-download. On production server it is
  application/pdf

        Any ideas what is the problem?

  --
  Paolo Mainardi

  CTO Twinbit
  Blog:http://www.paolomainardi.com

 --
 Paolo Mainardi

 CTO Twinbit
 Blog:http://www.paolomainardi.com
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
symfony users group.
To post to this group, send 

[symfony-users] Re: constructor in symfony

2009-03-24 Thread dziobacz

So in symfony doesn't exist normal constructor ?


On 24 Mar, 18:14, Fási Gábor maerl...@gmail.com wrote:
 Most probably because the sfComponent's constructor needs 3 parameters.

 On Tue, Mar 24, 2009 at 17:25, dziobacz aaabbbcccda...@gmail.com wrote:

  Heh - ok so:

  private $ident;

   public function __construct()
   {
          parent::__construct();
         $this-ident=2;
   }

  but I have still errors:
  Missing argument 1 for sfComponent::__construct()
  Missing argument 2 for sfComponent::__construct()
  Missing argument 3 for sfComponent::__construct()
  Undefined variable: context
  Undefined variable: moduleName
  Undefined variable: actionName
  Call to a member function getEventDispatcher() on a non-object

  I don't have this errors without constructor.

  On 24 Mar, 17:16, Pierre p...@pierre-minnieur.de wrote:
  $this-ident ... ever heard of $this? ;)

  On 24 Mrz., 17:06, dziobacz aaabbbcccda...@gmail.com wrote:

   It doesn't work for me:

   class see_userActions extends sfActions
   {
     private $ident;

     public function __construct()
     {
           parent::__construct();
           $ident=2;
     }
   .

   }

   What can be the reason ?

   On 24 Mar, 16:41, Fási Gábor maerl...@gmail.com wrote:

You can use __construct(), just like anywhere else in php. Remember to
call parent::__construct().

On Tue, Mar 24, 2009 at 16:11, dziobacz aaabbbcccda...@gmail.com 
wrote:

 How can I make constructor in symfony ? I have tried:

 class see_userActions extends sfActions
 {
  private $id;

  public function initialize()
  {
         $id=2;
  }
 .
 }

 Error:
 Strict Standards: Declaration of 
 zobacz_uzytkownikaActions::initialize
 () should be compatible with that of sfAction::initialize()
 Call to a member function notify() on a non-object

 Why ??


--~--~-~--~~~---~--~~
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: Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread Michal G

Hello,

Couple of reasons why i've chosen Doctrine instead of Propel:
- far, far, far, far better documentation
- IMHO more readable queries with DQL than with criterions
- code is maintained and actively developed - this means that bug will
be fixed and support for new version of dbm's will be provided. Also i
can use cool new features ;)
--~--~-~--~~~---~--~~
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] SfWidgetFormDoctrineChoice - how do you filter values

2009-03-24 Thread fredlab

Hey,

Imagine I have the following :

$w = new sfWidgetFormDoctrineChoice(array(
  'model' = 'Codetype',
  'add_empty' = false,
));

Where table codetype has :

id,
codetype,
value

Example of the table is :

id |codetype|  value

1   book book1
2   book book2
3   framework symfony
4   framework fram2
5   ..

I tought I could use the query option to filter the list of choices
returned by the snippet but I cannot get it to work.

For example, instead of having the whole table records, I would like
the results to be filtered and get records that have the codetype
equal to 'framework'.

Does anyone as an idea on how to do that ?

Regards,

Frédéric.

--~--~-~--~~~---~--~~
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: SfWidgetFormDoctrineChoice - how do you filter values

2009-03-24 Thread Ian P. Christian

2009/3/24 fredlab frederic.beauf...@free.fr:

 Hey,

 Imagine I have the following :

 $w = new sfWidgetFormDoctrineChoice(array(
  'model'     = 'Codetype',
  'add_empty' = false,
 ));

From the source:

 71   public function getChoices()
 72   {
 73 $choices = array();
 74 if (false !== $this-getOption('add_empty'))
 75 {
 76   $choices[''] = true === $this-getOption('add_empty') ? '' :
$this-getOption('add_empty');
 77 }
 78
 79 if (is_null($this-getOption('table_method')))
 80 {
 81   $query = is_null($this-getOption('query')) ?
Doctrine::getTable($this-getOption('model'))-createQuery() :
$this-getOption('query');
 82   if ($order = $this-getOption('order_by'))
 83   {
 84 $query-addOrderBy($order[0] . ' ' . $order[1]);
 85   }
 86   $objects = $query-execute();
 87 } else {
 88   $tableMethod = $this-getOption('table_method');
 89   $results =
Doctrine::getTable($this-getOption('model'))-$tableMethod();

so - looks like you just set a table_method, and put the logic into your Table!

Hope this helps,

Ian

http://twitter.com/ipchristian
http://pookey.co.uk/blog

--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Ian P. Christian

2009/3/24 dziobacz aaabbbcccda...@gmail.com:

 So in symfony doesn't exist normal constructor ?

Define normal?  It is normal, it just has parameters - this is
standard OOP. If you want to override a constructor from a base class,
you'll need to call it's parent with the params it requires.

Check the API docs for sfAction and you'll most likely see what's expected.

Alternatively try using preExecute() as previously suggested.

Hope this helps,

-- 
Blog: http://pookey.co.uk/blog
Follow me on twitter: http://twitter.com/ipchristian

--~--~-~--~~~---~--~~
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: Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread Nathanael D. Noblet

Michal G wrote:
 Hello,
 
 Couple of reasons why i've chosen Doctrine instead of Propel:
 - far, far, far, far better documentation
 - IMHO more readable queries with DQL than with criterions
 - code is maintained and actively developed - this means that bug will
 be fixed and support for new version of dbm's will be provided. Also i
 can use cool new features ;)

The reasons I chose doctrine over propel almost 2 years ago were:

Two way relations, no more do I have to spend hours writing my own 
doSelectJoinXButNotYWithZAndTheKitchenSink() functions to join what I 
want. Propel would only do it one way, like a User has a Profile, but if 
you had a Profile object you couldn't join the user ugh such a pain. 
Now creating a custom query is a matter of a couple lines, a few 
minutes, instead of a few hours dealing with hydration of results.

Inheritance. It allowed me to solve many problems really easily.

M2M was *WWAA* easier.

Active / responsive community


-- 
Nathanael d. Noblet
T: 403.875.4613

--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Eno

On Tue, 24 Mar 2009, dziobacz wrote:

 So in symfony doesn't exist normal constructor ?

I think a lot of us want to ask: why do you want to do this?



-- 



--~--~-~--~~~---~--~~
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: VOIP integration

2009-03-24 Thread Sid Bachtiar

Hi Pablo,

In that case, thank you for the Jabber plugin. I have yet to try it,
but I can see it being very useful.

Yeah, I think you should post an announcement in this mailing list and forum.

On Wed, Mar 25, 2009 at 1:46 AM, Pablo Godel pgo...@gmail.com wrote:
 I have experience with VOIP and will probably be looking into developing
 some integration between symfony and Asterisk, but it may be months away.
 And by the way, I am the developer of the Jabber plugin :) I will post an
 announcement since it looks like most people are not aware.
 Pablo

 On Tue, Mar 24, 2009 at 7:32 AM, Sid Bachtiar sid.bacht...@gmail.com
 wrote:

 I was not aware of that jabber plugin! A very nice plugin ... thank
 you for making me aware of it :-)

 On Wed, Mar 25, 2009 at 12:27 AM, Paolo Mainardi
 paolomaina...@gmail.com wrote:
 
 
  On Tue, Mar 24, 2009 at 12:22 PM, Sid Bachtiar sid.bacht...@gmail.com
  wrote:
 
  I think I understand now. They're talking about VOIP
  service/management (like Jaxtr), not developing VOIP client like Skype
  using Symfony Framework.
 
  Well, Symfony plugin is easy to develop, just need someone with
  experience in VOIP service :)
 
  Yes, and could be a very nice plugin to write for Symfony, another
  little
  piece of external world integration (like the last Jabber plugin).
 
 
 
 
 
  On Wed, Mar 25, 2009 at 12:19 AM, Gareth McCumskey
  gmccums...@gmail.com
  wrote:
   -SIGH-
  
   I never said it was totally impossible to achieve. I simply said that
   expecting it to be as easy as a plugin is expecting far too much. And
   Sid is
   right, its not possible to get PHP/JavaScript to take input from a
   users
   microphone to allow VOIP so right now...
  
   Your best bet is to see if the likes of Skype have released a Java
   Applet
   or Flash SWF that might run its VOIP network from a website. - My
   Previous
   email
  
   Please don't read into my comments that which is not there.
  
   Gareth
  
   On Tue, Mar 24, 2009 at 12:35 PM, Paolo Mainardi
   paolomaina...@gmail.com
   wrote:
  
  
   On Tue, Mar 24, 2009 at 7:25 AM, Gareth McCumskey
   gmccums...@gmail.com
   wrote:
  
   Thats kind of an arbitrary question. VOIP isn't a web application
   technology in the vein of symfony and PHP. You will need far more
   than
   a
   plugin for symfony to employ VOIP. Your best bet is to see if the
   likes of
   Skype have released a Java Applet or Flash SWF that might run its
   VOIP
   network from a website.
  
   I disagree.
  
   There are a lot of possibilities to using Voip SERVER on top of web
   application, for example the Asterisk API:
  
   http://code.google.com/p/asterisk-php-api/
  
  
  
  
   Your question is like asking if we can get a plugin to run our own
   television channel on a website. Its a seperate technology with its
   own
   needs and wants and not just another feature that can be included.
  
   No, it's not the same, if we are integrating opensource technology,
   it's
   not like embed a tv channel in a web application, otherwise other
   kind
   of
   integration (IM ?) wouldn't ever possible.
  
  
  
   --
   Paolo Mainardi
  
   CTO Twinbit
   Blog: http://www.paolomainardi.com
  
  
  
  
   
  
 
 
 
  --
  Blue Horn Ltd - System Development
  http://bluehorn.co.nz
 
 
 
 
 
  --
  Paolo Mainardi
 
  CTO Twinbit
  Blog: http://www.paolomainardi.com
 
  
 



 --
 Blue Horn Ltd - System Development
 http://bluehorn.co.nz




 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: constructor in symfony

2009-03-24 Thread Sid Bachtiar

Please read:

For Symfony 1.0:
http://www.symfony-project.org/book/1_0/06-Inside-the-Controller-Layer#chapter_06_actions

Or for Symfony 1.1:
http://www.symfony-project.org/book/1_1/06-Inside-the-Controller-Layer#chapter_06_actions

Or for Symfony 1.2:
http://www.symfony-project.org/book/1_2/06-Inside-the-Controller-Layer#Actions

It should answer all your questions about actions in Symfony.

I'd recommend you to use preExecute, but if you still want to use
__construct, try this (Symfony 1.2):

class see_userActions extends sfActions
{
  public function __construct($context, $moduleName, $actionName)
  {
// do your stuffs here

parent::__construct($context, $moduleName, $actionName);

// or here
  }
}

On Wed, Mar 25, 2009 at 4:11 AM, dziobacz aaabbbcccda...@gmail.com wrote:

 How can I make constructor in symfony ? I have tried:

 class see_userActions extends sfActions
 {
  private $id;

  public function initialize()
  {
         $id=2;
  }
 .
 }

 Error:
 Strict Standards: Declaration of zobacz_uzytkownikaActions::initialize
 () should be compatible with that of sfAction::initialize()
 Call to a member function notify() on a non-object

 Why ??
 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: Re : [symfony-users] sfGuardExtraPlugin

2009-03-24 Thread ckemmler

Great! Looking forward to use/debug it.
Will it have a captcha (hint)?


On Mar 24, 1:23 am, gimler gordon.fra...@web.de wrote:
 the doctrine version sfDoctrineGuardExtraPlugin work 100% with
 doctrine is testet and i use it in my live projects.

 the propel version sfGuardExtraPlugin didn't work i will fix it this
 week.

 greetings
 Gimler

 On 23 Mrz., 21:56, ckemmler ckemm...@gmail.com wrote:

  Hi Gimler,

  Good to know you're the plugin's owner :-)
  If I understand well, you have written the plugin, then ported it to
  propel without really testing it. Am I right?
  I don't really understand the dependencies to propel actually, please
  forgive my ignorance. So why/how was it working outside of propel?
  What was the original/primary intent of developing this plugin in the
  first place?

  I have awkardly posted a second post on only the registerPlugin
  problems that I have. I'll cross-post here for the record.

  I'm trying to have this module to work. Being new to symfony/php (from
  a java background), I'm also suprised that this module isn't more
  integrated into the platform.

  1. to make it work at all I had to manually uncomment the if(...)
  clause in the sfGuardExtraPlugin config so it now reads:
    $this-dispatcher-connect('routing.load_configuration', array
  ('sfGuardExtraRouting', 'listenToRoutingLoadConfigurationEvent'));

  2. The only things I could get now is a simplistic register form (w/o
  captcha); when I hit the request button though, I'm having this
  exception:

  You must pass an array parameter to the clean() method (this validator
  can only be used as a post validator).

  I could get rid of it by commenting out some validators in
  BasesfGuardFormRegister.class.php, but I don't know why they wouldn't
  work

  - 3. new exception:

  Call to undefined method BasesfGuardUser::merge

  So this is referring to the other plugin, sfGuardPlugin, and seems to
  indicate that the two plugins are not sync'd. Is it possible?

  Your help will be welcomed with extreme gratefulness!

  Candide
--~--~-~--~~~---~--~~
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: doctrine vs propel difference

2009-03-24 Thread ckemmler

OK I understand - that explains why sfGuardExtraPlugin doesn't work
(yet) under propel. Thanks!

On Mar 23, 8:45 pm, Jonathan Wage jonw...@gmail.com wrote:
 Yes. The merge() function is a part of Doctrine. I don't think Propel has
 this functionality.

 - Jon

 On Mon, Mar 23, 2009 at 7:06 PM, ckemmler ckemm...@gmail.com wrote:

  Is it possible that doctrine-generated model classes have a merge
  methods while propel-generated model classes haven't?

 --
 Jonathan H. Wage
 Open Source Software Developer  
 Evangelisthttp://www.jwage.comhttp://www.doctrine-project.orghttp://www.symfony-project.org
--~--~-~--~~~---~--~~
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: SfWidgetFormDoctrineChoice - how do you filter values

2009-03-24 Thread fredlab


Ian,

Thanks for the answers but even with the source code, I can't see how
to do it.

What do you mean by table-method ? What is the difference between it
and the query option that is also available ?

Thanks for helping,

Frédéric
--~--~-~--~~~---~--~~
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: SfWidgetFormDoctrineChoice - how do you filter values

2009-03-24 Thread Ian P. Christian

2009/3/24 fredlab frederic.beauf...@free.fr:
 Thanks for the answers but even with the source code, I can't see how
 to do it.

 What do you mean by table-method ? What is the difference between it
 and the query option that is also available ?

don't set a query option.
instead, set a table_method - for example 'getFrameworks'

This will cause the widget to call
WhateverTable-getFrameworks(), and use the returned data to populate
the dropdown.

-- 
Blog: http://pookey.co.uk/blog
Follow me on twitter: http://twitter.com/ipchristian

--~--~-~--~~~---~--~~
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] Multiple Databases doctrine on sf1.2

2009-03-24 Thread bue...@gmail.com

I have a problem using multiple databases in doctrine.

I  start by making a myFilter:

class myFilter extends sfFilter
{
  public function execute ($filterChain)
  {
// Code to execute before the action execution
  $env = $this-getContext()-getConfiguration()-getEnvironment
();
  $configuration = $this-getContext()-getInstance()-
getConfiguration()-getApplicationConfiguration(sfConfig::get
('sf_app'),$env,0);
  //print_r(sfConfig::getAll());
  $myDatabaseManager = new myDatabaseManager($configuration);
  $myDatabaseManager-initialize($configuration);

// Execute next filter in the chain
$filterChain-execute();
// Code to execute after the action execution, before the
rendering

  }
}

then i make a myDatabaseManager like this example:
http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59


class myDatabaseManager extends sfDatabaseManager{

public function initialize(sfApplicationConfiguration $config)
{

$test = myTools::getDatabase() ;

if(!isset($test)) $test = 'db' ;
$parameters = array(
'dsn' = 'mysql:host=localhost;dbname='.$test,
'username' = 'root',
'password' = 'root',
'name'= 'doctrine',
);
//echo sfContext::getInstance()-getUser()-
hasAttribute('new');
$database = new sfDoctrineDatabase( $parameters);
 /*$database-initialize(array(
  'name' = 'doctrine',
  'username' = 'root',
  'password' = 'root',
  'dsn' =
'mysql:host=localhost;dbname=dgsic_teste'));*/

$this-databases = $database;

$this-databases-connect();

}
}

On the filter.yml of the app I put:


rendering: ~
security:  ~

# insert your own filters here
database_new:
class: myFilter

cache: ~
common:~
execution: ~

But symfony always uses the connection from databases.yml. I override
sfDoctrineDatabase.class.php and notice that a connection prior to the
one i did is done to the database.yml  but don't know why.
Can you help me on this, dind't find any answers to the problem and I
google it.

thank you in advance.

Filipe Costa
--~--~-~--~~~---~--~~
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] Forms: isValid() == true, isBound() == true, but getValues() == null???

2009-03-24 Thread Nickolas Daskalou

sf 1.2, Propel 1.3.

I love Symfony. I hate the forms framework. Probably because I don't
understand how it all ties together. Anyway, my problem:

I've bound a form ($form-bind($tainted_values)) and $form-isValid()
returns true, as does $form-isBound().

However, when I try to access the values via $form-getValues(), I get
null. What's even more strange is that I can gain access to each value
individually like this:

$form['value_name']-getValue()

Note that this is a form I have manually created and extended from the
sfForm class.

Does anyone know what the  is going on?

How can I get access to all of the form values at once instead of
manually getting each one?
--~--~-~--~~~---~--~~
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: Download files - broken pdf

2009-03-24 Thread Eno

On Tue, 24 Mar 2009, Tomasz Ignatiuk wrote:

 No erros in log, but this headers already sent is strange.

Means you're action generated some output and often its from an error 
message or warning.



-- 
A


--~--~-~--~~~---~--~~
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: Forms: isValid() == true, isBound() == true, but getValues() == null???

2009-03-24 Thread Nickolas Daskalou
I found the problem. I had created a custom post validator like this:

class sfValidatorFoo extends sfValidatorBase
{
  public function doClean($value)
  {
  }
}

and because it doesn't return anything (null), all values were getting
filtered out. It works when I add this single line in the doClean() method:

return $value;

Thanks Nick. You're welcome Nick. Obama 2008.


2009/3/25 Nickolas Daskalou n...@daskalou.com

 sf 1.2, Propel 1.3.

 I love Symfony. I hate the forms framework. Probably because I don't
 understand how it all ties together. Anyway, my problem:

 I've bound a form ($form-bind($tainted_values)) and $form-isValid()
 returns true, as does $form-isBound().

 However, when I try to access the values via $form-getValues(), I get
 null. What's even more strange is that I can gain access to each value
 individually like this:

 $form['value_name']-getValue()

 Note that this is a form I have manually created and extended from the
 sfForm class.

 Does anyone know what the  is going on?

 How can I get access to all of the form values at once instead of
 manually getting each one?


--~--~-~--~~~---~--~~
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: Forms: isValid() == true, isBound() == true, but getValues() == null???

2009-03-24 Thread Sid Bachtiar

Can we see your form source code? It would be easier.

 What's even more strange is that I can gain access to each value
 individually like this:
 $form['value_name']-getValue()

What is so strange about that? It's a feature of PHP5, check
http://php.oregonstate.edu/manual/en/class.arrayaccess.php

On Wed, Mar 25, 2009 at 12:33 PM, Nickolas Daskalou n...@daskalou.com wrote:

 sf 1.2, Propel 1.3.

 I love Symfony. I hate the forms framework. Probably because I don't
 understand how it all ties together. Anyway, my problem:

 I've bound a form ($form-bind($tainted_values)) and $form-isValid()
 returns true, as does $form-isBound().

 However, when I try to access the values via $form-getValues(), I get
 null. What's even more strange is that I can gain access to each value
 individually like this:

 $form['value_name']-getValue()

 Note that this is a form I have manually created and extended from the
 sfForm class.

 Does anyone know what the  is going on?

 How can I get access to all of the form values at once instead of
 manually getting each one?
 




-- 
Blue Horn Ltd - System Development
http://bluehorn.co.nz

--~--~-~--~~~---~--~~
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: Multiple Databases doctrine on sf1.2

2009-03-24 Thread Jonathan Wage
Hmm...databases.yml supports multiple databases. Why don't you just specify
them there?

- Jon

On Tue, Mar 24, 2009 at 5:49 PM, bue...@gmail.com bue...@gmail.com wrote:


 I have a problem using multiple databases in doctrine.

 I  start by making a myFilter:

 class myFilter extends sfFilter
 {
  public function execute ($filterChain)
  {
// Code to execute before the action execution
  $env = $this-getContext()-getConfiguration()-getEnvironment
 ();
  $configuration = $this-getContext()-getInstance()-
 getConfiguration()-getApplicationConfiguration(sfConfig::get
 ('sf_app'),$env,0);
  //print_r(sfConfig::getAll());
  $myDatabaseManager = new myDatabaseManager($configuration);
  $myDatabaseManager-initialize($configuration);

// Execute next filter in the chain
$filterChain-execute();
// Code to execute after the action execution, before the
 rendering

  }
 }

 then i make a myDatabaseManager like this example:

 http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59


 class myDatabaseManager extends sfDatabaseManager{

public function initialize(sfApplicationConfiguration $config)
 {

$test = myTools::getDatabase() ;

if(!isset($test)) $test = 'db' ;
$parameters = array(
'dsn' = 'mysql:host=localhost;dbname='.$test,
'username' = 'root',
'password' = 'root',
'name'= 'doctrine',
);
//echo sfContext::getInstance()-getUser()-
 hasAttribute('new');
$database = new sfDoctrineDatabase( $parameters);
 /*$database-initialize(array(
  'name' = 'doctrine',
  'username' = 'root',
  'password' = 'root',
  'dsn' =
 'mysql:host=localhost;dbname=dgsic_teste'));*/

$this-databases = $database;

$this-databases-connect();

}
 }

 On the filter.yml of the app I put:


 rendering: ~
 security:  ~

 # insert your own filters here
 database_new:
class: myFilter

 cache: ~
 common:~
 execution: ~

 But symfony always uses the connection from databases.yml. I override
 sfDoctrineDatabase.class.php and notice that a connection prior to the
 one i did is done to the database.yml  but don't know why.
 Can you help me on this, dind't find any answers to the problem and I
 google it.

 thank you in advance.

 Filipe Costa
 



-- 
Jonathan H. Wage
Open Source Software Developer  Evangelist
http://www.jwage.com
http://www.doctrine-project.org
http://www.symfony-project.org

--~--~-~--~~~---~--~~
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: Multiple Databases doctrine on sf1.2

2009-03-24 Thread Filipe Costa
A client ask for a service that requires a new databse. I create a record in
my database, that is configured in the databases.yml. After that, I manually
create a new databases for that client.. The list of databases is in the
master database.

thanks
Filipe Costa

On Wed, Mar 25, 2009 at 12:14 AM, Jonathan Wage jonw...@gmail.com wrote:

 What is powering the list of databases to instantiate?

 - Jon


 On Tue, Mar 24, 2009 at 7:11 PM, Filipe Costa bue...@gmail.com wrote:

 they are dynamic, I have N databases.

 thanks
 Filipe Costa

 On Wed, Mar 25, 2009 at 12:03 AM, Jonathan Wage jonw...@gmail.comwrote:

 Hmm...databases.yml supports multiple databases. Why don't you just
 specify them there?

 - Jon


 On Tue, Mar 24, 2009 at 5:49 PM, bue...@gmail.com bue...@gmail.comwrote:


 I have a problem using multiple databases in doctrine.

 I  start by making a myFilter:

 class myFilter extends sfFilter
 {
  public function execute ($filterChain)
  {
// Code to execute before the action execution
  $env = $this-getContext()-getConfiguration()-getEnvironment
 ();
  $configuration = $this-getContext()-getInstance()-
 getConfiguration()-getApplicationConfiguration(sfConfig::get
 ('sf_app'),$env,0);
  //print_r(sfConfig::getAll());
  $myDatabaseManager = new myDatabaseManager($configuration);
  $myDatabaseManager-initialize($configuration);

// Execute next filter in the chain
$filterChain-execute();
// Code to execute after the action execution, before the
 rendering

  }
 }

 then i make a myDatabaseManager like this example:

 http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59


 class myDatabaseManager extends sfDatabaseManager{

public function initialize(sfApplicationConfiguration $config)
 {

$test = myTools::getDatabase() ;

if(!isset($test)) $test = 'db' ;
$parameters = array(
'dsn' = 'mysql:host=localhost;dbname='.$test,
'username' = 'root',
'password' = 'root',
'name'= 'doctrine',
);
//echo sfContext::getInstance()-getUser()-
 hasAttribute('new');
$database = new sfDoctrineDatabase( $parameters);
 /*$database-initialize(array(
  'name' = 'doctrine',
  'username' = 'root',
  'password' = 'root',
  'dsn' =
 'mysql:host=localhost;dbname=dgsic_teste'));*/

$this-databases = $database;

$this-databases-connect();

}
 }

 On the filter.yml of the app I put:


 rendering: ~
 security:  ~

 # insert your own filters here
 database_new:
class: myFilter

 cache: ~
 common:~
 execution: ~

 But symfony always uses the connection from databases.yml. I override
 sfDoctrineDatabase.class.php and notice that a connection prior to the
 one i did is done to the database.yml  but don't know why.
 Can you help me on this, dind't find any answers to the problem and I
 google it.

 thank you in advance.

 Filipe Costa




 --
 Jonathan H. Wage
 Open Source Software Developer  Evangelist
 http://www.jwage.com
 http://www.doctrine-project.org
 http://www.symfony-project.org









 --
 Jonathan H. Wage
 Open Source Software Developer  Evangelist
 http://www.jwage.com
 http://www.doctrine-project.org
 http://www.symfony-project.org

 


--~--~-~--~~~---~--~~
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: Multiple Databases doctrine on sf1.2

2009-03-24 Thread Jonathan Wage
Hmm. I was looking around sfDatabaseManager and I see this:

public function initialize(sfProjectConfiguration $configuration)

The signature of your function in your code is not the same. I am pretty
sure php would throw an error there. Try double checking the code in
sfDatabaseManager and sfDoctrineDatabase to make sure you are overriding all
the right methods appriopriately.

- Jon

On Tue, Mar 24, 2009 at 7:27 PM, Filipe Costa bue...@gmail.com wrote:

 A client ask for a service that requires a new databse. I create a record
 in my database, that is configured in the databases.yml. After that, I
 manually create a new databases for that client.. The list of databases is
 in the master database.

 thanks
 Filipe Costa


 On Wed, Mar 25, 2009 at 12:14 AM, Jonathan Wage jonw...@gmail.com wrote:

 What is powering the list of databases to instantiate?

 - Jon


 On Tue, Mar 24, 2009 at 7:11 PM, Filipe Costa bue...@gmail.com wrote:

 they are dynamic, I have N databases.

 thanks
 Filipe Costa

 On Wed, Mar 25, 2009 at 12:03 AM, Jonathan Wage jonw...@gmail.comwrote:

 Hmm...databases.yml supports multiple databases. Why don't you just
 specify them there?

 - Jon


 On Tue, Mar 24, 2009 at 5:49 PM, bue...@gmail.com bue...@gmail.comwrote:


 I have a problem using multiple databases in doctrine.

 I  start by making a myFilter:

 class myFilter extends sfFilter
 {
  public function execute ($filterChain)
  {
// Code to execute before the action execution
  $env = $this-getContext()-getConfiguration()-getEnvironment
 ();
  $configuration = $this-getContext()-getInstance()-
 getConfiguration()-getApplicationConfiguration(sfConfig::get
 ('sf_app'),$env,0);
  //print_r(sfConfig::getAll());
  $myDatabaseManager = new myDatabaseManager($configuration);
  $myDatabaseManager-initialize($configuration);

// Execute next filter in the chain
$filterChain-execute();
// Code to execute after the action execution, before the
 rendering

  }
 }

 then i make a myDatabaseManager like this example:

 http://groups.google.com/group/symfony-users/browse_thread/thread/b89bcc66e3b70a59


 class myDatabaseManager extends sfDatabaseManager{

public function initialize(sfApplicationConfiguration $config)
 {

$test = myTools::getDatabase() ;

if(!isset($test)) $test = 'db' ;
$parameters = array(
'dsn' = 'mysql:host=localhost;dbname='.$test,
'username' = 'root',
'password' = 'root',
'name'= 'doctrine',
);
//echo sfContext::getInstance()-getUser()-
 hasAttribute('new');
$database = new sfDoctrineDatabase( $parameters);
 /*$database-initialize(array(
  'name' = 'doctrine',
  'username' = 'root',
  'password' = 'root',
  'dsn' =
 'mysql:host=localhost;dbname=dgsic_teste'));*/

$this-databases = $database;

$this-databases-connect();

}
 }

 On the filter.yml of the app I put:


 rendering: ~
 security:  ~

 # insert your own filters here
 database_new:
class: myFilter

 cache: ~
 common:~
 execution: ~

 But symfony always uses the connection from databases.yml. I override
 sfDoctrineDatabase.class.php and notice that a connection prior to the
 one i did is done to the database.yml  but don't know why.
 Can you help me on this, dind't find any answers to the problem and I
 google it.

 thank you in advance.

 Filipe Costa




 --
 Jonathan H. Wage
 Open Source Software Developer  Evangelist
 http://www.jwage.com
 http://www.doctrine-project.org
 http://www.symfony-project.org









 --
 Jonathan H. Wage
 Open Source Software Developer  Evangelist
 http://www.jwage.com
 http://www.doctrine-project.org
 http://www.symfony-project.org




 



-- 
Jonathan H. Wage
Open Source Software Developer  Evangelist
http://www.jwage.com
http://www.doctrine-project.org
http://www.symfony-project.org

--~--~-~--~~~---~--~~
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: Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread Campezzi

Hello everyone,

Thanks for the replies. From what I heard, I'd better take a closer
look into Doctrine before sealing the deal with Propel. At the
moment, I'm inclined to think that working with Propel is a bit more
intuitive (at least it has been easier for me to understand), but I
have already run into some JOIN quirks. Also, the Behaviors in
Doctrine seem to be especially useful for the project I'm starting
now, which will only use soft deletes - to accomplish that in Propel,
I was overriding the doSelect and doDelete methods in every peer class
- quite a bit of work!

Kind Regards,

Campezzi



On Mar 24, 9:58 am, Campezzi campe...@gmail.com wrote:
 Hello there,

 I've been a PHP developer for some time now, and recently I began
 exploring the world of Symfony. So far, I like what I see, but there's
 one thing that I still haven't quite figured out: in a real-world
 environment, what are the basic advantages and drawbacks of Propel and
 Doctrine?

 I think the only way of getting a realistic answer is to ask people
 who are clearly more experienced with real projects using sf than me.
 So, if you feel like it, please share a quick view on what you love
 and hate about Propel and Doctrine! :)

 Cheers!
--~--~-~--~~~---~--~~
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: Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread isleshocky77

Just wanted to point out that the benchmark is being done on Doctrine
version 0.10.2.  A LOT of work has been done on doctrine since and the
current doctrine included with symfony is 1.0 and the current stable
version of doctrine is 1.1 and much much more stable from the days
0.10.

P.s. No I'm not sure if the results would definitely be affected, but
I'd love to see the test re-run with current versions.

--
Stephen Ostrow sost...@sowebdesigns.com

On Mar 24, 9:17 am, Dheeraj Kumar Aggarwal dheerajcom...@gmail.com
wrote:
 Hi

 A comparison between LightORM, Propel and Doctrine is given at this link

 http://phplightorm.wiki.sourceforge.net/LightOrm+vs+Propel+vs+Doctrin...



 On Tue, Mar 24, 2009 at 6:28 PM, Campezzi campe...@gmail.com wrote:

  Hello there,

  I've been a PHP developer for some time now, and recently I began
  exploring the world of Symfony. So far, I like what I see, but there's
  one thing that I still haven't quite figured out: in a real-world
  environment, what are the basic advantages and drawbacks of Propel and
  Doctrine?

  I think the only way of getting a realistic answer is to ask people
  who are clearly more experienced with real projects using sf than me.
  So, if you feel like it, please share a quick view on what you love
  and hate about Propel and Doctrine! :)

  Cheers!

 --
 Regards,
 Dheeraj
--~--~-~--~~~---~--~~
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: Propel vs. Doctrine - Pros and Cons

2009-03-24 Thread Alistair MacDonald
Propel also has behaviours -- you just have to enable it when you build the
model.

What I find annoying is that whilst methods such as doDelete have multiple
extension points with behaviours the get/set functions have no override
points. This means that common code can't be added without editing the
classes -- or providing a custom generator class. (I have a versioning
mechanism that isn't restricted to a single table and also has 'states' --
individual objects may or may not be versioned/
require approval for changes. Each class has to override the setter for the
[common] fields which makes this happen in order to access the common code.
The delete aspect can be done using the built in behaviour hooks)

Alistair

On Mar 25, 2009 1:48 AM, Campezzi campe...@gmail.com wrote:


Hello everyone,

Thanks for the replies. From what I heard, I'd better take a closer
look into Doctrine before sealing the deal with Propel. At the
moment, I'm inclined to think that working with Propel is a bit more
intuitive (at least it has been easier for me to understand), but I
have already run into some JOIN quirks. Also, the Behaviors in
Doctrine seem to be especially useful for the project I'm starting
now, which will only use soft deletes - to accomplish that in Propel,
I was overriding the doSelect and doDelete methods in every peer class
- quite a bit of work!

Kind Regards,

Campezzi

On Mar 24, 9:58 am, Campezzi campe...@gmail.com wrote:  Hello there,  
I've been a PHP devel...

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---