Browsing archives for 'symfony'

How to Setup sfPDOSessionStorage

Programming,symfony 16 June 2010 | View Comments

Setting up sfPDOSessionStorage is a fairly simple matter to make sure that sessions exist on a setup with multiple web-heads. Add the following code to your app//config/factories.yml file: all: storage: class: sfPDOSessionStorage param: db_table: session # table storing the sessions database: propel # database connection to use # Optional parameters db_id_col: sess_id # column storing [...]

Tagged in

Validate a Domain is Valid and Exists, Symfony 1.2

Programming,symfony 27 October 2009 | View Comments

When a good portion of my day is spent working with validating, parsing, and analyzing URLs – I find that I’ve written a small set of tools to ensure consistency, clean, and sane URLs. After an overhaul on a settings page – I had to integrate much of this into a simple (to the viewer, [...]

Modifying Form Elements in Symfony 1.2

Programming,symfony 15 October 2009 | View Comments

As I found in recent development of an app, I needed to change one of Symfony’s form on the fly (more specifically, I needed to change a drop-down, sfWidgetFormSelect). After some looking, there wasn’t much documentation on this that I could find. My final solution was easy enough: <?php $form = new SomeFancyForm(); $new_choices = [...]

Forcing SSL and HTTPS with Redirects on Symfony 1.2

Programming,symfony 1 September 2009 | View Comments

Forcing SSL on certain modules and actions used to be pretty simple with Symfony’s sfSslRequirementPlugin, however since Symfony 1.2 came out – it isn’t necessarily compatible. I took a look around the internet for options, however I was rather unsatisfied with the options. Because I need to be able to secure modules and actions, I [...]

Sane Pre-Commit Hooks for Symfony + Git

Programming,symfony 24 August 2009 | View Comments

Throughout my history of working with Symfony, I’ve noticed a trend that I’ll make a minor edit in a database configuration file, forget to actually regenerate the models and forms, commit the edit, and then find several days later (when I do want to regenerate the models) that they’re breaking. I then do this little dance of going through the history finding out where exactly I went wrong.

Tagged in , , , , , , , , ,