Wednesday, November 26, 2014

how to insert javascript source...

Sorry I can;t wirte English.





1. my java script source.
<html>
<body>
<script type="text/javascript" src="http://checkout.naver.com/customer/js/checkoutButton.js" charset="UTF-8"></script>
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="margin-top:3px;">
<tr>
<td width="80">&nbsp;</td>
<td>
<script type="text/javascript" >
//<![CDATA[
nhn.CheckoutButton.apply({
BUTTON_KEY: "", 
TYPE: "B", 
COLOR: 1,
COUNT: 2,
ENABLE: "Y",
"":""});
//]]>
</script>
</td>
<td>
</td>
</tr>
</table>
</body>
</html>


2. My Source

VerticalPanel mainPanel = new VerticalPanel();
mainPanel.add( new imagePananel ())
mainPanel.add( new makeJavaScriptPanel());

private String makeJavaScriptPanel(){
StringBuilder sb = new StringBuilder();

sb.append("<html>");
sb.append("<body>");
sb.append("<script type=\"text/javascript\" src=\"http://checkout.naver.com/customer/js/checkoutButton.js\" charset=\"UTF-8\"></script>");
sb.append("<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" style=\"margin-top:3px;\">");
sb.append("<tr>");
sb.append("<td width=\"80\">&nbsp;</td>");
sb.append("<td>");
sb.append("<script type=\"text/javascript\" >");
sb.append("//<![CDATA[");
sb.append("nhn.CheckoutButton.apply({");
sb.append("BUTTON_KEY: \"F5AD74D3-DAAD-4ED8-B3C7-614240931115\", ");
sb.append("TYPE: \"B\", ");
sb.append("COLOR: 1,");
sb.append("COUNT: 2,");
sb.append("ENABLE: \"Y\",");
sb.append("\"\":\"\"");
sb.append("});");
sb.append("//]]>");
sb.append("</script>");
sb.append("</td>");
sb.append("<td>");
sb.append("</td>");
sb.append("</tr>");
sb.append("</table>");
sb.append("</body>");
sb.append("</html>");

return new HTMLPanel(sb.toString)
}





watch attached image.

javascript show this image... I want  show...
but script code not working.. I don't know how to this problem




--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment