Thursday, January 29, 2009

Magento a hope that will change the world....

Magento is a feature-rich eCommerce platform offering complete flexibility and control over the look, content and functionality
of an online store.

Key Features :-

Site Management
Control multiple websites and stores from one Administration Panel with ability to share as much or as little information as needed
Web Services API for easy integration between Magento and any third-party application

Marketing Promotions and Tools
Flexible Coupons (pricing rules) with ability to restrict to stores, customer groups, time period, products, and categories.

International Support
Multi-Lingual
Support for Multiple Currencies

Shipping
Shipping to multiple addresses in one order

Customer Accounts
Re-orders from account

Catalog Management
Batch Import and Export of catalog

Catalog Browsing

Layered / Faceted Navigation for filtering of products
Product comparisons

Wednesday, January 28, 2009

About symfony 1.3

Two years ago, it was about to release symfony 1.0. Since then, released symfony 1.1 in June 2008 and symfony 1.2 just two months ago. The 1.1 version of the framework was a major upgrade with a lot of changes to the internals. The 1.2 version finished the transition from the old form system to the new one with the new admin generator, and of course also came with its batch of other goodies.

Some time ago, Tim Ariyeh wrote a tweet about what he thinks about the latest releases:

"I think it's time we all admitted that symfony 1.2 should have been 2.0, and 1.1 should never have happened."

He is quite right, sometimes, we make mistakes. But this is now history and I'm quite happy with the state of symfony 1.2. The internals of symfony are rock solid, well decoupled, and easy to extend. It Now even support Doctrine natively. The documentation has also been updated accordingly with a new book, and a lot of new cookbook tutorials.
What?

First, don't expect big revolutions for symfony 1.3. The 1.3 release will be an evolution of the actual code base, made of polish, small enhancements, and optimisations. That means that one of the most important goal for symfony 1.3 is compatibility with 1.2. The tries are being done to ease the process of upgrading as much as possible. According to the symfony website statistics, symfony 1.2 is already, and by far, the most downloaded symfony version. And the Jobeet tutorial, which is based on symfony 1.2, has generated more than one million page views in less than two months.

You can now add your own ideas and vote for the ones you want to see implemented on a user voice page.

OUTDATED: Display user submitted images in their profile page

description

This snippet will display the thumbnail images of the most N most recently submitted images by the user. You can also optionally limit the images selected based on taxonomy term id's (see snippet for details)

instructions

  1. In a text editor paste the following snippet into your user_profile.tpl.php file
    (For instructions on how to get started with your own custom user profile layout click through to the Customising the user profile layout handbook page.)
  2. Upload your edited user_profile.tpl.php to your active theme folder
// Display N most recent thumbnails of images submitted by the user
// Each thumbnail is linked back to it's image node
// Can optional limit the photos shown by specififying one or taxonomy term id's

// The number of thumbnail images to show
$nlimit = 3;
$taxo_id = array();
// Add one line for each taxonomy term id you want to limit the thumbnails to
// As an example, the following two lines would select images associated with taxonomy terms 36 OR 37
// $taxo_id[] = 36;
// $taxo_id[] = 37;
// Note, if not taxonomy term ids are specified, the selection is from all the user submitted images

$userid=$user->uid;

if (
count($taxo_id) > 0 ) {
// Limit images based on taxonomy term id's
$taxo_str = implode(',', $taxo_id);
$sql = "SELECT n.created, n.title, n.nid, n.changed FROM node n INNER JOIN term_node ON n.nid = term_node.nid AND term_node.tid IN ($taxo_str) WHERE n.type = 'image' AND n.uid = $userid AND n.status = 1 ORDER BY n.changed DESC";
}
else {
$sql = "SELECT n.created, n.title, n.nid, n.changed FROM node n WHERE n.type = 'image' AND n.uid = $userid AND n.status = 1 ORDER BY n.changed DESC";
}

$result = db_query_range($sql, 0, $nlimit);
$output = '';
while (
$info = db_fetch_object($result) ) {
$node = node_load(array('nid' => $info->nid));
$img_tag = image_display($node, 'thumbnail');
$link = 'node/' . $node->nid;
$output .= l($img_tag, $link, array(), NULL, NULL, FALSE, TRUE);
}
print
$output;
?>

Tuesday, January 27, 2009

Who Wants a Free Web Application?

Looking for something to do with all that brain power? We're happy to announce an upcoming community event that will harness the power of the symfony community toward a variety of social causes. Help us get the word out!

This event will take on the basic structure of other 48 hour web application development competitions, such as Rails Rumble, but with a special twist unique to symfony. The applications we create during the course of the competition will be gifted to different socially-minded organizations around the world. Once the fun is over, our work will live on and hopefully do a lot of good.

A Call for Causes

The first thing we need is to determine who we're working for. If you are or know of a socially-minded organization that could benefit from an interactive web application, we want to hear from you.

