• Nacho
  • NEWBIE
  • 25 Points
  • Member since 2011

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 3
    Replies

Hi

 

I'm trying to get the HTML code of a chart and assigning it to an atribute of the controller.

 

<apex:inputText value="{!chartHTML}" id="chartHtmlInput" style="display:none;"  />

 

I've got the atribute chartHTML specified in the controller and I'm trying to asign to it the HTML code of a chart.

 

so I use the following javscript code

 

document.getElementById('{!$Component.chartHtmlInput}').value= document.getElementById('{!$Component.chartPanel}').innerHTML;

 

sadly the HTML code I'm getting is escaped, as you know I can't use the attribute "escape" in <apex:inputText>

 

any Ideas how can I get my code non-escaped?

 

Thanks in advance

  • May 16, 2011
  • Like
  • 0

Hi

 

I'm trying to get the HTML code of a chart and assigning it to an atribute of the controller.

 

<apex:inputText value="{!chartHTML}" id="chartHtmlInput" style="display:none;"  />

 

I've got the atribute chartHTML specified in the controller and I'm trying to asign to it the HTML code of a chart.

 

so I use the following javscript code

 

document.getElementById('{!$Component.chartHtmlInput}').value= document.getElementById('{!$Component.chartPanel}').innerHTML;

 

sadly the HTML code I'm getting is escaped, as you know I can't use the attribute "escape" in <apex:inputText>

 

any Ideas how can I get my code non-escaped?

 

Thanks in advance

  • May 16, 2011
  • Like
  • 0