[jQuery] form submit
hello, Recently i've discovered how to use dynamicaly loaded content, with javascript. $("div ul li a").live("click", function() { //..... } Now I want to know.... I'm using a small form, with more than 1 field, and a 'submit button'. which looks like this: Type: <select name="typecoinsCASHIN" id="typecoinsCASHIN"><option value="0">Normal chips</option><option>Premium chips</options></ select> Amount: <input type="text" name="amountCOINSCASHIN" /> <input type="submit" name="chipInChips" id="chipInChips"
[jQuery] What Do I Do wrong?
Hello, I have the following jQuery code: $(document).ready(function(){ $("a.navia:not([id='imprint'])").attr("href", "#"); $("a.navia").click(function(){ var active = "div#subnavibg" + $(this).attr("id") + ":hidden"; $("div.subnavibg:visible").slideUp(500); $("a.navia.selected").removeClass("selected"); $(active).slideDown(500); $(this).not([class='selected']).addClass("selected"); }); }); I think it's quiet clear what the aim of the script
[jQuery] Select tags within a string using jQuery
Hi all, I have my website getting a value as a result of an ajax call. After that, I would like to insert that result (a string) into a tag. However, I would like to insert that result in a way that (1) it must have opacity = 0, then (2) it will slideDown() so the whole content list being pushed down using animation, and finally (3) change opacity = 1. Imagine this is just like a Facebook message list insert process The way I am planning to do this is to return the result string from ajax to opacity=0
UI Slider inside TD overflows vertically
I used the UI selectToUISlider plugin (downloaded at http://www.filamentgroup.com/lab/update ... a_support/ along with jQuery) to create a slider input from a select input inside a table. Instead of the tic marks being inside the slider box and the labels horizontally underneath, the OL overflows vertically: How it should look How it does look The overflow is not visible when "overflow:hidden;" is set on the TD, and it still shows up when the height of the TD is increased. I know that these inputs
Clear Before Reload?
Greetings! Being new to jQuery, I had a simple question for the community Consider the following code: <html> <head> <script src="jquery-1.3.2.js"></script> <script type="text/javascript"> function DocLoadup(HTMLName,DestDiv) { $(document).ready(function(){$("div#" + DestDiv).load(HTMLName);}); } </script> </head> <body> <a href="javascript:void(0)" onclick="DocLoadup('Test.html','div1');">Test Load</a><br><br> <div id="div1"> </div> </body> </html> All seems straightforward enough; and all works
[jQuery] Slow response to AJAX calls in IE7
I am developing quite a complex user interface in jQuery that relies on an AJAX call to retrieve JSON. We have noticed that the code runs slow in IE7. IE8 and IE6 are acceptable. Firefox and Chrome really quick. I have traced the problem back to the AJAX call, which IE7 seems slow to process. What takes less than a second in the other browsers will take IE7 3 or 4. I have googled for an answer it seems there is some consensus that the native XHR in IE7 is slow, so it may not be a specific jQuery
[jQuery] how to make a function with JQuery
Hello every one, I'm a new user of JQuery and i'm trying to use it on a web site that i'm building. Keep in mind that i'm also new on the web. So i wanted to know: - How to define a function with JQuery. - Does it works similary like woring with Javascript and DOM ? - Shall my function, if allowed, be defined in the $(document).ready () ... ? thank
[jQuery] get parent where
I've been trying to get a specific parent element traversing up the DOM until I find it, but it is getting to be some very verbose code, and I'm thinking there must be a better way. I have a bunch of events which is fired on a click, and I am trying to figure out which of the parent divs was clicked. Now I have something like this (this is a simplified version) <code> <div id="firstArea"> <ul> <li>First Item</li> <li>Second Item</li> <li>Third Item</li> </ul> </div> <div id="secondArea"> <span id="subSecond">
[jQuery] fxqueues with afterFinish ?
Hi All I've beem using prototype and scriptaculous and want to swith to jQuery. The thing is that scriptaculous has a very nice queuing mechanism. I think most of it can also be done by fxqueues, however I don't see how to call a function when a certain effect finishes. Can this be done ? and is fxqueues the best choice ? Scriptaculous does something like: .... new Effect.Parallel(effect[i], { queue: 'end', duration: duration[i], afterFinish:callback} ) ... thnx LuCa ps fxqueues: http://www.decodeuri.com/jquery-fxqueues-plugin-20/
[jQuery] validate - require validation in multiple varying instances
I'm using the jquery validator supplied here: http://bassistance.de/jquery-plugins/jquery-plugin-validation/ The form I made has six different sections corresponding to six different sets of information being entered. For clarity, I should mention that this is an RSVP form, and the user is able to RSVP for up to six people. The sections and input fields are numbered accordingly: section1 firstname1 lastname1, section2 firstname2 lastname2... section6 firstname6 lastname6 To indicate how many people
[jQuery] tooltip on newly added elements?
Will tooltip show itself when I add IMG with tile and alt? or do i have to reinit it everytime?
[jQuery] sliding button
Hello guys, I'm trying to create a couple of "download" buttons (one placed at the left and the other at the right of my page) with sliding effect: basically I want to show just a piece of it and when the mouse goes over to slide it in order to show if the linked document is available or not. I have successfully implemented the effect I want for the right button as described below: #HTML <div class="download_badge" style="float: right;"><img src= "badge_whitepaper.png"></div> #CSS .download_badge
[jQuery] What am i doing wrong????
When I add this rule to a page with the other rules, my page stops validating. Works fine if I don't add it. What this is for is a check box next to a input box. IF the check box is checked, the field is mandatory. OtherCruiseLine: { required: function(element) { return $("input[name='CruiseLinesPicked'][value='Other']").is (':checked'); } without this rule the page validates. With this I get an error of: missing } after property list. But not sure what's wrong.. Thanks!
attribute!=value is not returning the same results as XPath.
I have a page with 21 TD elements that have a valign attribute set to top. 2 of these have an align=right. 4 of these have an align=left. using a regular Xpath expression: /td[@valign="top" and not(@align)] correctly returns 15 TD elements from my page, 21-4-2 = 15. the JQuery selector: $('td[valign="top"][align!="right"][align!="left"]'); returns 0. $('td[valign="top"][align!="right"]'); returns 19, correctly. $('td[valign="top"][align!="left"]'); returns 2... There is no align attribute set on
[jQuery] Evaluating json problem
Hello, I'm trying to execute simple scenario, from the server side (servlet) I'm returning: out.print("[{\"type\":\"basic\"}]"); on the client side I have : var dataURL = "<%=response.encodeURL(request.getContextPath())%>/ FetchData"; var items1; $.getJSON(dataURL, function(json){ eval("items1="+json); }); FireFox is showing jscript exception in the console: Error: missing ] after element list Source File: http://localhost:10038/wps/PA_1lb791mt//jsp/html/test.jsp Line: 345, Column: 15 Source
swfobject variable xmlDataPath not working
I'm trying to embed some flash into my site and, for some reason my xml file isn't playing nice with the swfobject var xmlDataPath. I have no idea why, any help would really be appreciated. <script type="text/javascript"> // <![CDATA[ var so = new SWFObject("<?php bloginfo('template_url'); ?>/banner.swf", "banner", "960", "555", "9", "#fff"); so.addVariable("xmlDataPath", "this is passed in via FlashVars for example only"); // this line is optional, but this example uses the variable
[jQuery] How can I select an element's parent?
Hello guys, I'm trying to update a script I found out there in order to fit better my needs. The first step I want to update is the capability to bind a dynamic number of anchors. Right now with the HTML below <ul id="product_links"> <li class="first" ><a>FIRST></a></li> <li class="second">SECOND</a></li> <li class="third"><a>THIRD</a></li> </ul> I have the script below: $("#product_links .first a ").bind("click", function(){ pupup_element ("first"); }); $("#product_links .second a ").bind("click",
My inelegant code for remembering position of panel :(
Hi all, I know someone will enjoy rewritting this chunk of code for me and the community! It's a simply cookie to remember the position of an animated panel so it stays open (or closed) after a page reload. It is working*, but I am sure it can be shorter! Please educate me! *Actually it's not perfect, when you close the panel you lose the button altogether until another page refresh! Long code that doesn't work! $(document).ready(function(){ $("#AdvancedSearchButton").click(function(){ $("#SearchResultsHeaderContainer").slideDown();
Ninja CSS Cost Estimator
Hello, I would like to build a cost estimator similar to http://www.cssninjas.com/. I have seen several example but none have exactly what CSSninja has. What do I use? How do I do it? Thanks in Advance.
[jQuery] Default Menu
Hi! I'm trying to show the selected menu with a different color background when a user clicks on a particular main menu item. This works with a ul that does not have child items on it. But ul's with child elements the css does not seem to work and seemed overridden by javascript. What i did was on the program logic that automatically produces the unordered list of menu items, I inserted a class 'sfHover' for li items that is equal to the current page. Again, this works on the menus that does not
[jQuery] jCarousel Bug???
I am attempting to use multiple carousels with a callback function on one page, and for some reason when I click the next button of one carousel, a previous on the same page increments as well as the carousel that contains the next button. After doing some debugging I realized that the both carousels have the same instance of the callback function. Why is this happening?
[jQuery] jquery not work when firebug in on
windows xp firefox 3.0.6 jquery:1.3.2(latest release) script: $(document).ready( function() { $("a").click( function(event) { alert("Click"); } ); } ); when i turn the firebuf off,it works well. Please help. thanks.
[jQuery] page-sliding jQuery Javascript code not playing with DHTML page
Using the following code example from Scott Robbin, which simply allows for separate html pages to slide in and out of the one screen, I wanted to expand this by sliding in some DHTML. Here is the page-sliding code used: http://srobbin.com/blog/jquery-pageslide/ DHTML animated code: http://www.dhteumeuleu.com/colorsyntax/viewJS.php?src=yoshisland.html&sound=smw21-1.mid (http://www.dhteumeuleu.com/dhtml/yoshisland.html) ...but, at best, only the images show, placed still and next to each other. As
sliding panes not displaying DHTML
I really like the following code example from Scott Robbin, allowing me to slide pages in and out of the screen, however I wanted to slide in some DHTML from here: http://www.dhteumeuleu.com/colorsyntax/ ... mw21-1.mid (http://www.dhteumeuleu.com/dhtml/yoshisland.html) ...but, at best, only the images show. Well they don't, I've even tried hard linking to them. I know the links are valid because opening the page on its own they all show up, so there's an incompatibility somewhere. Here's my page:
[jQuery] Message didn't disappear in validation plugin
I use jquery validation plugin 1.5.5, and got problem with error message. They don't disappear when the form is valid or when i use multiple rules, second rule message didn't show, the message is still the first rule message. Here's the code: $(document).ready(function () { $('#user_form').validate({ rules : { username : { required : true, min : 4, max : 32 }, password : { required : true,
[jQuery] Unable to trigger a event on page load
I bind a custom event on page A,then ajax load page B。In page B,there is a <a> link which trigger the custom event. Problem is :the trigger function work when i place the trigger function in page A ,but not work in B by ajax load. Help! jQuery Core:v1.3.2
setTimeout not delaying...
anyone can analyze what went wrong? the setTimout wont delay, it just closing the dialog box. function formulirAjax2($idForm,$idPesan,$idPreloader,$idContainer,$idTabel,$idDivForm){ $($idForm).ajaxForm({ target:$idPesan, beforeSubmit: function(){ ShowPreloader($idPreloader,$idPesan); }, success: function(){ HidePreloader($idPreloader); function tutupDialog(){ $($idDivForm).dialog('close'); }
[jQuery] apply css style after dynamic table row
i am calling web service and build dynamic table row. It work up to here. and then i trying to apply css style on <td> after that and it didn't work. Is there a work around? <table id="tbid"> [I added row content dynamic by jquery here] <table>
[jQuery] jCarousell and tabs problem
Hello all. I have a problem with the jCarousel Plugin when i try to display a second carousel inside one tab. Ok, the first one displays the right way. When i click the second tab, the second carousel is displayed but with a width of 60px (that i don't know how they got there). My html is this: <head> Section: <!-- Import jQuery and plugins --> <script src="lib/jquery-1.3.2.js" type="text/javascript"></script> <script type="text/javascript" src="lib/jcarousel/lib/ jquery.jcarousel.pack.js"></script>
jQuery selectors not working?
I have the following jQuery code to try and shift about_sheet right when about_tab is clicked. I used alert($) to confirm jQuery is working, and have also chosen another random div and tried to hide it, which also failed leading me to believe that the issue lies in the selectors. Here is the code: <script type="text/javascript"> $(function() { $("#about_tab").click(function() { $("#about_sheet").animate({"left" : "300px" }, 4000); }); }); </script> Thanks,
[jQuery] Reply to Default Menu post
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> </head> <body bgcolor="#ffffff" text="#000000"> <font size="-1"><font face="Microsoft Sans Serif"><big>Hi, It wasn't clear to me if you were talking about the treeview.js plugin or not. If not just ignore this reply. If so, see the following figure. If this is the effect you want I'll send you the code. Notice that the leaves have a blue background; the nodes have a transparent background. <img alt="" src="cid:part1.00070608.07020009@gmail.com"
jQuery ::: Assign a function dynamically?
The function below formats a text field for autocompletion based on the element id. The thing is, that when a user begins typing in the field, another row with the same name will appear beneath it, so that the input fields wind up looking like this: <input id="months" type="text" name="months[]" value="" /> <input id="months" type="text" name="months[]" value="" /> <input id="months" type="text" name="months[]" value="" /> Since each input field can only have one id, and the id has to be unique,
jquerry Lightbox Opens when someone tries to close browser
I have seen this script a few places, not sure it was jquery but I figured it was. I am looking for a script that opens a lightbox when someone moves the mouse over to close the browser window or change the url or type in the search bar, a lightbox pops up. I spend a bit of time searching and can't find the script.
[jQuery] jQuery [treeview] Question
Hi, I'm a jQuery beginner. My browser is Firefox 3.5.1 I'm using Treeview 1.4 Revision Id: jquery.treeview.js 4684 2008-02-07 19:08:06Z joern.zaefferer I have two questions: 1. Whenever I click on either of my two Treeview control labels "Collapse" or "Expand" (see below) the respective label visibly gets the focus (dotted border). I want to remove (blur) this border, but I don't know what I need to change in the treeview.js code to get this effect. How can I do this? Relevant portion of my code:
find() working only once on AJAX result?
Hi, all I'm new to jQuery and I'm having a bit of a problem manipulating AJAX results with jQuery methods. I use an AJAX get and execute the find() method on the resulting output. But this seems to work only once. Subsequent attempts using the same selector in the find() argument don't work. Different selectors will work, but again, only once. There seems to be something going on when traversing the AJAX result? $(document).ready(function() { $.get('sections.htm', {}, function(data) {
[jQuery] jQuery ::: Assign a function dynamically?
The function below formats a text field for autocompletion based on the element id. The thing is, that when a user begins typing in the field, another row with the same name will appear beneath it, so that the input fields wind up looking like this: <input id="months" type="text" name="months[]" value="" /> <input id="months" type="text" name="months[]" value="" /> <input id="months" type="text" name="months[]" value="" /> Since each input field can only have one id, and the id has to be unique,
[jQuery] lightbox problem when using scrollable
I'm using a gallery scrollable component for thumbnails. When a user clicks on the thumbnails it loads that larger version of the image into a div on the same page. All the large images are already loaded into the div. My problem is when a user goes to click on the larger version of the image I want it to open with lightbox, but no matter which thumbnail they click on, it always starts at the first image in the lightbox. You can see the problem shown here. http://tsutsumidaphoto.com/Mihoko/akiko3.php
Ormeo - Comment Anywhere
A lot of jQuery in this: http://www.ormeo.net (Currently stable on Firefox only) Feedback greatly appreciated, please put it in http://ormeo.uservoice.com even if you put it here too, thanks!
Multiple instances of a function
Firstly, please pardon me as I'm extremely new to both JavaScript and jQuery. This also may be a JavaScript related question rather than jQuery specifically, but here goes: I have a simple navigation menu. On hover, the block element changes background color. I'm also fading in/out a div layer. I'm also using the jQuery Color Animations plugin. Very simple to accomplish and I had no trouble doing so. However, I don't want to have to use a whole new function for each individual element, so I wrote
[jQuery] Overflow difficulties
I have this website: http://www.vampsworld.com/freelance_projects/aawc/ with this JQuery: <script type="text/javascript"> $(document).ready(function() { $('#homemenuoption') .css( {backgroundPosition: "-20px 35px"} ) .mouseover(function(){ $(this).stop().animate({backgroundPosition:"(-20px 94px)",height:"231px"},{duration:200}); }) .mouseout(function(){ $(this).stop().animate({backgroundPosition:"(40px 35px)",height:"34px"}, {duration:600,
Next Page