Please submit a brief proposal for the application you would like built that includes the following:

  • A description of your organization (200 words or less)
  • A description of the application you would like built (400 words or less)

Please keep in mind these applications will be built in 48 hours or less by small development teams. If you're not sure how to gauge the effort involved in you proposal, just send in your idea and we'll help refine a reasonable scope.

Display recent nodes (titles & teasers) snippet

Description

This php snippet displays the 10 most recent nodes submitted by the user, restricting certain node types. In this example, pages, stories, and forum posts are excluded from the list.

Usage

• For use in a user profile page override
• Using a text editor like NOTEPAD.EXE or an equivalent, copy and paste the code into your user_profile.tpl.php file
• To increase/decrease the number of posts listed change the $nlimit value to suit. The default setting is 10.
• Tested and works with Drupal 4.6
• Change the div class names or the prefix text to suit.

= 10; ?>
=$user->uid; ?>
= pager_query(db_rewrite_sql("SELECT n.nid, n.created FROM {node} n WHERE n.status = 1 AND n.uid = $userid AND n.type != 'page' AND n.type != 'poll' AND n.type != 'forum' AND n.type != 'story' ORDER BY n.created DESC"), variable_get('default_nodes_main', $nlimit)); ?>
while ($node = db_fetch_object($result1)) {$output2 .= node_view(node_load(array('nid' => $node->nid)), 1);}; ?>
print $output2; ?>

Friday, January 23, 2009

Customising the user profile layout

(Thanks to Dublin Drupaller for starting this section of the handbook)

The PHP Snippets below are intended for use within a customised USER PROFILE page that simply enables you to “pull” specific content from your drupal database specific to a particular user and display it in the way you want.

They are intended for use with a phptemplate based theme and for Drupal site developers who do not have php programming knowledge but want to push out the boundaries of user profile pages and control precisely how they look.

See also Advanced Profile Kit for an alternate method of sprucing up your user profile pages.

Simple step-by-step instructions are provided.
The concept

Drupal is an extremely powerful tool for building online communities, in particular, allowing users to submit their own content to a community hub. A good illustration of this working well online might be the World famous myspace.com site, where bands/artists are able to submit content into their own page.

Drupal has all the tools available to create your own myspace.com style community hub.

These snippets are intended as a mini-repository and as an aid for site designers without php programming skills to create sophisticated User Profile Pages for members of their community.

Customised User Profile Pages maybe applied to many applications. myspace.com is primarily a site for artists & bands, but, similar techniques could be used for other applications such as a rzye.com (Drupal powered community hub) style professional networking hub or terminus1525 (Drupal powered community hub) for studios.
Getting Started - (Drupal 4.x and Drupal 5.x)

Step 1 - is to override the default User Profile page layout by uploading the special template.php file to your active theme folder.

$account, ‘fields’ => $fields));
}
?>

If you already have a template.php file in your active theme folder, simply add the above to the existing template.php file and upload it.

Step 2 - (Drupal 4.x and 5.x) is to create your customised user_profile.tpl.php file and upload that to your active theme folder.

If you’re starting from scratch, simply open notepad.exe or a similar text editor and paste in the snippets linked below to build your custom user profile page. Save it with the user_profile.tpl.php filename and upload it to your theme folder along with the template.php file.

Once you have got started with your first user_profile.tpl.php file, you can experiment with adding in more snippets or including HTML layout controls to get a feel for the flexibility this allows.
Getting Started - (Drupal 6.x)

Step 1 - is to override the default User Profile page layout by uploading a custom user-profile.tpl.php* file to your active theme folder.

Drupal will automatically detect the presence of your custom user-profile.tpl.php and override the default user profile layout. To make this happen, you need to rebuild the theme registry, which you can do by clearing the caches (for example using the button on the admin/settings/performance page), or simply by visiting the admin/build/modules page.

* note that in Drupal 6.x, your custom user profile layout file name uses a hyphen, instead of an underscore.

Step 2 - is to customise your user-profile.tpl.php layout file.

By default, all user profile data is printed out with the $user_profile variable. If there is a need to break it up you can use $profile instead.

As an example, the following snippet inserted in your custom user-profile.tpl.php will display the default user profile layout.

Available variables:

* $user_profile: All user profile data. Ready for print.
* $profile: Keyed array of profile categories and their items or other data provided by modules.

To check for all available data within $profile, insert the following snippet at the bottom of your custom user-profile.tpl.php.

Available variables

The following is a list of variables that is available to your custom user-profile.tpl.php.

'. check_plain(print_r($profile, 1)) .'

‘; ?>

How to use these snippets

Simply copy and paste these snippets into your custom user profile layout file and upload it to your active theme folder. Check to make sure that the snippet you are using is compatible for the version of Drupal you are using.

It’s recommended that you test your customised user_profile.tpl.php(Drupal 4.x or Drupal 5.x) or user-profile.tpl.php file (Drupal 6.x) on a test installation before adding to a live site.
Adding new snippets

