I am new to extjs. I want to display icon images for each grid elements. can you please help me anybody?
I am getting the image path from an xml file.
My cod
You need to add a renderer to your columns that you want to display an image. The renderer value is the function to call to render the image tag.
One of your column elements modified:
{header: "Photo", width: 100, renderer:renderIcon, dataIndex: 'form-file', sortable: true},
A sample renderer function:
function renderIcon(val) {
return '
';
}
In this example, the value of the dataIndex must be the full path of the image. If not then you must add some additional logic.