Questions tagged [symfony1]

The first version of symfony, a full stack MVC framework for PHP 5.

Symfony is a full-stack PHP MVC framework

Symfony provides an architecture, components and tools for developers to build complex web applications faster. Choosing Symfony allows you to release your applications earlier, host and scale them without problem, and maintain them over time with no surprise.

Symfony is based on experience. It does not reinvent the wheel: it uses most of the best practices of web development and integrates some great third-party libraries.

Thousands of developers already trust Symfony for their applications!

Information

This tag is specific for the first version: symfony 1.x. There is also and for minor version.

Notice that, even if this version of Symfony is very stable and has been used in thousands of applications around the world, it is now outdated and surpassed by the superior version. As of November 2012, Symfony1 has reached his end of maintenance. If you are starting a new project, it is recommended that you use instead.

As of November 25, 2012 the latest stable release of symfony 1 is version 1.4.20.

Community

New users join the community every day, and that makes Symfony the most popular PHP framework around. A large community means easy-to-find support, user-contributed documentation, plugins, and free applications.

Speed

It aims to speed up the creation and maintenance of web applications, and to replace the repetitive coding tasks by power, control and pleasure.

The very small number of prerequisites makes Symfony easy to install on any configuration; you just need Unix or Windows with a web server and PHP installed. It is compatible with almost every database system. In addition, it has a very small overhead, so the benefits of the framework don't come at the cost of an increase of hosting costs.

Using Symfony is so natural and easy for people used to PHP and the design patterns of Internet applications that the learning curve is reduced to less than a day. The clean design and code readability will keep your delays short. Developers can apply agile development principles (such as DRY, KISS or the XP philosophy) and focus on applicative logic without losing time to write endless XML configuration files.

Robust

Symfony is aimed at building robust applications in an enterprise context. This means that you have full control over the configuration: from the directory structure to the foreign libraries, almost everything can be customized. To match your enterprise's development guidelines, Symfony is bundled with additional tools helping you to test, debug and document your project.

Last, but not least, by choosing Symfony you get the benefits of an active open-source community. It is entirely free and published under the MIT license.

Symfony is sponsored by Sensio Labs, a French Web agency.

Useful links:

In general:

For a migration/cohabitation with :

3991 questions
10
votes
3 answers

Symfony: email address as request parameter

I'm having some issues with passing an email address in a url to a symfony app. The url looks like example.com/unsubscribe/email/me@example.com It will always result in a sfError404Exception, except when the period is removed. After doing some…
pivotal
  • 736
  • 6
  • 16
10
votes
2 answers

PHP Post Data Over VPN

I need to connect to a webservice which is behind of a VPN via PHP. My server is Debian Linux (Squeeze). Is it possible to accomplish this via PHP on Linux? Is it risky to do this if it is possible? (When VPN connection hangs etc., does the…
Lashae
  • 1,372
  • 1
  • 20
  • 36
10
votes
2 answers

Porting a website from Symfony 1.4 to 2.0

I've got a huge site that has been written (in a very bad way) in symfony 1.4 now, I've been asked to make some substantial changes to the navigation flow, add some features and so on.. considering the effort, I was wondering if it would be better…
holographix
  • 2,497
  • 2
  • 32
  • 46
9
votes
2 answers

what's the proper way to use Symfony's EventDispatcher component?

I'd like to promote loose coupling in my PHP code, by making certain classes observable. Symfony's EventDispatcher component looks promising, as does the SPL SplObserver/SplSubject pair of classes. What's the best way to do this? I can see a couple…
Josh Johnson
  • 8,832
  • 4
  • 25
  • 31
9
votes
1 answer

How do you extend an entity in Symfony2 like you used to be able to in Symfony 1?

In older versions of Symfony you used to be able to build new objects within a data object by extending a model class with an extended subclass. For example, I had a questionnaire model that had a results table. That results table had a Result.php…
Adam Stacey
  • 2,833
  • 4
  • 26
  • 38
9
votes
2 answers

Sending POST Request to Secured Action

I have an action that takes POST data secured by sfGuard. This means that if the user is not logged in, the POST data will be sent to the log in form. Ordinarily, this is not a problem, the user continues to log in, and has to submit the data…
Druckles
  • 3,161
  • 2
  • 41
  • 65
9
votes
4 answers

Php framework : symfony 1, symfony 2 or Yii

We are going to switch from an homemade framework to Symfony or Yii. The capabilities of these two framework are, from our point of view, similar (ie they both have what we need). Our situation : php 5.2.9, medium-size website (10.000 uniques / day)…
Loïc Février
  • 7,540
  • 8
  • 39
  • 51
9
votes
3 answers

Connect to remote host from Aptana Studio 3 terminal

How to connect to remote host from Aptana Studio 3 terminal view, and use commands on that server? I'm using symfony framework, the project is in my host 192.168.0.100, so I want to run symfony commands like: $ symfony propel:build-schema
Almas Adilbek
  • 4,371
  • 10
  • 58
  • 97
9
votes
2 answers

Enable debug mode interactively in symfony

I'm using symfony 1.4 with Doctrine. I'm trying to find a way to enable debug mode only if the current sfUser has a special debugger credential. I already created a filter that deactivates the symfony debug bar if the sfUser has not this credential…
Phen
  • 2,313
  • 3
  • 18
  • 15
9
votes
4 answers

How to return specific status code (for example 24) in symfony

i need to return crazy http code statuses for API in symfony i need to return status code 24 i try to do it with: $this->getResponse()->setStatusCode('24'); but i'm always getting response code 500 when i try to return "normal" status code like…
Piotr M
  • 135
  • 1
  • 1
  • 3
9
votes
5 answers

No database connection via doctrine in symfony

I'm working on the symfony tutorial jobeet and I have problems to get a database connection to the MySQL-database via doctrine. Development enviroment: Mac OS X and XAMPP. The command php symfony doctrine:build-schema gives me the following error…
skanne
  • 198
  • 1
  • 2
  • 6
9
votes
3 answers

Where should "global" Symfony functions be placed?

What's the best practice for placement of functions that are used across multiple MVC layers? I've recently had to write some statistics functions that are used both in the View and the Model. If I put them in a helper, I'm stuck loading helpers in…
Jeremy Kauffman
  • 10,293
  • 5
  • 42
  • 52
9
votes
3 answers

Symfony route parameter requirement restriction

How do I enforce a requirement that a paramater in a route be a string? Given the route my_foobar_route: url: /example/routing/:s1/:id requirements: { id: \d+ } Can anyone remind me of how to force param s1 to be a string?
morpheous
  • 16,270
  • 32
  • 89
  • 120
9
votes
3 answers

Is there an OpenID 2.0 plugin for Symfony?

I am using sfOpenID plugin for Symfony, which doesn't support OpenID 2.0. That means, for example, that people using Yahoo! OpenID can't login to my site. There is an OpenID 2.0 plugin that works with sfGuard, but I am not using nor planning to use…
Tomas Kohl
  • 1,388
  • 1
  • 19
  • 27
9
votes
5 answers

Functional testing form with CSRF enabled in Symfony

What is the best way of creating functional tests to test forms with CSRF protection enabled in Symfony? Currently I have to add the following code before each form submittion: $form = new sfGuardFormSignin(); $token = $form->getCSRFToken(); …
Stepashka
  • 2,648
  • 20
  • 23