Home › Forums › JavaScript › Trouble with jQuery and WordPress
- This topic is empty.
Viewing 1 post (of 1 total)
-
AuthorPosts
-
May 6, 2010 at 4:48 pm #28952benkulbertisParticipant
Hello there, I am a begginner at jQuery and I am trying to do a simple accordian list that displays below it more information when the link to each section is clicked. My code has jQuery code has not been executing, and I am at a complete loss to why. jQuery 1.4.2 is loaded, I verified it with a simple line that alerts me. My code should be valid, I tested it in jsFiddle (http://jsfiddle.net/GU5s2/) and it works exactly as I intend. I disabled all plugins and I’m pretty sure that jquery is running in no conflict mode. Here is my jquery code:
Code:jQuery.noConflict();
(function ($) {
$(‘.more’).hide();
$(‘#htmlcss’).click(function() {
$(‘.more’).hide(300);
$(‘#htmlcssmore’).show(300);
});
$(‘#php’).click(function() {
$(‘.more’).hide(300);
$(‘#phpmore’).show(300);
});
$(‘#js’).click(function() {
$(‘.more’).hide(300);
$(‘#jsmore’).show(300);
});
$(‘#gen’).click(function() {
$(‘.more’).hide(300);
$(‘#genmore’).show(300);
});
$(‘#convert’).click(function() {
$(‘.more’).hide(300);
$(‘#convertmore’).show(300);
});
$(‘#theme’).click(function() {
$(‘.more’).hide(300);
$(‘#thememore’).show(300);
});
$(‘#complete’).click(function() {
$(‘.more’).hide(300);
$(‘#completemore’).show(300);
});
$(‘#server’).click(function() {
$(‘.more’).hide(300);
$(‘#servermore’).show(300);
});
})(jQuery);and my HTML:
Code:Can anyone shed some light on this problem? Thank you!
-
AuthorPosts
Viewing 1 post (of 1 total)
- The forum ‘JavaScript’ is closed to new topics and replies.