Title: javascript on widget admin page
Last modified: August 19, 2016

---

# javascript on widget admin page

 *  Resolved [mimiz.fr](https://wordpress.org/support/users/mimizfr/)
 * (@mimizfr)
 * [15 years, 7 months ago](https://wordpress.org/support/topic/javascript-on-widget-admin-page/)
 * Hi,
    I’m writing a plugin, and this plugin will have a widget that have some 
   options. If one option is checked, i want to ask the user for filling a text 
   input, and hide this input text if the option is not checked.
 *  Here is the code :
    the form looks like these :
 *     ```
       <input type="checkbox" onclick="javacript:myFunc();" />
       <div id="toHide"><input .../></div>
       ```
   
 * the js function is correctly loaded.
 *     ```
       function myFunc(){
        jQuery("#toHide").show();
       }
       ```
   
 * and it does not work.
    if i replace “jQuery” with $, firebug tells me that $ 
   is not a function, I don’t understant why … does anybody have an idea ?
 * regards
 * mimiz

Viewing 1 replies (of 1 total)

 *  Thread Starter [mimiz.fr](https://wordpress.org/support/users/mimizfr/)
 * (@mimizfr)
 * [15 years, 7 months ago](https://wordpress.org/support/topic/javascript-on-widget-admin-page/#post-1745852)
 * Hi
    i solved my problem … My selector was incorrect …
 * Regards
    mimiz.fr

Viewing 1 replies (of 1 total)

The topic ‘javascript on widget admin page’ is closed to new replies.

## Tags

 * [javascript](https://wordpress.org/support/topic-tag/javascript/)
 * [jquery](https://wordpress.org/support/topic-tag/jquery/)
 * [widget](https://wordpress.org/support/topic-tag/widget/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 1 reply
 * 1 participant
 * Last reply from: [mimiz.fr](https://wordpress.org/support/users/mimizfr/)
 * Last activity: [15 years, 7 months ago](https://wordpress.org/support/topic/javascript-on-widget-admin-page/#post-1745852)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
