Parents, text copy,
Although I am using swfobject in this sample, it is a question for parents more than it is about the plugin. Here is my js: <script type="text/javascript" src="jquery-1.3.2.min.js"></script> <script type="text/javascript" src="jquery.swfobject.1-0-7.min.js"></script> <script type="text/javascript" charset="utf-8"> $(document).ready(function () { $('blockquote').flash({ swf: 'copyButton.swf', height: 30, width: 130, flashvars: { txtToCopy: $('#post-144 blockquote').text()
How to make iFrame working?
How to make iFrame working? I enclose files.
Menu hover function repeats
As you can see in the link provided. When the menu is hovered over a few times. I get this wavy action. Can it be fixed? http://www.kill-on-sight.com/413/index.html <script type="text/javascript" src="http://code.jquery.com/jquery-latest.js"></script> <!-- Call latest jquery plugin --> <script type="text/javascript"> $(document).ready(function(){ $('.subnav').width($('.subnav').width()-2); $('ul.topnav li').hover( function () { $('.menu-first', this).addClass('slide-down'); $('.subnav', this).slideDown(300);
$.ajax problem
Hi guys, I'm hoping that you can help me with an intermittent issue I've been having. I have a block of code that looks roughly like this: <form method="POST" id="milform" name="milform" action="^$this^"> <div>Create Military</div> <div style="float: left; width: 500px; border: solid 1px grey;"> <div class="statuslabel">Military Name:</div> <div class="statusfield"><input type="text" name="milname" length="32" size="32"></div> <div class="statuslabel">Army Name:</div> <div class="statusfield"><input
this + name of class
I want to into each element with class' right' write length text from left side inside element in class 'left': <ul class="item"> <li><span class="left">aaaaaa</span><span class="right"></span></li> <li><span class="left">bbbb</span><span class="right"></span></li> </ul> <ul class="item"> <li><span class="left">cccccccc</span><span class="right"></span></li> <li><span class="left">ddddddddd</span><span class="right"></span></li> </ul> I have:
multiple checkbox toggle
Hello, I hope someone can help. I have some jQuery code to add and remove a class to toggle an image. It works for one but now I want it to work if I add other checkboxes. Currently all the checkboxes change the 1st div. I would like to make it toggle it's respective div. Any help would be great! Thanks in advance! <html> <head> <title>jquery to Show/Hide a Div</title> <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.1.min.js"></script> <script type="text/javascript"> $(document).ready(function(){
Ajax call not working in Firefox and Google Chrome
Hi, I'm a newbie to jquery and am using jquery version 1.4.2 in my java application. I am trying to develop an application, where I am accessing the data available in a remote server and rendering the data in an HTML page in my local system, using an Ajax call. The code works fine in IE7 and above. However, I am facing a problem in Firefox ( version 3.5.8) and google Chrome. The following error is reported in Firefox - Error: uncaught exception: [Exception... "Access to restricted URI denied" code:
Having trouble getting the value of select fields..
Ok so let's say I have something like this: <select id=stuff[0] name=stuff[0]> <option value="thing">Thing</option> <option value="other_thing">Other Thing</option> </select> <select id=stuff[1] name=stuff[1]> <option value="thing">Thing</option> <option value="other_thing">Other Thing</option> </select> I need to go through the stuff[] array via jquery and find out if ANY of them have "thing" selected. Major confusion. I've tried $('#stuff[0]').val(); just to get it to return at least one of the
Controlling the browsers scroll
Hi, I'm wondering if it's possible to control the browsers scroll bar from a link on an html page using jQuery? Basically I will have a bar at the bottom of the browser window with two links, one is an UP and the other is a DOWN button. When clicked I would like these to scroll the browser window. Is this possible? If so, can you direct me to which functions can be used or other resources help get me going in the right direction? Thanks, Spencer
building tree structure
Hi all, Did anyone try to implement the tree structure using JQUERY tree(or JQTREE) any any thing else, that acts like a open and close tree......the values to the tree comes from database. my data base has 5 cloumns (ID,PID,NAME, NUMBER, ROLE) Can somebody help me in building a tree structure with these values.
Proper use of using jquery regarding popups or hidden fields?
Hi, What is the best way to use jquery for a popup or hidden data. Add a hidden div containing the data Use jquery to populate the div with the fields you need etcI find number 1 to be the easiest but if you are creating a large site you have all this html that is not being used and I find it clutters up the code. Thanks
Huge jQuery Question! Full Browser Slider?
OK, new to the boards. I prefer jQuery over flash and not sure how to tackle this, so please advise as best you can. Trying to create a site that allows for images to go full browser and then have the ability to have the other images slide in based on a click. I also want to float a menu that will allow it to pull in other media (video, that would slide in the same way). The best example I can share is this: http://j.mp/5U79i1 What he is using is flash based (slideshowpro director and slideshow pro
Using jQuery to load content into a div, bugging out with Active Content flash?
So I'm using this code to load content into a div with id "load". <script type="text/javascript"> function pageload(hash) { if(hash) { if($.browser.msie) { // jquery's $.load() function does't work when hash include special characters like aao. hash = encodeURIComponent(hash); } $("#load").load(hash + ".html"); } else { // start page $("#load").load("1.html"); } }
.change not firing the first time in ie7
Hi, I am using: $(function() { //----------------------------------------------onload var viaje; var total; var precio; var precio_opcion_total; var num_viajeros = 0; var opcion_precio; var opcion_id; calculate(); $("input:checkbox.checkbox_opciones").each(function(){ this.checked = false; }); $("table.viaje").hide(); //----------------------------------------------events $("select#viajes").change(function () { $("select#viajes
Odd behavior in IE8 with "live" checkbox change handlers
This is from a Stackoverflow question. Somebody noticed that live-binding a "change" event to some checkbox elements tended to cause live-bound "click" handlers to not run. We then noticed that by changing the binding order so that "click" is bound first, things worked better. Finally, I noticed that regardless of the order in which "click" and "change" handlers were bound to the checkbox elements, binding (with "bind", not "live") a do-nothing "change" handler to $('body') would make the checkbox
Two selects in a page
Hi everybody, I need to know how to reload a component using jQuery, i got 2 selects in a page the 2nd one is populed by the 1st one value, how can i reload just the 2nd select w/o reload whole page? Regards, Mark.
Best practice for .each()
I was building custom field validation* for a form and it made sense to check each field with something like: $("#formID :input[validate='date']").each( function(){ validateThisField(this, 'date'); } ); It occurred to me that I'm writing an anonymous function who's only function is to call another function. So why don't I just write it like this: $("#formID :input[validate='date']").each( validateThisField ); It makes me have to pull a couple things in the function rather than just passing it in
validate plugin error messages combined with ajax response error message question
I finally found some time to get started with jQuery on a project. My first task is to learn the form validation, so I've setup a very simple form with the validate plugin, and also an ajax call to check to see if a username is unique. The validation works, as does the username check. My problem lies in the error messages that are displayed. On username, I have 2 rules in place: username : { required: true, rangelength: [5,50] } and then in messages I have 2 corresponding messages: username
Remove border on A:hover with IMG inside?
Simple really, only I can't work it out for the life of me. <a href='#'>Home</a> a:hover { border-bottom: 1px dotted #000099; } So how do I remove the border when I have a link like <a href='#'><img src="home.png"></a> I've tried $('a:hover img').parent().css('border','none'); in the document.ready, but I'm clearly doing something wrong. Any ideas? A.
Showhide issues
Hello all, New to jquery (as of this morning!) and javascript as a whole, so do forgive my lack of knowledge on coding. I'm attempting to make a slide down menu, i have succeeded to a degree, with a few slight problems i hope somebody can help me with, sure they're very simple ones! First is that when the menu loads (I'm using images rather than text as buttons) everything is fine, but when the 'design' menu button is clicked and the submenu options drop down, the deign menu button transforms from
$(this).find() not work
Good Morning! i was working with jquery 1.3.2 and jQuery UI 1.7.3 and changed the version to jquery 1.4.2 and jQuery UI 1.8rc3. Before these versions of jquery this code worked perfect, now with new version it does not work and i could not find the problem. Help please! function createBookingModal(module, options) { $("#bookingModal").dialog( { dialogClass: 'alert', autoOpen: false, modal: true, resizable: true, bgiframe: true, show: 'slide',
JQuery Order Form, with support for drop down lists and id
Hi, I am a complete begineer in relation to js and jquery, and am attempting to modify an existing order form script from; Site: http://dabrook.org/blog/articles/jquery-automatic-update-order-form-with-radio-buttons-and-checkboxes/ Page: http://dabrook.org/examples/cdia/javascript/05/form.html Currently the order form script only supports check boxes and radio buttons, but i am trying to update it to also support drop down lists and then only form elements with a specific id. Is this possible with
sending form using jquery and wyiwyg editor
Hi, My site: http://www.orchot-hagilboa.com/index.php?mid=1 My jquery form is working properly in most areas except where i have an online wysiwyg editor. If you look at the right side of the site, you will see the editor. It creates a textarea form field. When i send the form, the reply_desc (textarea name) is empty. I do an alert on that and you can see its empty as well. The way I grab my textarea is: [code] var comment = jQuery('textarea[name=reply_desc]'); alert(comment.val()); [/code] To take
Need to click twice to load image....
Hi all, I have created a gallery, which is visible at http://www.bessandsam.com/development2010/photos_testSAVE.htm Unfortunately I often find that I have to click twice on a thumbnail before the central image loads -- other people have reported this problem as well. The first click definitely registers -- the old image disappears and the new caption loads -- but the image itself often doesn't appear. I am using a really simple method for swapping the images, found in my JavaScript book: // swap
not able to remove nested lists in a jQuery variable
Hi I have a nested oredered list which i m animating using this code... var $li = $("ol#update li"); function animate_li(){ $li.filter(':first') .animate({ height: 'show', opacity: 'show' }, 500, function(){ animate_li(); }); $li = $li.not(':first'); } animate_li(); now i want
Unbind hover after click and refresh page,
Hi, How can i avoid hover if the mouse is focus on the link after click and refresh page? Im using a template (website baker) with a menu in jQuery. Hover effect will display a div and "click" will call a new page, but the template will refresh and the mouse will be situated in the link, so, the hover will do effect after refresh. Here is one example (hover works and after do click, i want to unbind hover in the link). Thanks! <html> <head> <script src="jquery-1.4.1.js" type="text/javascript"></script>
.hover not working in IE6 after transparent .PNG fix (help?)
Hello, Here is the website I'm working on: DEMO For my navbar and footer I use jQuery to do a nice fade in and fade out: $(function(){ var navbar = $('#navbar'), navbarLinks = $(".navbarlink", navbar); navbarLinks.hover(function () { navbarLinks.not(this).stop().animate({opacity: 0.3}, "slow"); }, function () { navbarLinks.stop().animate({opacity: 1.0}, "slow"); }); }); $(function(){ var footer = $('#footer'), footerLinks = $(".footerlink",
is callback after before() possible?
hi is there a way to call a callback function just after a before() statement targeting the element just created to inject some more html code inside it? Ex: $(function(){ $('a.add').click(function(){ addCampo($(this).attr('id')); return false; }); }); function addCampo(type){ type == 'addFoto' ? ( $('p#bottoniAdd').before(someHtmlCode)) : ( $('p#bottoniAdd').before(someOtherHtmlCode)); } Thanks Vitto
Wait until "if" statement is done?
Is it that possible? if($("#results").hasClass("busy")) { $("#gradiente").fadeOut(800, function() { $(this).remove(); }); } $("#results").append("<div style='height: "+ altura +"px; width: "+ anchura +"px;' id='gradiente' />"); for(i=0; i<=altura; i++) { var r = desde_rgb[0]-(step_r*i); var g = desde_rgb[1]-(step_g*i);
Events and Object
Hi all, I have an issue that I really cannot find out how to solve. Here is an example of what I'd like to do : function object() { this.init = function() { $(".object").click(function(event) { var val = $(this).val(); this.process(val); }); } this.process = function(val) { // DO SOMETHING } } Not surprisingly, this is not working. In fact, the function in the click event
active option remains highlighted
Hi, I am new to jquery and would like some help regarding my problem. I created an accordian menu which includes categories, sub categories and sub sub categories. Once you hover(css) on one of the menu options there is a hovering effect. What i would like to achieve now is that once a menu option is chosen that option remains highlighted (:active) until another menu option is chosen. How can i do this please? If anyone can help would be great. Thanks in advance!
jquery script interfering with another script
I have two scripts that are interfering with each other on my blog. I installed a new wordpress theme that has a rotating image at the top of the page. Since doing so lightbox stopped working on my site. Does anyone know if there is an easy way to solve this? The website I'm having the problem with is www.kerform.com/blog. Thanks.
jQuery image hover function
Hi Everyone, I'd like to accomplish a simple image rotator using jquery (and possibly php - for an img dir) that would rotate thru images on hover at a high speed. An example of this on www.cargocollective.com is accomplished with flash, but i'd like to use jquery if possible. I've been searching around the forums for a solution, but can't seem to find anything. I'm pretty new with this stuff so the solution may just be a few simple tweaks using the cycle plugin. Any ideas? Thanks.
I want to remove items from copy of form before .serialize()... but how?
OK, this sounds strange, but before a form gets submitted, I want to grab all of the data being submitted, and serialize to insert in a separate variable that's also part of a process that's separate from the form submission itself. The problem is, I only want to grab and serialize certain form elements (specifically, those that aren't "type='hidden'"). What's the best way to grab the form, duplicate the object temporarily, and remove certain elements from it, so I can then run .serialize() on
Date picker <div> location
Hi how can i change the location the date picker creates. the datepicker places the <div> at the end of the page. <body> <div>Content</div> <div id="ui-datepicker-div" style="position: absolute; top: 72px; left: 474.8px; display: none;"></div> </body> but i want to do <body> <div><div id="ui-datepicker-div" style="position: absolute; top: 72px; left: 474.8px; display: none;"></div>Content</div> </body>
Change img on toggle radio button
Hello all, I wanted to modify an img src tag with a radio button. I tried the following below, with no luck. Not sure I'm doing it right. Help! function toggleIMG() { if ($('#club-team').is(':checked')) { $('#logo_img').attr('src', 'club.jpg'); } else { $('#logo_img').attr('src', 'rival.jpg'); } } <input type="radio" name="team_kind" id="club-team" value="1" onchange="toggleIMG()" /> <input type="radio" name="team_kind" id="rival-team" value="2" /> <img id="logo_img" src="club.jpg"
Internet Explorer Invalid Argument Error
Code is working fine in Firefox but causes an error in Internet Explorer 8. It says that there is an invalid argument on line 116 of the jquery.js file. I am pasting part of the code that I think is causing the problem below. $("div#carousel").mouseover(function(event){ speed = event; }).mouseout(function(){ speed = 0.2; }); This is probably pretty basic. I am new to javascript and jquery. Any help would be greatly appreciated. I'm thinking that there is something wrong with the
Selecting a form by id in Firefox doesn't work
I have something like the following form: <form action="/profile.php" method="post" id="profile_form"> ... bunch of labels and input elements go here ... </form> Then a jquery call (which is supposed to serialize the form for ajax) in a <script> tag at the bottom: $("#profile_form").submit(function() { alert('never get here with firefox 3.6'); }); I get to the alert just fine using Chrome, IE8, Safari and Opera. Am I doing something wrong? This is with the latest version of jquery. Thanks for
Ajax Load a page with Google map Inside
Hello everybody, I tried to do a loading bar during the computation of the data of my google map, unfortunately without success for the moment. I use the load function serveral times but never with a google map / javascript, that's probably the problem linked to it. Here is my 2 html pages : 1- dynamicmap.html 2-googlemap.html. For information, I worked with Django, the googlemap.html works very well when I used this "outside" the dynamicmap.html ... I tried to add the function "initialize()" as
Select elements followed by another type
I'm trying to craft a selector that returns all textboxes that are immediately followed by a label. Can anyone help? Thanks.
Next Page