Simply click on the ADD NEW CHILD PAGE link below and create a new handbook page. Include any dependencies, such as which version of Drupal you have tested the snippet with or extra modules that need to be enabled for the snippet to work.

PLEASE NOTE! The following snippets are user submitted. Use at your own risk! For users who have setup drupal using an alternate database to the default (MYSQL), please note that the snippets may contain some database queries specific to MYSQL.

* A basic User Profile Page to help get you started
* Customising the user profile pages (a “before” and “after” example with screenshots)
* User Profile avatar/picture Snippet
* Handling single-line profile fields
* Handling multi-line profile fields
* Handling checkbox profile fields
* Handling freeform profile fields
* Handling URL profile fields
* Recent weblog entries (titles) snippet
* Recent weblog entries (titles & teasers) snippet
* Add/delete to/from buddylist snippet
* Display a list of buddies snippet
* Display list of (x) recent posts (titles) snippet
* User “history” or “member for: (time)” snippet
* Adding layout and content to the default user profile theme
* allow users to choose whether certain profile fields are visible or hidden
* Allowing users to customize their profile
* Custom User Blocks and User Tables PHP Snippets
* Customising the user profile layout per role
* Display link to user’s embedded gallery (or not if it does not exist)
* Display a customisable “this user is [online/offline]” status message in the User Profile page
* Display a user friendly text message when profile fields are left blank
* Display a user’s points value from the userpoints.module
* Display recent nodes (titles & teasers) snippet
* Displaying counts from the Invite module
* Drupal V5.x warning: Cannot add header information
* Handling date profile fields
* Howto: Make the user profile layout compact (with css only)
* Insert Subscribed Organic Groups List
* Messages for unpublished profiles
* My Comments Block for Profiles
* Outputting full civiCRM profile to custom profile
* Outputting individual CiviCRM profile fields into custom Drupal profile
* User Profile Page
* User referral module
* Weight sorting for input fields (when the user fill the form) doesn’t apply - fix
* Insert user friendly “click here to add your..” links when user profile fields are left blank
* Display a date related notice or countdown snippet
* Send private message snippet
* Display a Skype “Call me” or “leave a voicemail” button depending on Users’ online/offline status
* Display users age based on a date-of-birth field
* insert a “view your order history” and “view [username]s store” link
* Show/hide certain profile fields depending on user role or user permissions

Thursday, January 22, 2009

Remove unwanted tabs from pages

Description

Some modules add tabs to pages that are not needed for general users, or not needed at all. You may wish to link to the page in a different way, as some users don't understand that they can click on the tab above a node.

There is currently no way to alter the hook_menu() generated tabs from code, so this function will find and strip out a tab based on its name.

Step 1 of 2

Locate your theme's template.php file. If one doesn't exist create an empty one. This is where you can place customisation PHP code.

Step 2 of 2

Custom functions placed in the themes template.php file should begin with the theme name. In the code snippet below replace "yourthemename" with the actual name of your theme, such as "bluemarine".

You may already have a '_phptemplate_variables' function defined depending on what theme you are using, if so do not include the function again from the snippet below.

function _phptemplate_variables($hook, $vars = array()) {

if(
$hook == 'page') {
yourthemename_removetab('address book', $vars);
// add additional lines here to remove other tabs
}

return
$vars;
}

function
yourthemename_removetab($label, &$vars) {
$tabs = explode("\n", $vars['tabs']);
$vars['tabs'] = '';

foreach(
$tabs as $tab) {
if(
strpos($tab, '>' . $label . '<') === FALSE) {
$vars['tabs'] .= $tab . "\n";
}
}
}
?>

The tab removal work is done in the yourthemename_removetab() function, pass in a plain text tab label, along with the PHPTemplate variables, and the function will remove the tab.

In the above example snippet the 'address book' tab added by the eCommerce package is removed from the users profile page.

Notes

  • Call yourthemename_removetab('tab name', $vars); for each tab you wish to remove.
  • No other modules need to be installed to use this.

Wednesday, January 21, 2009

symfony 1.2.2 - Doctrine service release

The symfony team sat together on a bugfixing day on Tuesday, resulting in over 40 closed tickets for 1.2.2. Pretty much for a bug-fix release. So wait no more, symfony 1.2.2 is now available. The main bugfixes included in it take care of issues in the sfDoctrinePlugin and its admin generator. We also include the fresh Doctrine 1.0.6 release, so you are getting the newest and best support for your favorite ORM.

The other batch of bug fixes takes care of Form framework related issues, like file uploads or presets, and some testing facilities were fixed.

If you use neither Doctrine nor the Form framework, a few performance improvements which were put into symfony for 1.2.2 might be of interest for you. Especially Ticket #5356 could be of interest for users with many small files cached. Feel free to run the tests on your box and append your results to the ticket.

The whole list of closed tickets can be found in the Trac Roadmap for 1.2.2 or the Changelog file

