I have been developing this website (First Day)
My javascript for the Beliefs section was working previously, then I changed it because the design changed a little. The javascript is the same except I needed to hide some elements when the page loaded. On a click, depending which word is clicked, that description will show up, and the others (if any were already shown) will disappear. The change I made works on my local machine, but doesn't work on my web server. What could be wrong with my javascript?
Here is the edited code; however, it is still not working
Thanks for any help. This is one I cannot figure out.
Here is the link to the zipped folder of the website. Dropbox Zipped Folder
JavaScript Code:
$(document).ready(function(){
$('.Descriptions').hide();
$('#God').click(function () {
$('.Descriptions').hide();
$('#GodDescriptions').show();
});
$('#Jesus').click(function () {
$('.Descriptions').hide();
$('#JesusDescriptions').show();
});
$('#HolySpirit').click(function () {
$('.Descriptions').hide();
$('#HolySpiritDescriptions').show();
});
$('#Bible').click(function () {
$('.Descriptions').hide();
$('#BibleDescriptions').show();
});
$('#Man').click(function () {
$('.Descriptions').hide();
$('#ManDescriptions').show();
});
$('#GodsRelationship').click(function () {
$('.Descriptions').hide();
$('#GodsRelationshipDescriptions').show();
});
$('#Salvation').click(function () {
$('.Descriptions').hide();
$('#SalvationDescriptions').show();
});
$('#SavedWho').click(function () {
$('.Descriptions').hide();
$('#SavedWhoDescriptions').show();
});
$('#Perseverance').click(function () {
$('.Descriptions').hide();
$('#PerseveranceDescriptions').show();
});
$('#GospelOrd').click(function () {
$('.Descriptions').hide();
$('#GospelOrdDescriptions').show();
});
$('#Resurrection').click(function () {
$('.Descriptions').hide();
$('#ResurrectionDescriptions').show();
});
$('#ChurchGov').click(function () {
$('.Descriptions').hide();
$('#ChurchGovDescriptions').show();
});
$('#SecondComing').click(function () {
$('.Descriptions').hide();
$('#SecondComingDescriptions').show();
});
$('#Missions').click(function () {
$('.Descriptions').hide();
$('#MissionsDescriptions').show();
});
});
unbind("click")somewhere else and that's removing the click bindings you have above. Can you add analertto the onclick and document ready functions to see if it's being triggered? As an after thought what browser are you testing this with?