Get Both Of The(for The Thumbnail To Main Img Swap And The Navigational Arrow Swap) To Work?
May 8, 2010
i have been tryin for a long time to get both of the javascripts(for the thumbnail to main img swap and the navigational arrow swap) to work in synchit needs to be so that after clicking on a thumbnail then on an arrow, the correct image in the correct order appears. as of now they are running separately and one has no influence on the other. forgive me if im not being clear. i keep trying to replace the id that one script is looking for with the same id from the other but this will not work..why?
i have a thumbnail gallery of pictures on my page. I also have one area where i feature one of the gallery pics in larger format. Imagine a photography website, when a thumb is clicked, the larger pic is populated in the Feature section. Ideally this is all on one HTML page.
See code below. <body> <table width="770" border="0" cellspacing="0" cellpadding="0">
i have a sliced page from photoshop. how i can change the main banner part at the top so that it gradualy changes over a period of time, i was thinking maybe a swap image thing, but not sure.
I am trying to put together a purse shopping site - I would like to have the various views of the same purse in thumbnails under one image then when the customer clicks on the thumbnail the larger image will go into the viewing area. The general layout is like this page - [URL] So when someone clicks on the smallest image I would like it to replace the other image on the page and the larger image becomes the thumbnail. How is this accomplished?
I tried a Javascript on my homepage that works fine on Netscape, works nearlyx normal on Opera but does not work at all on Internet Explorer. Is there anybody out there who can help? I use a frameset of 3 frames. One of these Frames has thumbnails with the javascript code for the image-swap - the big picture should change whenever someone clicks on the corresponding thumb. Code:
I would like to add a submenu that pops up when the mouse moves over the first-level menu option. I succesfully added the submenu. However, now the image-swap script (the script that makes that the image that you see change as you move your mouse on the image) doesn't work anymore.
The relevant part of the header:
<script type="text/JavaScript"> <!-- function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
I am a complete novice with Javascript, but am trying to work out how I can get a button to swap to another image when clicked, and each image have a different URL attached. I want to use this to toggle the bgcolor of my page using this script:
Code: <script type="text/javascript"> <!-- function createCookie(name,value,days) { if (days) { var date = new Date(); date.setTime(date.getTime()+(days*24*60*60*1000)); var expires = "; expires="+date.toGMTString(); [Code]...
I have a site with 2 frames. The navigation frame is on the right side and the larger main frame is on the left. The navigation frame is nothing but a bunch of thumbnails that scroll when the mouse hovers over “up/down�. The links are the thumbnails. I hope you get the picture… a user would click on a thumbnail and go to a site. The problem is that I want the thumbnail to link to a site and open it in the frame on the left (the main frame.) The only options I have (through Dreamweaver) is _blank, _parent, _self, _top.
The script I think that might need to change is below. Can anyone help me and figure out what needs to be changed? Code:
I have a gallery consisting of thumbnail images and a big image...pretty standard stuff. Anyway i'd like the big image to fade in when a thumbnail image is clicked and can't find any tutorials on how to do this. I have found ready made galleries using jquery but thought there might be something i could do with my existing html/css. I'm new to javascript and wonder if someone can point me in the right direction? Is this more complicated than it appears to be?
I've hit a little bit of a road block developing this site: [URL]. I'm attempting to use the thumbnails to load a new video in the main object. I've used this: $(document).ready(function(){ $('.thumbnail').bind('click', function() { new_video = $(this).attr('href'); $('.main_video').attr('src', new_video); $('.main_video').siblings('param').attr('value', new_video); return false; }); }); To replace the attributes in the object, but at this point, the source has the new arguments, but it needs to reload as the actual element still contains the old video. Should I somehow use AJAX to refresh this div? Should I reconstruct my jQuery somehow?
With IE 7 you don't get the class to work. It swaps out the first class but doesn't add the onmouseover class. Am i missing something here or is this just another reason to hate IE?
I am looking to find a javascript that image swaps 4 button images that are to be used as links.
There will be an unvisited button (color of my choice)
There will be a hover state which Is green.
There will be a visited link button that is purple.
There will be a currently active page button that will be red.
I have a script that works for 3 of the for states. The script that I have also will not keep the purple, visited state, as standard text based links will when a page has allready been visited. Does anyone have a script that will work for what I want to do for all states.
I don't know how to build a script of my own, but plan on learning.
Does anyone have a script that will work for what I want to do for all 4 link/swap states that I want incorporated?
I want this to work EXACTLY like Facebook, so that when you click in the "Write a comment..." input field and it makes your photo and COMMENT button appear. Viewing their source doesn't help me. Here are my divs
I have seen this technique on a couple websites, but haven't been clear on how it's done. What I am looking for is to have a form with x-options. The technique is that when the first option is selected it auto updates the other options to correspond. For example if I was looking for specific cities in a state. Once a state is selected I am only given specific cities. The end result is to combine this with php and mysql, but I am sure if I understand the javascript aspect I can run with it.
I'm looking for a solution that can be used in a calendar/gig guide scenario where each day is represented by a dot image. Now this dot must do the following
1. When the mouse goes over the dot image it swaps to the mouseover dot
2. When the mouse goes out of the dot image it restores back to the original img
3. When the img is clicked the dot image is swapped with another image (different to the other 2) that will remain there even when the mouse goes out of the image
I wish to modify the dimension of the font within a given table (that is, not yet in the whole page); when I hit a button, the font's size increases by 1 point; another button decreases it by 1 point (starting from the default size), and a last button will reset it to the original size.
Pratically, whichever might be the default size (which I set from three css, swapped accordingly to the screen's res), the text inside that table it should be resized only by step of +1 or -1 point from the default size. Any ideas?
I have a portfolio page which loads a dozen thumbnails and one large image. A friend helped me code a script (below) which will swap out the large image (named "imgLarg") when a different thumbnail is clicked. Both the thumbnail and the enlargement are identically named, one is in /thumbs/ and one is in /enlargements/ - tricky, huh? ;-) What's the easiest way to make this work in other browsers as well?
I have a page that is a displaying a Movie, or it's really 3 Movies but to get to the 2nd Movie the user has to click a "Next" button. My problem is that I want to delay this button to appear until the movie is more or less done... could be 7 or 16 minutes. What would be the easiest and most propriate way to do this using jQuery... swaping out one DIV for another once after X minutes?
I have a large div with a Google Map and a much smaller div with Google Streetview. I want the user to be able to click a button and make the large div show the street view and the small div show the map. I'm hoping jQuery can be used to make this 'easy' somehow?
I just don't know how to approach this .. 1) Resize the divs and change z-order? 2) Swap the id of the divs and somehow trigger a refresh? 3) Swap the html using jquery?
I am trying to getelementbyclass and than on click change the displaytype or change to use another class for that div.Below is what I have so far, but I can't get the div style to change based on getelementbyclass.On click I would like to change the targeted div to use .show class and all others still to use .hide class.Any way to do this? Am I close?
Code: <script type="text/javascript"> function showHideAll(id) {
I'm attempting to make it so it physically swaps the element position within DOM (the index, in other words) when someone clicks on a button. It will either be the element right before, or right after (depending on which button they click). I'm using jQuery, so if there is an easy way to do it using that, please let me know. If not, I can use jQuery to get the DOM elements using .get(). I don't know if I can just just do something like:
Code:
var domElements = $('.draggable').get(); var tempElement = domElements[index + 1].cloneNode(true); domElements[index + 1] = domElements[index].cloneNode(true); domElements[index] = tempElement;
It doesn't seem to work quite right. Should I use replaceChild or something? Don't know if it would work, here? I will know the index, so that's not an issue, here, it's just a matter of getting it to reorder the elements, so when I loop through them, they are processed in the correct order.
I want multiple images to be able to call this function and run it as planned. This is my question, how do you make it so that the name of the tag can be dynamic in the function. if I don't make myself clear, here's my code if it helps.
<html> <head> <title>Example</title> </head>
[Code]....
Ok, so this isn't EXACTLY my code, but it's exactly the same thing as what I'm doing. I just gave some parts easier names, so it's easier to follow. Oh, and if I forgot to say, this is an image swap.
I've been banging my head for two days now trying to figure out how i can swap td cells. There are a lot of examples of how to order rows, but i can seem to find any on how to swap td cells. Has anyone a good referal for this.