Upgrade

Please upgrade your existing projects by updating the reference to the 1.2.2 subversion tag or by running the PEAR upgrade command:

$ pear upgrade symfony/symfony-1.2.2

If you use the 1.2 branch from our SVN repository, just run the svn update command to upgrade your project.

Last but not least, don't forget to clear your cache by running for doctrine:

$ php symfony doctrine:build-model
$ php symfony doctrine:build-forms
$ php symfony doctrine:build-filters
$ php symfony cache:clear

or when using propel:

$ php symfony propel:build-model
$ php symfony propel:build-forms
$ php symfony propel:build-filters
$ php symfony cache:clear

and enjoy your shiny new symfony 1.2.2!

symfony 1.3

As a side task, I created the symfony 1.3 branch, which will now be the main development stream. Kris Wallsmith will be taking over the responsibility for this branch, I will try to keep 1.2 in a good shape.

Blog to it - The social blog directory

Blog to it is a social blog directory developed using 100% contrib modules. Well, there were a few tweaks to one module and a few more tweaks in the theme. This case study has been written to give an insight into how and why Blog to it was developed.

What is it?

"Do you have a blog that you would like to share with others? Do you enjoy reading blogs but don’t know where to effectively look for them? If you’re in this predicament, drop by Blog.to.it and take a look at what they have for you to enjoy.

Blog.to.it is a website that allows users to import all of their blog posts via RSS or start a new blog directly on their site. The site has eight different blog categories including technology, business, science, gaming, lifestyle, entertainment, sports, and other. Whatever you want to write or read about is easy to find, just look through the categories that interest you most.

Once posts are in they can be voted on, commented on, and sorted by rating, category, or date. Blog.to.it hopes to be a great place to find new blogs to read. The site merges loads of features from current sites and brings them to a new audience, the personal blogger. There are many blogs world wide and it is often hard to get noticed between all the corporate blogs out there, this site is trying to help bloggers come together in a space that’s just for them."
From Killer Startups

Features

  • Hosted user blogs - Just like on Blogger or Wordpress a user can start blogging on Blog to it, this isn't a key feature but was more or less there, so why not use it.
  • RSS user blog import - This is the key driver of the site by allowing users to add their existing blog posts automatically to Blog to it.
  • Blog post commenting - It was never fully decided if this should be on the site or not, should comments be on Blog to it or on the original blog. Maybe one to work on?
  • Blog post rating / voting - This also another key feature. The main way to view posts is by number of votes. (Digg like)
  • Browse posts by rating
  • Browse posts by date
  • Browse posts by category
  • Browse posts by user / blog
  • Browse blogs by tag
  • Personal and site wide Twitter updates - This is a really great feature to have. It both helps the user integrate more with the site, and is a great marketing tool. A lot of the traffic is coming from Twitter and Twitter aggregation.

How was it done?

Modules

Blog to it screenshot
The whole site was developed using Drupal 6 and then moved to Acquia Drupal once live. It is heavily based around the core blog module because user blogs are created in the default Drupal way, and RSS imports are imported into the Blog content type.

By using the DrupalMU Helper module which is part of the Drupal MU install profile it helped turn the core blog module into a multi-user blogging system and gives vital functions that were used when creating views and the theme.

One of the other key modules was the FeedAPI module which is used to import an external blog into the blog content type via RSS feed. The Content Profile was used to add the RSS feed URL field to the user's profile. Simple feed was also looked into as a way of importing feeds, but it didn't seem to attach the imported nodes to the user who setup the import. This may of been a development error rather than a fault with the module, but FeedAPI was suggested a better module, and it worked.

Posts can be voted on using the VotingAPI and Plus1 modules. Voting API was an obvious choice when creating a site that requires voting, but which module to use with Voting API was a harder choice. Drigg seems the most advanced to allow +1 and -1 voting, but this was not available for Drupal 6 (it was tested once the first 6 release and seemed too specific), so after spending a few hours installing, testing and uninstalling Plus1 seemed to offer what was needed for the Blog to it use case.

This site is not very complex, but works well. The uptake has been good and by adding Twitter integration this helps with marketing. The Twitter module allows each user to import their Twitter posts, and announce their new posts on Twitter. It also allows the announcement of all new posts via Triggers and Actions on http://twitter.com/blogtoitnew.

Views also plays a big part in this site, much like it does in other sites. It allows many pages to be developed showing the posts in different ways. There is one main view for the site which creates three pages for each category.

Theming

The theme was based upon Raincity's Basic theme, this really helped speed up development. There was very little special development in the theme. The only exciting aspect is the use of the Drupal MU helper functions. The function returns the UID of the user whose blog or profile is being viewed. This allowed custom theming for user pages such as hiding the Blog to it logo and displaying the site name.

Infrastructure

The site was developed on a budget VPS from VPS Empire who has now merged with VA Serv. After launch and after a lot of hunting a hosting partnership was found with Castlegem, so far the site has been running very well, and Castlegem were great at getting the server setup, including custom nameservers, DNS and backup.

