Zend Framework Forum

Go Back   Zend Framework Forum > Zend Framework General discussions > Resources for Developers

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-07-2008, 12:33 PM
JGD JGD is offline
Junior Member
 
Join Date: Jul 2008
Posts: 9
Default sorting by columns

Hi,

My page displays results retreived from a database table. I would like to allow the user to order these reults based on table headings. How can I acheive this?

Any feedback is appreciated,

Regards
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-21-2009, 11:03 PM
Junior Member
 
Join Date: Aug 2008
Posts: 2
Default

any luck with this?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-22-2009, 01:10 AM
Senior Member
 
Join Date: Jun 2008
Location: Florida
Posts: 167
Default

Have the column headings be hyperlinks that send a request to a controller, with params that define how to sort, then using these params to sort your array or create your SQL.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 03-18-2009, 01:36 AM
Junior Member
 
Join Date: Mar 2009
Posts: 9
Default Try dojo datagrid

Since Zend and Dojo play well together, you can remove the creation of an HTML table, and replace it with a dojo data grid. This took a while to figure out, but once done, enables sorting and read-on-demand paging fairly well.

Once thing I haven't found yet (and had to force into it) was the concept of allowing filters on each field found. Not a filter of available values in the grid, just free-text typing that could be used as a filter to the server-side query returning the result.

And on a side note, if anyone is aware of a declarative plugin for auto-displaying filter edits above each field of a grid, I would LOVE to hear from you about your suggestion.

Good luck with that.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT. The time now is 02:34 PM.


Designed by: Miner Skinz Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0