Categories | Question details Back To List | ||
show link hello, mygrid.setColTypes("link,ed"); try to use <cell>Click here^javascript:doSome()^_self</cell> instead wher i will add this to in my code <?php $res=mysql_connect("localhost","root",""); mysql_select_db("kanibrainnew1"); require_once("../dhtmlxConnector_php/codebase/grid_connector.php"); $grid = new GridConnector($res); $grid->dynamic_loading(100); $grid->render_sql("select * from shot,shotTaskArtist where shotTaskArtist.projID = shot.projID and shot.projID='om' and shotTaskArtist.shotID = shot.shotID","shotID","shotID,shotStatus,taskID,TaskREF,task_note,mandays,userID,taskStatus,startDate,endDate,priority,naxt_sub,last_sub,actualMandays,supervisorName"); ?> thid id my html file <div id="gridbox" style="width:1165px; height:902px;"></div> <div id="params" style="width:1165px; height:902px;"></div> <script> mygrid = new dhtmlXGridObject('gridbox'); mygrid.setImagePath('dhtmlxGrid/codebase/imgs/'); mygrid.setHeader("Add/Del,ShotID,Shotstatus,TaskID,Taskref,Task-Note,Alloted Mandays,UserID,TaskStatus,StartDate,EndDate,Task Priority,Next-Sub,Last-Sub,Actual Mandays,Supervisor"); mygrid.setColTypes("link,ed,ed,ed,ed,ed,ed,ed,ed,ed,dhxCalendarA,ed,ed,ed,ed"); mygrid.setSkin("modern") mygrid.attachHeader("#connector_text_filter,#connector_select_filter,#connector_select_filter,#connector_select_filter, ,#connector_select_filter,#connector_select_filter,#connector_select_filter,#connector_select_filter,#connector_select_filter,#connector_text_filter,#connector_select_filter,#connector_select_filter,#connector_select_filter,#connector_text_filter") mygrid.setColSorting("connector,int,connector") mygrid.init(); mygrid.enableSmartRendering(true); mygrid.enableMultiselect(true); mygrid.loadXML("connector.php"); var dp = new dataProcessor("connector.php"); dp.init(mygrid); </script> please reply me where i will add one column of link there and where . Answer posted by Stanislav (support) on Dec 08, 2009 10:14 $grid->dynamic_loading(100); //next is added to add custom formatting function my_format($data){ $value = $data->get_value("shotID"); $new_value = "Click me^javascript:doSome("+shotID+")^_self"; $data->set_value("shotID",$new_value); } $grid->event->attach("beforeRender","my_format"); |