I have not changed anything.
My output collapsed like attached image.
usually AS is working well,only ‘if’ clause AS is now my problem.
Note it But my json output comes properly.
This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.
The active forums are here.
July 15, 2010 2:51am
Subscribe [119]#166 / Jun 09, 2011 6:45am
I have not changed anything.
My output collapsed like attached image.
usually AS is working well,only ‘if’ clause AS is now my problem.
Note it But my json output comes properly.
#167 / Jun 09, 2011 7:08am
i couldnt see any wrong things with if clause.. all i can see is undefined columns.
#168 / Jun 10, 2011 8:49am
thanks for the great job.
#169 / Jun 15, 2011 8:28am
really great library i have one question how can i use php functions with in library to perform a specific task like i want to replace - from one of the column record like
str_replace("-"," ",$column_name)#170 / Jun 15, 2011 3:04pm
you can use php functions with callback_functionname(param1,param2, ..) (download latest #162 ) :
->edit_column('column_name', '$1', 'callback_str_replace(-, ,column_name)')#171 / Jun 16, 2011 3:06am
really great but it is not replacing space between words, well i have put
working.
#172 / Jun 18, 2011 10:21am
hey everybody,
i’ve made a video about installing IgnitedDatatables and its usage in very limited time =).
Video : http://bit.ly/iXvRfk
Regards,
Yusuf
#173 / Jun 18, 2011 11:05am
hey everybody,
i’ve made a video about installing IgnitedDatatables and its usage in very limited time =).Video : http://bit.ly/iXvRfk
Regards,
Yusuf
[offtopic]How… in… the… word… do… you… survive… in… dreamweaver…!?!? :S I would seriously advise you to look at the alternatives…[/offtopic] Now a bit more ontopic, these videos only tend to be useful if you record some audio with them as well, though I don’t like doing that either 😛
#174 / Jun 27, 2011 6:35am
Hello, i have a situation here… I am using datatables+igniteddatatables and serverside processing on them. Now I want to apply filter on datatables. Not ordinary but extended filter. Example…filter on price range (show me records between 100-5000). Another one…I have a column with status and would like to filter on lets say 2 statuses (Available,Sold,For sale, Other and would like to show records that match Available and For sale). For now I am filtering like this
oTable.fnFilter(x, x); But this only works for one match from specific column. And regex in this filter doesnt work.
Could anyone advise me how to do that? Is this even posible?
#175 / Jun 28, 2011 11:00am
Hey skergetd,
You can push data to ajax like this (use aoData.push):
'fnServerData': function(sSource, aoData, fnCallback)
{
aoData.push( { "name": "filter_min", "value": "100" },
{ "name": "filter_max", "value": "5000" } );
$.ajax
({
'dataType': 'json',
'type' : 'POST',
'url' : sSource,
'data' : aoData,
'success' : fnCallback
});
},function listener()
{
$this->datatables
->select('id, name, email, age')
->from('tbl_profile');
$this->datatables->where('age >', $this->input->post('filter_min'));
$this->datatables->where('age <', $this->input->post('filter_max'));
$data['result'] = $this->datatables->generate();
$this->load->view('ajax', $data);
}This should work..
#176 / Jun 30, 2011 4:30am
Is there anyway we can use SQL grouping (group_by) ?
I can’t find any in the library code.
$this->datatables->group_by('xxx')#177 / Jun 30, 2011 6:57am
you should use ‘GROUP BY’ in subqueries.
For Example :
$this->load->library("Datatables");
$this->datatables
->select('pages.id as pageid, title')
->from('(SELECT id,title,user_id FROM pages GROUP BY user_id) as pages')
->join('users', 'users.id = pages.user_id', 'left' )
->select('username');
echo $this->datatables->generate();its not a very good example but i think u got the idea ^^
Regards,
Yusuf
#178 / Jun 30, 2011 11:23am
Ignited Datatables v0.5.3 released, added mDataProp support for Datatables v1.8.1+
Regards,
Yusuf
#179 / Jul 01, 2011 2:38am
Hi,
I’ve tried this in where clause:
$this->datatables->where("(tractivity.activestatus=1 and tractivitysubscriptions.userid = '" . $_SESSION['userid'] . "' and activitytype=1) or (tractivity.activitytype=0 and tractivity.activestatus=1) or (tractivity.userid='" . $_SESSION['userid'] . "')");The result is correct but somehow I can’t use the datatable search feature.
It’s processing but didn’t get a correct search result.
I wonder where’s the problem in this?
Btw, the subquery was great… many thanks.
Thanks in advanced
Andry
#180 / Jul 01, 2011 3:38am
Hello,
Try :
$this->datatables->where("((tractivity.activestatus=1 and tractivitysubscriptions.userid = '" . $_SESSION['userid'] . "' and activitytype=1) or (tractivity.activitytype=0 and tractivity.activestatus=1) or (tractivity.userid='" . $_SESSION['userid'] . "'))");