html link column in jqGrid

Danny picture Danny · Jul 22, 2009 · Viewed 64.5k times · Source

Is it possible have a html link in a column with jqGrid, I can't find any example in the documentation?

Answer

Randy Klingelheber picture Randy Klingelheber · Mar 23, 2010

Here's the sample colModel configuration from Craig's link to jqGrid formatting help. It specifies the formatter as showLink and the url and params are specified with formatoptions.

colModel: [ {name:'myname', 
             edittype:'select', 
             formatter:'showlink', 
             formatoptions:{baseLinkUrl:'someurl.php', addParam: '&action=edit'}