javascript - jsp how to escape double quotes -


   <center>     <span class="reportsubsectiontitle">report type</span>                                     <br />         <html:radio  styleid="summary" property="reportoutputstyleid" onclick="dodetail();" value="2" />pending funding                                     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;        <html:radio  styleid="detail" property="reportoutputstyleid" onclick="dosummary();" value="1" />previously funded </center> 

so, on loading, want default option 2 selected.

 <body topmargin="0" leftmargin="0" rightmargin="0" onload="window.moveto(0,0);                                                        window.resizeto(screen.availwidth,screen.availheight);                                                        window.focus();                                                        insertoption('number');                                                        document.achreportcriteria.reportoutputstyleid.value="2";                                                        dodetail();"> 

i tired \" , &quot, doesn't seem it.

here's easiest, simplest solution , cleanest solution:

<body topmargin="0" leftmargin="0" rightmargin="0" onload="initializepage()">  <script>     function initializepage() {         window.moveto(0,0);         window.resizeto(screen.availwidth,screen.availheight);         window.focus();         insertoption('number');         document.achreportcriteria.reportoutputstyleid.value="2";         dodetail();     } </script> 

and function stored in external js file, avoid reloading each time page reloaded.


Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -