hiluc
Joined: 15 Sep 2004
Posts: 3
Posted: 2004-09-15 22:21
Back to top
Reply with quote
|
A column 'title' is setup with 'sql|L' option (to have a clickable link to a file using other fields from the same table)
$opts['fdd']['title'] = array(
'name' => 'Title', 'sort' => true,
'escape' => false, 'sql|L' => 'concat("<a target=\"_blank\" href=\"",file_path,file_name,"\">",title,"</a>")',
);
Now, when sorting: the result of the 'sql|L' - query is sorted, not the displayed field (->title). Any help or workaround ?
|
michal
Joined: 17 Jun 2003
Posts: 537
Location: Slovakia
Posted: 2004-09-16 08:49
Back to top
Reply with quote
|
it is sorted by the string, which is '<a href...>' in this case. to sort if by title, there are two possibilities i see:
1. allow usage of $row array in 'url' option (as is suggested in some of my bug reports/feature requests/patches)
2. change the string so that it sortes by what you need. something like '<a title= .. href=..>title</a>' hope it's at least a little html correct...
|
|
Post new topic
Reply to topic
|
|
|