adding links to cells while dhtmlXGridFromTable

Hi,

I’m trying to place a link in one of the cells in the table.





Username

Name

Class

Class Number

Phone# (Home)

Phone# (Mobile)

Gradin Fee Paid

Gradin Fee Payment Notes





leungpokyin



Victor

7C

10

23936

91575

YES

Self Account Transfer





dhtmlxgrid_excell_link.js is included

var mygrid = dhtmlXGridFromTable(‘records’);



The above is part of the original table, I wonder what is the correct way to do this. I mean putting the link in the cell. I found that html tags are not happy going into cells.



Thank you so much

The default way is to define column type as link and use plain value, without html tags



<th type=“link”>Username

Name

Class

Class Number

Phone# (Home)

Phone# (Mobile)

Gradin Fee Paid

Gradin Fee Payment Notes





leungpokyin^user-edit.php?user_id=2&wp_http_referer=%2Fgradin%2Fwp-admin%2Fusers.php%3Fpage%3Dau_extended
Victor

7C

10

23936

91575

YES

Self Account Transfer




But you can use your initial approach, with inline HTML tags ( in such case you need not _link.js and can use “ro” column type for all columns ) - just update existing dhtmlxgrid_start.js with attached one - it will resolve problem with HTML tags inside source table.

dhtmlxgrid_start.zip (1.73 KB)

Thanks so much, the new  dhtmlxgrid_start.js  works wonderfully, thanks again…