I have a drop down that is being dynamically generated, so it could have anywhere from 1 to 50 options. I'm having real trouble at that part. Each of those options, if they exist, will have a corresponding numeric div I need to show based on the selection. For example...
I've got the javascript to achieve this if the numbers are static, but Im not sure how to make this more dynamic or flexible so I can have a varying amount of numbers. Can anyone please help?
Currently this script is outputting the exact mathematical calculations I need it to perform. Can someone show me how to change these from simply outputting formulas to actually executing them?
Current example output: "Values added together and multiplied by the variable: 4 + 6 X 5"
Desired output: "Values added together and multiplied by the variable: 50"
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<p class="holder">Values added together and multiplied by the variable: <input type="text" id="amountfour" style="border:0; color:#f6931f; font-weight:bold;" /> </p>
I've built a single page site that uses div id tags in the URL and Jquery to handle navigation (index.php#home, index.php#about, etc.)
Whenever the user visits index.php and clicks a link, it takes 2 clicks to make the navigation kick in; I believe this is because it's missing an ID tag. Once it's set to index.php#home, index.php#about, etc. it works fine.
Is there anyway to check if an id is assigned in the url and if not, add #home to it?
I am currently working on the checkout screen for a shopping cart. I want to have a dropdown such as "Would you like to use saved Billing information?" if they have saved info to their account before. If they choose an existing address, I'd like to hide the fields so they don't get confused and think they need to enter anything.
The "options" will always have numeric values (0, 1, 2, 3, etc.)
I am pretty new to jQuery so here is the script I wrote, but sadly it isn't working. Can anyone help me make this work or show me a better way to achieve it?
I'm really in love with the Jquery Mobile CSS system. It's beautiful and it's sliding functionality is awesome.
However I'm new to it and I'm running into some beginner questions.
Mainly, how can I pass an argument through the URL? If I do index.php#one?id=1, Jquery says it can't load it. I need to pass ID's through my URL so I can use PHP to dictate what is shown.
I'm sure there is a way to do this. Does anyone know?
I have an interesting project that I'm sure someone has done before. I need to essentially recreate the effect on the Bing homepage where you can mouseover different parts of an image and be displayed different tool tips depending on where your cursor is.
I don't want to use Flash for these things unless I absolutely have to. It seems they could be done with CSS purely but I was wondering if there is a more attractive/prettier way to do it with Jquery?
I'm currently programming a website and we wanted to have Jquery on it. This is my first real foray into Jquery (other than occasionally using a plugin here and there) so I'm a bit confused as to why what is happening is happening.
The idea is to have 3 different things going on:
At the top of the website we want rotating ads. When one of them is clicked, it opens a video file in Lightbox style (darkens the BG)
3 rotating banners below that, when clicked they just go to a website
3 more buttons with play buttons in the corners. When the play button is clicked, a video player takes over the button and plays the video.
So far I have the 2nd and 3rd one working. The video player works, the Jquery shows and hides the divs appropriately, and the rotating banners work great.
However I am having problems implementing a lightbox style onto the top banner.
I found a Jquery thing called Shadowbox but for the life of me I can't get it to play nice with the code I wrote for the show/hide div functionality for the video player.
If you click the play button on the latest news button, it will play a video. While the video is playing, click one of the banners at the very top of the screen (the ones that say Placeholder Ad). The video player will disappear and no shadowbox pops up.
Why is this? What am I doing wrong? I figure it's an ID issue; that shadowbox is applying some div replacement behavior to everything of a certain type, but I don't know how or where to fix it.
You can see the code in the HTML of the link, but here is the code for the Latest News box:
<script type="text/javascript">
$(document).ready(function(){
$('#content1').hide();
$('#layer_box a#click').click(function(){
$('#content1').show('slow');
$('#play_button').hide('slow');
$('#layer_one').hide('slow');
});
$('#layer_box a#close').click(function(){
$('#content1').hide('slow');
$('#play_button').show('slow');
$('#layer_one').show('slow');
})
});
</script>
If anyone could help me get this working I would greatly appreciate it. I'd really like to learn why its breaking and how to fix it. Jquery is very powerful and I want to use it a lot in the future, I'm just not sure how to troubleshoot compatibility issues like this just yet.