symfony

install sfSwiftPlugin for Symfony 1.4

I am using Symfony 1.4 as PHP framework, with Propel as ORM. I downloaded sfSwiftPlugin 1.5.1, but it was for 1.o version, and when installing it is giving me error you try to install a symfony 1.0 plugin. how can in upgrade the Plugin, or is there any other plugin for mailing purpose. Can we use the core PHP Mail function, in Symfony? ...

Symfony 1.4 doctrine - global database table prefix__%s

I need to set environment specific table prefixes, so i found unperfect solution in inserting this in ProjectConfiguration::configureDoctrine(Doctrine_Manager $manager): (config/ProjectConfiguration.class.php) if (sfConfig::get('app_database_table_prefix')) { $manager->setAttribute(Doctrine_Core::ATTR_TBLNAME_FORMAT, sfConfig::g...

Posterous API to post to posterous?

I am looking for a (PHP) tutorial that shows how I can programattically post contents of a blog on my site, to my posterous blog. In case there are no online resources, I will be grateful if someone could post a little snippet in here that shows how this cone be done. [Edit] In otherwords, I am looking for an example that posts a samp...

Symfony / Propel - retrieving old dates from a database

This is regarding Symfony 1.4, and probably all prior versions, running php 5.3, mysql 5.1. If I store old dates in a database < 1970..., and I then retrieve them, they are automatically converted into an incorrect date. Example table: id, some_date 1, 1961-09-09 A quick example. $record = MyTablePeer::retrieveByPK(1); echo $record...

What others see as URL when we work with localhost changed in the hosts file?

Hello, Let me introduce to the situation we had to face it and the core of the question. We needed in our project to change the "localhost" to be something else like "newdomain-localhost.com", so we changed the hosts file (in Windows) and everything worked. We reached the wall of Facebook with its sharer, where you need to get the sit...

Passing a propel criteria to the symfony routing function that retrieves the object

Hi guys, quick symfony / propel question. I have the following propel collection route: api_offer: class: sfPropelRouteCollection options: prefix_path: /api/offer model: Offer plural: offers singluar: offer actions: [ list ] module: apiOffer requirements: sf_format: (?:html|json) My question is, does ...

symfony sfDoctrineGuardPlugin generator.yml filtering by user_id

Hi all. I know it might seam slightly strange to user the admin generator.yml in the frontend but every page is either a list or an edit page and it's definitely the easiest things to do. After struggling with writing a log in module i have installed sfDoctrineGuardPlugin and used the relations to link them to my main user table. Ever...

Use Compass with symfony

I'm currently experimenting with Symfony/SASS/Compass. I use sfSassyCssPlugin (http://github.com/vicb/sfSassyCssPlugin) to automatically compile my .scss files. If i want to use compass with this plugin, do i need to modify the plugin to use another compiler (compass instead of sass)? How to use Compass best with Symfony projects? Than...

How to find table related with an alias in Doctrine ORM query?

I'm using Doctrine ORM 1.2 and Symfony 1.4 and I want to create method in myUser class which will extend Doctrine_Query instance passed as an argument with some additional left joins and conditions. The trick is that I don't always want these these left joins to be made with root component of the query and I need to know with what table ...

Config file in Symfony that is global to the project and can be used in models?

Is there a config file in Symfony 1.4 where you can place custom values that is accessible to your models? I was using app.yml in my frontend app so far but models are common for all applications in the project, so this won't work at the model level. ...

Symfony/sfDoctrineGuard Conditional Permissions

Hey All, I'm contemplating the best way to implement the conditional permissions i.e. Users and Teams are m-to-m. But each Team also has a 1-to-m "Leader" relationship with the User table as well. For simplicity sake, let's say we have two permission levels, "User" and "Admin". Then lets say, only certain Team administration task i.e. ...

Why use Symfony not Drupal

I've been using Drupal for some time and have been a bit frustrated with how it takes a lot more work to do things the Drupal way than if I were writing custom code from scratch. Sometimes I spend the day not coding, but just searching for the right solution to weave my idea into the drupal flow. This has led me to think of moving back a...

Working with Symfony and Git (collaboration)

Hello everyone, Suppose we have a Project with three applications — A, B and C. Our team: Jack, Susan and Martin. And one project leader — David. Each programmer is working on their own application: A - Jack B - Susan C - Martin So, there is a problem with source code management. How to effectively organize it with G...

sfDoctrineGuardPlugin + vjCommentPlugin

Hi. I'll have installed both plugins on my symfony project via official Readme, everything installed fine, without errors. But when I click on SendComment button, I have error: Empty module and/or action after parsing the URL But when I place cursor to the address bar and press enter, page refresh and I can see my page but without com...

a framework plugin in another framework (e.g. Symfony)

Is it possible to use a Symfony plugin in a CMS being built with another framework like Cake or Zend? How independent are those plugins? ...

For a new PHP project which framework should I choose Zend or Symfony?

I mostly come from Java background as have no up to date info on best practices regarding PHP, so please advise. We are about to start a PHP project for an application (no portal). The framework needs to be stable (no changing API between releases), need to scale well, support clustering maybe and obviously need to facilitate common pr...

symfony language select based on subdomain

My symfony app should get user's language from subdomain: en.project.com - for english fr.project.com - for french and so on... Special filter get 'GET' param 'lang' from current uri and save it in user attribute. How can I setup apache virtual host config for multiple subdomains? ...

setPeerCount doctrine equivalent

In propel setPeerCountMethod is used to change the count query in pagination. Does anybody know its equivalent in doctrine? ...

symfony 1.4 Doctrine stable photogallery plugin?

Hello, don't you know someone photogallery plugin. I would appreciate some functional backend mainly. It does'nt mather how frontend it has - will be rewritten. ...

schema.yml using sfDoctrineGuardPlugin

Hello, I'm building a schema.yml and I'm trying to add foreign key constraints to the table sf_guard_user. But, when I do doctrine:insert-sql (edit: doctrine:build --all), the links between my tables and sf_guard_user are not there ! Am I missing something ? I'm using mysql (InnoDB) and Symfony 1.4 Here's a sample of my schema.yml : ...