Symfony Resources Central

Web development made simple

sfGeshi plugin release

The sfGeshi plugin has been updated today to use latest GeSHi improvements, and to add some features. The SVN path changed too, to comply with symfony-project.com plugin repository naming conventions, so be sure to check out the documentation.

sfGeshi::getLanguages()

This static methods allow you to get an associative array of languages, with GeSHi language identifiers as keys and human readable language names as values.

<?php echo select_tag('language', options_for_select(sfGeshi::getLanguages(), $language)); ?>

sfGeshi::getPluginPath()

This convenience method has been added to allow you to call sfGeshiPlugin directory differently. It should be used if you need direct access to GeSHi files (like language highlighting definition files in /geshi/).

<?php
$files = sfFinder::type('file')->name('*.php')->in(sfGeshi::getPluginPath().'/geshi/');

foreach ($files as $file)
{
  echo $file . '=>' . basename($file, '.php');
}

Using DBMS functions with sfDoctrine

I recently had a peek on symfony forum, and seen someone asking "How can I make a SELECT count(*) FROM .... with doctrine?". An answer to such a question should be pretty obvious as it's of everyday use, but the question seems to have come to life many times as well on IRC than on the forum/mailing list. Here is my two-cents how-to.

Continue reading...

Testing Symfony 1.1

Wondering what symfony 1.1 will look like? Well, I couldn't hold my curiosity neither, so I upgraded one of my websites to symfony 1.1, and I describe here how to setup a box to run both versions. The upgrade process being definitive for a given project, make backups or svn commit before upgrading.

Continue reading...

A new index.php controller for subdomains

The default behaviour of symfony, is to create one myapp.php and one myapp_dev.php public controller by application, knowing that the first application you create will have its prod controller renamed to index.php (default application). But this behaviour can be easily overriden to take advantage of subdomains.

Continue reading...

sfGeshi plugin

sfGeshi's aim is a symfony plugin that integrates the Generic Syntax Highlighter PHP library (GeSHi) into the Symfony Framework. Supports 75 different languages, and you can add more by writing simple php files.

Related links:

Symfony 1.0 is out!

Despite the DIGG side effects of which symfony project server suffered because of heavy traffic brought by the well known social bookmarking site's homepage anouncing symfony's first "stable" release, the long awaited 1.0 version is here!

For thoose who don't know it, Symfony is a MVC (Model-View-Component) PHP5 framework aiming to Rapid Application Development and good codinig practices like the DRY (Don't Repeat Yourself) principle. Their main contributors, french developpers from Sensio Labs Fabien Potencier and François Zaninotto have written a very good documentation book about it, that you can either buy at amazon (for thoose who like holding a real book), or download/read freely on the symfony project website as a PDF file.

Supported by a large community, you'll find support about symfony in diverse flavour, from the symfony forum to different languages mailing lists, going thru #symfony and #symfony-fr (for french developpers) on Freenode IRC network.

As the official release note is saying: At last, the long-awaited 1.0 stable version of symfony is just released. For all those who waited for the "stable" status to dive into symfony, the time has come.

Some reference:

page 3 of 3 -

© Copyright 2007-2008 daKrazy. All rights reserved.

Design and template by hartym