What next?

Blog to it screenshot
Blog to it has currently been released as an Alpha version so many of the bugs can be ironed out. Development will continue until the beta version is ready early 2009.

So far very few bugs have been found, the hardest aspect seems to be perfecting the usability. For example, should anonymous users be able to vote and comment? what should be displayed on each page? what is a "top post"?

Also because there are so many posts being imported cron needs to run every 2 mins. This means that on each cron run there is only 1-2 posts and twitter updates being imported, where as if cron was run every hour there many be 50+ posts and twitter updates being imported. This also helps the site stay very up to date, but puts a big strain on the server

There are many ideas of how to move the site and project forward, and by using an array of contrib and custom modules it is planned to add more social features to the site. Such as friends and / or followers, what posts your friends have added, other people who have voted on this post. It is also planned to launch a more feature rich profile page displaying a user's friends and what posts they have voted on.

Please head over to Blog to it, register, add your blog and vote up posts you like.

Tuesday, January 20, 2009

A week of symfony #106 (5-11 january 2009)

A new year means new symfony versions and therefore, this week symfony developers started committing changesets to 1.3 branch. In addition, the winner of the Jobeet design contest was announced and symfony 1.2.2 was released.
Development mailing list
Discussions about symfony 1.2 admin generator partial feeds and sfForm vs Factories.yml
Development highlights
r14468, r14469: [1.0, 1.1] backported fix from #2240 to 1.0 and 1.1 after having it tested in 1.2 version
r14481: [1.1] fixed autoloading for PHP 5.1.2
r14483, r14484: [1.1, 1.2] fixed unfinished ob_start in sfValidatorFile
r14485: [1.2] fixed form and view_cache tester are not overridable
r14486: [1.2] fixed sfTesterUser inability to test attribute for namespaces
r14507: [1.2] fixed uppercase POST/GET are not XHTML valid
r14511: [1.2] fixed generate:app and escaping-strategy
r14515: [1.2] silenced possible warning
r14516: [1.2] fixed multiple selector chaining in sfDomCssSelector.class
r14518: [1.2] added cast of generate:app escaping strategy to boolean
r14523: [1.2] publish-assets now canonicalizes pathes before creating the links, thus allowing "\.." and "\."
r14561: [1.3] Created symfony 1.3 doc branch from symfony 1.2.2
Milestone 1.2.2 completed
r14591: [1.3] implemented ArrayAccess interface for sfUser attributes
r14592: [1.3] implemented ArrayAccess interface for sfRequest parameters
r14593: [1.3] added accessor for request content
r14594: [1.3] added accessor for request options + added to web debug bar
r14596: [1.3] made web asset (js, css, image) paths customizable
r14599: [1.3] tweaked cache reload url in web debug bar (to maintain environment)
r14600: [1.3] added accessor for logger options + set dispatcher
r14601: [1.3] added php error handling when using web debug logger (partially reverted)
r14602: [1.3] added better logging for sfBasicSecurityFilter
r14619: [1.3] added upgrade structure for 1.3
sfDoctrinePlugin:
r14466: [1.2] fixed issue with sfDoctrineFormFilter::processValues
r14470: [1.2] corrected fix for resetting filters
r14472: [1.2] fixed issue where i18n doesn't fall back to default culture
r14498: [1.2] adding coverage for ticket
r14499: [1.2] form filters now perform a stricter check
r14500: [1.2] fixed issue where filter functions for fields are not camelized
r14501: [1.2] fixed sfDoctrineRoute to return object instead of null
r14510: [1.2] fixed lingering uppercase method attribute
r14512: [1.2] admin generator resets default filter values correctly
r14550: [1.2] fixed error when uploading files for embedded forms
r14597: [1.3] fixed ability to disable admin generator css by setting false
sfPropelPlugin:
r14470: [1.2] corrected fix for resetting filters
r14480: [1.2] updated bg translations of the admin generator
r14499: [1.2] form filters now perform a stricter check
r14509: [1.2] fixed the way propel handles batch deletions to notify deletion behaviours
r14512: [1.2] admin generator resets default filter values correctly
r14597: [1.3] fixed ability to disable admin generator css by setting false
Updated dwhittle branch
...and many other changes
Development digest: 170 changesets, 39 defects created, 54 defects closed, 6 enhancements created, 14 enhancements closed, 20 documentation defects created, 31 documentation defects closed and 23 documentation edits.
Book and documentation
Updated How to use FCK editor page
Published spanish, italian and vietnamese translations of Jobeet tutorial
Published some vietnamese translations of cookbook tutorials: Quản lý giỏ hàng với plugin sfShoppingCart, Thay đổi cấu trúc thư mục mặc định and Dùng Doctrine để lấy dữ liệu
Wiki
New Job Postings:
Symfony Developer for various plugins and projects - freelance, based in Berlin or Leipzig, Germany - Contact: info [at] mahono [dot] com
Symfony Developer @ Cortica - half or full-time based in MATAM, Haifa (Israel) - Contact: koby [at] cortica [dot] com
New developers for hire:
Boxlight Media Ltd: London based new media agency specializing in enterprise web application development and e-mail marketing strategies who are actively using symfony as their preferred and recommended application development framework.
New symfony blogger:
Lapin Blanc (feed)
gestadieu.blogspot.com (feed)
Plugins
New plugins
sfTidyPlugin: provides automated code repair (ex. users input from TinyMCE or FCKEditor) and produces valid XHTML or XML code. Plugin requires PHP Tidy extension.
sfMicroBlogPlugin: provides a tool box to manipulate microbloging sites. Currently twitter, ping.fm, identi.ca or any other laconi.ca are supported.
sfCookieSessionStoragePlugin: session data is directly stored in an encrypted cookie on the client side (no persistent session on the server side).
sfScriptaculousPlugin: additional JavaScript helpers formely found in JavaScriptHelper.php
sfSocialPlugin: adds social network features for your users: contacts, messages, status, etc.
sfWebRPCPlugin: allows ultra easy creation of RPC servers with symfony
Updated plugins
sfDatagridPlugin: fix the exception when the date filter value cannot be converted
DbFinderPlugin: fixed wrong exception text
sfSmartyPlugin: updated require_once to work with PEAR installed Symfony or Symfony installed as an external, updated to allow Smarty from PEAR installations
i18nTranslatePlugin: initial import
sfDoctrineUserPlugin: added a branch for 1.2
sfExtjsThemePlugin: added in ability to set actions
sfPhpDocPlugin: changed base class of sfGeneratePhpDocTask to sfBaseTask
sfImageTransformPlugin: fixed role attribute in package.xml
sfOpmlPlugin: fixed sfOpml::fromArray()
sfDoctrineActAsTaggablePlugin: various additional fixes for symfony 1.2 upgrade
tsTitlePlugin: added support for cache, fixed tsTitleTest
ckWebServicePlugin: updated README, created branch for sf1.1 version, added folder for 1.2 branch,
swToolboxPlugin: updated sendMail method
ysfYUIPlugin: changed calls to sfLoader::loadHelpers() to sfApplicationConfiguration::loadHelpers()
dwSwfChartPlugin: fixed issue with relative url root
sfDoctrineAdminGeneratorWithShowPlugin: update from official theme
sfEasyDebugPlugin: modification to allow to work when stack is not complete
sfFormExtraPlugin: fixed Autocomplete getStyleSheets() returns incorrect files, updated sfFormExtraPlugin package.xml
Some new symfony powered websites
TrustedReviews: UK's premier source of technology news and reviews
Kann nicht Auto fahren: (german) complain about bad car drivers and emberass them by adding photos and videos
ListasEmCaixas: (portuguese) social list making application
They talked about us
Functional Testing a Secured Module
How to Embed Forms in Symfony 1.2 Admin Generator Part 2
Formation symfony 1.2 + Doctrine le 21 janvier 2009
Offline Version of Symfony 1.2 Book + Jobeet Tutorial
Tutorial Jobeet completo e in Italiano
Come trovare l’ultima query eseguita da propel
Using doctrine with symfony 1.2 (2/4) - inheritance
Symfony 1.2.2 available at ServerGrove
Se publica Symfony 1.2.2
Add reCaptcha widgets to symfony forms
Invoicr (former CS-4U), what's new?
Twitto - A web framework in a twit
Jobeet se convertirá en un libro
Twitto: PHP Framework in 140 Zeichen
Twitto, el framework PHP más pequeño
German Symfony trainings
Zend Framework o Symfony
Choosing a PHP framework to work with
Symfony: Paginacja przy własnych/nietypowych warunkach SQL
More: Synchronization using phing
The bittersweet rewrite
Symfony 1.2 sous Ubuntu
Astuce symfony : changer le chemin du cookie de session de symfony
404ページをカスタマイズする場合の注意
アクションキャッシュを使用する場合にテンプレートではなくアクションから直接出力しているとキャッシュされずにページが真っ白に
Web framework
簡単にsymfonyをインストールするスクリプト
Optymalizacje: sfPropelPager::getResults()
[symfony] javascript/cssのロード

