Refreshing a widget in Yii

Yesterday, I wrote an AJAX shopping basket widget which, as I’m sure you can imagine, I wanted to refresh when items are added or deleted.  However, having written the code to display the widget it confused me for a while … Continue reading

May 17th, 2012

Yii – Example of Creating a submenu widget

This is a continuation of two previous articles, How to make a dynamic Sub-menu and How to make a dynamic sub-menu – UPDATE, which show the mechanisms by which you can build a dynamic submenu system, populating the dropdowns from the relevant controller. … Continue reading

May 1st, 2012

Advanced Logging in Yii

Here are some nice examples of using the logging facilities in Yii  PHP |  copy code |? 0102 ‘log’=>array(03 ‘class’=>’CLogRouter’,04 ‘routes’=>array(05 array(06 ‘class’=>’CWebLogRoute’,07 // you can include more levels separated by commas08 ‘levels’=>’trace, info, error, warning, vardump’,09 // categories are those you used in the … Continue reading

April 24th, 2012

Yii – simple email and mail merge

I needed an email mechanism for a customer that was light and easy to configure. Yii extensions I tried several email extensions from the Yii website all of which I found overly complex to setup and use.  I then remembered … Continue reading

April 5th, 2012

WP eCommerce by GetShopped is now fully integrated

WordPress 3.0 introduced the ability for plugin developers to build their own custom post types.  This means that the main data is held in the same table as your WordPress posts and pages and therefore means that other core wordpress … Continue reading

March 29th, 2012

WPEC – hacking the product URL to exclude categories

Preamble For several weeks now I have been on the holy grail, trawling through OLD wpsc/wpec documentation and scouring the interweb for the answer to the primary SEO criticism of WordPress eCommerce.  Even the latest 3.8.8 beta still does not … Continue reading

March 21st, 2012

WPEC Products in multiple categories cause SEO duplicates

Overview Whilst trying to customise a bought in template and digging around in a customer’s WordPress eCommerce system, it occurred to me that there is a fundamental design flaw in the system from two perspectives.  Both have to do with the way that Products are assigned to … Continue reading

March 21st, 2012

Yii – How to customize a CGridView CbuttonColumn – part 2

Part 2 (see part 1 here)  PHP |  copy code |? 1 array(2 ‘class’=>’CButtonColumn’,3 ‘template’=>’{update}{add}{delete}’, Always set the class to CButtonColumn. The ‘template’ option enables you to name your buttons as you wish. Yii understands the basic crud names of ‘update’, ‘view’ and ‘delete’ but … Continue reading

February 28th, 2012

Adding an additional column as part of CDbCriteria

This was a tough one today and I found the solution in a number of places, but this one was the most helpful. Problem I’ve got an Property Rental application which also holds availability by dates for each property.  If … Continue reading

February 23rd, 2012

Changing the width of a filter column in CGridview

I recently spent an hour or so trying to reduce the width of columns in a CGridView. As I was trying to squash the grid into a narrow space, I wanted some columns to be narrower than others. I tried … Continue reading

February 21st, 2012