Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by dlaunay on Dec 17, 2008 01:24
open dhtmlx forum
Tag traduction in grid header

Hi,

I want to display a picture in column header, near the title.
So, i use the following javascript code to initialize the grid header.

Grille.loadXMLString('<?xml version="1.0" encoding="ISO-8859-1"?><rows>    <head>        <column id="Module_et_Fonction" width="250" type="tree" align="left" sort="na"><![CDATA[<div id="expColl">Fonction<img id="imgExpand" src="${WEB_RESSOURCE}images/plus.gif"/></div>]]></column></head></rows>', finirInitialisationGrille);

In the header the text is ok, but the img appears like a unknown source (broken image).
When i check the source in the image properties, it indicates :
http://localhost:8080/ProjetReference/web2SpringMVC/page/$%7BWEB_RESSOURCE%7Dimages/plus.gif
instead of ${WEB_RESSOURCE} value : http://localhost:8080/ProjetReference/Web/ressources/

when i place the folowing code directly into the body of html page, it works fine : <img id="imgExpand" src="${WEB_RESSOURCE}images/plus.gif"/>


So i suppose the grid makes an traduction of the special character?

Do you have an idea?
Maybe i don't use dhtmlxgrid object not correctly?

Best regards
Answer posted by Support on Dec 17, 2008 03:06
The desired behavior doesn't related to the component logic. 
I'm not quite sure which kind of server side logic you are using, but in above sample, your server side script just not replaced variable inside XML string - most probably it caused by outputing such data directly in the page, without server side processing.