Monday, January 19, 2009

Call the expert: Using a custom version of Doctrine

Now that the release of Doctrine 1.1 right around the corner their has been a bit of noise about how users can use 1.1 instead of the default bundled 1.0.
With sfDoctrinePlugin it is easy to swap out the version of Doctrine used by simply changing one configuration value.
Below you will find an example of how you can configure sfDoctrinePlugin to use a different version of Doctrine, for example 1.1.
First we need to check out the version of Doctrine we want to use into lib/vendor/doctrine:$ cd lib/vendor
$ svn co http://svn.doctrine-project.org/branches/1.1/lib doctrine
Now we can configure the sfDoctrinePlugin to use that version of Doctrine instead of the one that comes bundled with the plugin. In your ProjectConfiguration::setup() method you need to change the value of the sfDoctrinePlugin_doctrine_lib_path with sfConfig, like the following:public function setup()
{
sfConfig::set('sfDoctrinePlugin_doctrine_lib_path', sfConfig::get('sf_lib_dir') . '/vendor/doctrine/Doctrine.php');
}
Now you can enjoy the great features of Doctrine 1.1 without too much work. You can check out what is new in Doctrine 1.1 by reading the upgrade file.

The “Practical symfony” book is now on sale

Two years after the publishing of “The Definitive Guide to symfony” book, I am happy to announce that the Jobeet tutorial is now available as a printed book: “Practical symfony“.

