[wp-hackers] Troubling with jQuery (UI/Slider) and/or wp_enqueue_script()

Frank Helmschrott fhelmschrott at gmail.com
Sun May 31 07:47:05 GMT 2009


i'm dealing with my first completely self written plugin for 2 days
now (hooray).

After i found everything quite simple i've already spent some hours
now fiddling around to get the jQuery UI Sliders running on my plugins
option page. I'm trying to completely do this via wp_enqueue_script
and without adding some manual <script src...> stuff - i think that's
the way it should work.

Here's the method that enqueues the important stuff:

			function register_admin_scripts()

it get's called via init action which basically works.

That's what the output source looks like:

<script type='text/javascript'
<script type='text/javascript'
<script type='text/javascript'

jQuery basically works, Farbtastic color picker works. What doesn't
work is the slider. I get the following error through firebug:

F is undefined
Line 12

Line12 is the basic jQuery stuff.

Two questions:

- Does anybody now where this error may come from? I guess the loading
order should be ok

the second is a more basic one:

- Why do jquery-ui-slider and my script not get loaded via the
load-scripts.php? Is there any way to get that working (not really a
matter in this case but could be a performance win on the public

Thanks for helping!


More information about the wp-hackers mailing list