html - Buttons for text area that change the font size however It only works of text selected by the user (like Microsoft office's font size selections) -


this code have font size buttons need work on selected text user , not change font size of letters in text area (like microsoft's font size selection in there word documents)

   <select onchange="textarea1.style.fontsize = this.value;" >      <option value="12px" selected="selected">12</option>      <option value="14px">14</option>      <option value="16px">16</option> </select> 

put id="textarea1" select

<select id="textarea1" onchange="textarea1.style.fontsize = this.value;" >      <option value="12px" selected="selected">12</option>      <option value="14px">14</option>      <option value="16px">16</option> </select> 

Comments

Popular posts from this blog

java - Jmockit String final length method mocking Issue -

asp.net - Razor Page Hosted on IIS 6 Fails Every Morning -

c++ - wxwidget compiling on windows command prompt -