During the last two weeks, I have updated and enhanced the Jobeet tutorial based on the feedback from the community. I have also updated the screenshots to reflect the new Jobeet design. The “Practical symfony” book is the printed version of this tutorial and as such covers the symfony 1.2 version.

The book is available in two editions: Propel and Doctrine. You can already buy the Propel version. Jon is working on the Doctrine version and the book will be available very soon.

The book content is the same as the one available on the website. The only differences are the table of contents and the day 24 cross-references, where all links have been converted to page references.

If you want to read the Jobeet tutorial comfortably in the train or in your bed, or if you simply want to support the symfony project documentation effort, you can buy the book on lulu.com.

A week of symfony #107 (12->18 january 2009)

Symfony development continues at full pace with more than 230 changesets in just one week. Symfony 1.3 was the most updated version, including its Propel and Doctrine plugins. In addition, Jobeet tutorial was highly updated, 10 new plugins were published and tens of post about symfony were published around the world.

Development mailing list

Development highlights

  • r14660: [1.3] updated doctrine svn:externals to version 1.1
  • r14684: [1.3] made autoloaders case insensitive
  • r14688: [1.3] updated unit test bootstrap script to check for an active configuration (i.e. if called from a task)
  • r14689: [1.2, 1.3] fixed simple autoload unregister not changing registered flag
  • r14691: [1.3] added reloadAutoload method to base task
  • r14692: [1.3] updated generate:project task to generate a relative path to the core autoloader when symfony is nested within the project directory
  • r14697: [1.3] added array access + call to sfContext
  • r14698: [1.3] added $request to preExecute() and postExecute()
  • r14699: [1.3] added parsing of request content as put parameters
  • r14700: [1.3] added sfMailer + sfSwiftPlugin + tests
  • r14701: [1.3] updated core autoload
  • r14730: [1.1, 1.2, 1.3] fixed discrepancy in embedFormForEach function signature
  • r14776: [1.3] added registration of autoloadAgain when in debug mode without registering different methods on the same autoload class
  • r14829, r14830, r14831: [1.1, 1.2, 1.3] fixed notice in sfPearRestPlugin
  • r14852: [1.1, 1.2, 1.3] fixed sfForm::offsetUnset doesn’t properly unset private members
  • sfDoctrinePlugin:
    • r14698: [1.3] added $request to preExecute() and postExecute()
    • r14702, r14703: [1.3] updated test fixtures
    • r14779, r14780: [1.2, 1.3] fixes regression in sfDoctrinePager and adds additional coverage to tests
    • r14782: [1.2, 1.3] adding coverage for unique columns
    • r14783: [1.2, 1.3] Fixes _list_td_tabular.php using wrong classname
    • r14784: [1.2, 1.3] Fixes renderFormTag() to allow custom method
    • r14793: [1.2, 1.3] Fixes regression with sfDoctrinePager and the use of setQuery()
    • r14815: [1.2, 1.3] Fixes issue with wrong option being passed to insert sql task
    • r14816: [1.2, 1.3] Fixes bug where 404 is not thrown when no records are found
  • sfPropelPlugin:
    • r14691: [1.3] added reloadAutoload method to base task
    • r14698: [1.3] added $request to preExecute() and postExecute()
    • r14728: [1.1, 1.2, 1.3] fixed foreign keys are assumed with column name “ID” in auto generation of forms
    • r14731: [1.3] moved contents of config.php into configuration class
    • r14732: [1.3] removed unnecessary conditional around inclusion of behavior file
    • r14733: [1.3] added IS_I18N peer constant
    • r14770: [1.3] fixed coding standards in inheritance objects
    • r14783: [1.2, 1.3] Fixes _list_td_tabular.php using wrong classname
    • r14784: [1.2, 1.3] Fixes renderFormTag() to allow custom method
    • r14788: [1.3] added isToString column attribute to object builder, generation of __toString() magic method
  • Updated dwhittle branch: added array access + call to sfContext, removed sfContext::getMailer in favor of call, added $request to preExecute() and postExecute(), added parsing of request content as put parameters, added sfMailer base class, added initial commit of sfSwiftPlugin, updated doctrine externals to 1.1 for symfony 1.3, cleaned up doctrine test
  • …and many other changes

