Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Add some extra tools to symfony

Fetching latest commit…

Cannot retrieve the latest commit at this time

README
For now, there is no full documentation. However you can find some information here

* [swBreadcrumb](http://rabaix.net/en/articles/2009/05/16/working-with-symfony-plugins-breadcrumb "Working with symfony plugins breadcrumb") : Working with symfony plugins breadcrumb

# swToolboxHelper

## sw_t($title)
  * define the title of the current page
  * custom configuration : edit and add these lines to your app.yml
  
        [yml]
        swToolbox:
          page_title_enabled: true
          page_title_suffix: " - Thomas Rabaix"
        
## sw_insert_google_api

  * small helper to insert google api url
  
        [yml]
        swToolbox:
          api_loader:
            yourhostname:
              google_api_key: your_key_here
              google_map_version: 2.x
              google_map_url: http://maps.google.com/maps
              google_analytics: [ UA-KEY-ONE, UA-KEY-TWO]
  

# swUserContextCacheFilter

This class can replace the default cache handler class. The class always executes an user context action.

Let's take this example with an ecommerce website, you might want to cache the full action, however some parts are user specific.
So you can have a viewProduct action and a viewProduct_UserContext action in your actions.class.php

* viewProduct : execute page related action, get the product and other related information
* viewProduct_UserContext : execute user specific action for the current page, like testing if the product is already in the client's basket.

## Installation

* edit the filters.yml

        [yml]
        cache:
          class: swUserContextCacheFilter
          param:
            condition: on # always set to on
Something went wrong with that request. Please try again.