Development digest: 237 changesets, 44 defects created, 26 defects closed, 6 enhancements created, 3 enhancements closed, 8 documentation defects created, 18 documentation defects closed and 27 documentation edits.

Book and documentation

Wiki

Plugins

  • New plugins
    • sfGenExtraPlugin: adds extra components to work with Symfony’s generated forms (3 way sort on admin generated forms, filter on a range of numbers instead of exact values, validate a field against a constant value)
    • sfGuardHardenedPlugin: hardened version of sfGuard to avoid dictionaries attacks and sniffing tools
    • sfCliPlugin: allows to execute the symfony commands on a web console
    • sfWorkerPlugin: manage worker from symfony requests. Workers as in external process which may be longer than a single HTTP request
    • swDoctrineAssetsLibraryPlugin: a Doctrine version of the sfAssetsLibraryPlugin
    • QRcodePlugin: generates QR code image
    • sfEventDeferrerPlugin: provides the mechanisme to defer sfEvent triggering
    • sfUnobstrusiveWidgetPlugin: packages useful widgets for symfony
    • sfMultisiteThemePlugin: allows a site owner to have one or more domains pointing to one Symfony project, but allows them to set up different layouts(themes) for each URL. Allowing the same content on each site
    • sfEditTemplatePlugin: provides modules to edit template files in your symfony projects
  • Updated plugins
    • sfGravatarPlugin: added symfony 1.2 compatibility, updated default gravatar image which looked ugly
    • sfPropelActAsCommentableBehaviorPlugin: created 1.0 branch of the plugin for sf 1.0
    • sfDateTime2Plugin: fixed a roundup issue in sfDate::diff()
    • sfExtjsThemePlugin: changed so that params:field_type would also work for datastore, modified onLinkClick method to use the new default tabpanel, modified edit cancel button to close the tab, modified edit save button to update the list grid, initial import of working ExtjsGeneratorPlugin under symfony 1.2
    • limexPlugin: corrected a bogus path, added required methods to functional test case
    • swToolboxPlugin: added swValidatorTrilean (true, false and null), allow to add specific raw SQL code into Doctrine Query
    • sfDatagridPlugin: updated README, add the column comparator options for the datagridPropel, change the default text in english by default
    • sfWebRPCPlugin: debugging IXR_library, added makefile to package easily, added documentation, fixed a bug in IXR_Library
    • sfSuperCachePlugin: added ability to preserve some HTTP headers when check_lifetime is set to true. That way, client-side cached actions live well with the plugin
    • sfSocialPlugin: added count of unread messages, fixed bug in $sfSocialMessage->read(), implemented sfSocialEvent module, added some unique keys to schema.yml, implemented sfSocialContact module, updating sfGuardSecurityUser
    • sfShibbolethPlugin: added agilbert branch, added sfShibbolethUser module as a password-less alternative to sfGuardUser module, auto registration of routing rules added, updated the processForm action with a random password generator
    • bhLDAPAuthPlugin: untested recursive group checking, squelch adLDAP warning
    • sfPropelActAsCommentableBehaviorPlugin: upgraded plugin to symfony 1.2, moved plugin’s trunk to a dedicated branch
    • sfMicroBlogPlugin: added a getInstance()
    • ckWebServicePlugin: updated README, updated package.xml for version 2.2.2, migrated project fixture to sf1.2, replaced config.php with ckWebServicePluginConfiguration class, created tag for version 3.0.0, applied major refactoring to use annotations instead of doc tags where possible, added support to add methods to different webservices, refactored ckWebServiceGenerateWsdlTask to support new features of ckWsdlGenerator, SoapHandler generation is no longer optional, result adapter module configuration is no longer overwritten, merged recent changes to ckWebServiceGenerateWsdlTask and test fixture updates from 1.2 branch, disabled debug option in ckWebServiceGenerateWsdlTask, removed obsolete autoload registration, merged recent changes from 1.1 branch to provide consistent interface, moved getPropertyStrategy() from ckXsdComplexType to ckAbstractPropertyStrategy, extended functionality of property strategies

Some new symfony powered websites

  • filmprices.com: (English/Norwegian/Swedish/Danish) a film price comparison site

They talked about us

Friday, January 16, 2009

Using Ajax in Drupal 6

John K. VanDyk confirmed that Pro Drupal Development 2nd edition will be published early this summer. I don’t know about you but in Montreal it sure does not look like summer. We’re still in the dead of winter, and it’s one snowstorm after another.

Anywho, I got busy last night and, on a Drupal 6 install, I worked through chapter sweet seventeen of the Pro Drupal Development 1st edition book. The title of the chapter is "Using jQuery".

(Hey, here is an idea for a thread: name the one computer book you’ve actually read from cover to cover in your life. My answer: Pro Drupal Development, and probably just a few other books.)


View More