fadeIn() after fadeOut()...timing question
Good morning I have tried to find info in the docs for this but have had no luck. I have a page with a number of links that when clicked, will fade out any open pop-ups, and fade in the pop-up for the link that was clicked. How can I specify that the fadeIn should not start until the fadeOut is complete?
[jQuery] Printing contents of a tab within a lightbox-clone
Hello folks, I'm having difficulty getting the contents of a particular tab within a jquery-ui Tabs collection that is present in a "lightbox" (Fancybox) My print.css sheet is: html, body { display:block; } body * { display:none; } #printresults { display:block!important; opacity:1.0!important; } #printresults is the div within a tab that I want printed. But when I print (via an 'a' tag window.print() link) I get a magnificient blank page. Ideas/solutions/leads? Thanks/Bruce
[jQuery] Code evaluation
I have some jquery code that does what I want it to do but I was wondering if I could get some input/ suggestions/ opinions on how it could be better. Thanks for your time! here is the code: jQuery.fn.swapFade = function() { if (this.is(':hidden')) { this.fadeIn('slow'); } else { this.fadeOut('slow'); } }; $(document).ready(function() { $('p').hide(); var hash = {'one': 'a', 'two': 'b', 'three': 'c'} $('a').hover(function() { $(this).fadeOut('slow')
Making a Success/Error message appear after sent mail
So I have spent the past week (about 10 hours in total) looking for a way to make a jQuery message appear without a reload after someone send me a message using my contact me form. Yet all the tutorials I have read (20-30) have included a success/error message but also have many other messages. Since im a beginer to jQuery I have no idea which is which and how to cut out what I wan't. So I was wondering if somone hear could tell me how I could accomplish this using jquery-1.2.6.min.js Here is the
[jQuery] Replacing entire page.
Hello, I am trying to replace the entire page when the user selects a different option in a combo box. The code I have works for the first iteration. However, It fails everytime there after. I went through firebug and it appears after the first refresh it never triggers the ready() method. Any help is appreciated. My Code is, <script type="text/javascript"> $(document).ready(function() { $("#id_company").change(function () { var data = {}; data.company = $(this).val(); $.get("/ajax/search/",
JQuery Ajax XML Return Values
I am trying to create a function where I can return some values from an XML file with the $Ajax call. The XML: located in the root of my webb application /languagemap.xml 1. <?xml version="1.0" encoding="utf-8"?> 2. <Mappings> 3. <Mapping DisplayName="Chinese" ShortName="zh" Code="4"/> 4. <Mapping DisplayName="Dutch" ShortName="nl" Code="19"/> 5. <Mapping DisplayName="English" ShortName="en" Code="9"/> 6. <Mapping DisplayName="Finnish" ShortName="fi" Code="11"/> 7. <Mapping DisplayName="French" ShortName="fr"
Dynamic variables
Hi, I am using this slickbox code, but wwant to use it for multiple divs with different variables. <p><a href="#" id="slick-toggle">Toggle the box</a></p> <div id="slickbox">This is the box that will be shown and hidden and toggled at your whim. :)</div> So I will have slickbox_1, slickbox_2, etc. How can I modify the script below to accept all these different div names? Here is the javascript: $(document).ready(function() { $('#slickbox').hide(); // toggles the slickbox on clicking the noted link
[jQuery] Problem with for loop and click funtion.
Hi, I wrote simple click function to load big images from thumbs and it works properly. I put this into for loop because i need to make few galleries on one page. The point is to connect right thumbnails set with right .big-img div. Here is the code http://paste.pocoo.org/show/138171/. Maybe someone can help because i am a "fresher" with jquery.
[jQuery] update input value onblur
I'm learning JQuery and building a page with a table. The table contains multiple tr's andd the tr's contains multiple td's. The td's contain a input element. The first td of a row contains a "select element" and the others a "text element". Now I want to fire a AJAX when the onblur event is fired on the second input text element to fill the fourth(4) element. When its fire i want a loading span is visible for the user. the following works for me when i have 2 input element with unique id's. <script
[jQuery] New iPhone-style button plug-in released...
We've just released another jQuery plug-in which emulates the iPhone-style button used to toggle settings on/off. The plug-in works with both checkbox and radio button groups and we've worked hard to make this a complete plug-in. While there are several similar plug-ins, we couldn't find one that actually had all the features we needed--which is why we built this version.<div> </div><div><a href="http://www.givainc.com/labs/ibutton_jquery_plugin.htm">http://www.givainc.com/labs/ibutton_jquery_plugin.htm</a></div><div>
count deepness
Hello, I have created a menu with ul en li elements, like this: <ul> <li>a</li> <li>a</li> <li>a <ul> <li>a</li> <li>a</li> <li>a</li> </ul> </li> <li>a</li> </ul> now i want to calculate how far i can go in this submenu, in this example the farest i can get is 2. Becouse i start in the menu wich is number 1 and then i can go 1 submenu deeper, so thats 2. Now my question how can i calculate this using jquery. Thanks in any advance.
[jQuery] Using jQuery to see if CSS is disabled.
Hello All, I'm trying to code a site using progressive enhancement methods. It's built upon standards-compliant CSS and HTML and JS. I'm using jQuery on the site to animate some elements on hover etc. Now, when CSS and JS is disabled, it's all good. But, If CSS is disabled and JS is still enabled, the js still manipulates the elements and it's not what I want. I was wondering if anybody knew anything about this. I can't seem to find anything about this...
[jQuery] getJSON
Hi Guys, I m trying my hand on getJSON I am able to see response through fiddler Please let me know what i am missing This is my function $(document).ready(function() { $.getJSON("http://127.0.0.1:8001/category/1? format=json&callback=?", function(json) { alert(json.category); alert("test"); }); }); Response i am receiving is:- "{\"Category\" : [{\"CategoryId\" : \"1\",\"Description\" : \"General \",\"Category\" : \"General\",\"Name\" : \"nipun\",\"Path\" : \"d:\/ testing\/nipun.txt\",\"Title\" :
[jQuery] Support for Mobile Browsers coming?
Hi, Just wondering if jQuery has plans to support mobile browsers (iPhone, BB, G1, Palm Pre, WindowsMobile 6.5 in particular). This page (http:// docs.jquery.com/Browser_Compatibility) only lists PC browsers. Thanks! Will
[jQuery] How to Reading tooltip Contents from .txt or .js file
Hi, is it possible to get the contents from .js or .txt file. I wish to store all the tool tip content in a txt or js file, pass the parameter to get the msg depending upon the parameter?? is it possible?? if yes how can i do it?
[jQuery] Problems with ajax and encoding
Hi, I´m using ajax(xml) to load one piece of php code, a template code stored on the database(Latin1). I´m having problems with accentuation when this piece of php code has accentuation. I´ve tryed almost everything, but i had no sucess at all. My code its like that: js: $.ajax({ url: '/admin/sistema/publicidade/req/getFormatos', type: 'post', dataType: 'xml', data: dados, success: function(data){ //process data }) }); php code: header("Content-Type: text/xml;charset=ISO-8859-1", true); $xml = "<?xml
Jquery Lightbox not firing with Mod Rewrite URLS
I have a site that is very much all mod rewrite URL's. I cannot get my jquery stuff to fire because of the Mod Rewrites. Is there a way around this? If I create a page without mod rewrites all the jquery works fine. Any suggestions are greatly appreciated.
[jQuery] Autocomplete + JSON + 's.toLowerCase is not a function': FIXED!
A little bug I ran into, and the fix for it that I found, in case anyone else has similar issues: I'm using the jQuery Autocomplete plugin, with a JSON data source. This is done by adding a custom parse method to the initialization, as such: input.autocomplete(ac_url, { limit: 10, dataType: 'json', parse: function(data) { var parsed = []; for (var i in data) { row = { data: data[i][1]+'|'+data[i][0], value: data[i][0], result: data[i][1] }; parsed[parsed.length] = row; } return parsed; }, formatItem:
[jQuery] Form Serialize - Not replace space with plus
I'm using $("form").serialize(), and then doing an AJAX request. JQuery automatically replaces spaces with the + character. How can I keep my spaces? (I couple replace the + character with a space on the server side, but I want the users to be able to enter the + character when they submit forms.)
[jQuery] JQuery append problem in IE7/8 but not in other browsers!
I have what I believe is quite a simple piece of code that works in every other browser except IE: $.post("/here", { this: this_value },function(data){ $("#" + this_ID).append(data); }, "text"); It simply sends a post to the server and appends the result to a div with the this_ID. The post is definitely received and can be displayed using an alert(), but I cannot seem to get the return to display on the page (the returned data is in the form of html). I have also tried .html() and .after() but neither
[jQuery] jQuery UI open URL in new window
All, I am very new to this! I have a menu and want to open all URLs in a new window. Could someone help me with the code and where to place it in the js file Thanks
[jQuery] Hidden div height width
Hi all Can any one tell me is it possible to get the height and width of a hidden div. I have to apply animation to a hidden div. But is don't know how to do this. Thanks Rupak
RE: Getting a data from a method in ASP.net C#
So I have a method in a a C3 ASP.net project with the following signature public string[] GetProduct(); { - - - - return data.ToArray(); } How can I get the data value from this using jquery. Please help!! SA
[jQuery] [validate] plugin: combine features from multiple demos
i posted this to the plugin group, but it appears to be a dead forum -- last post was february. i'm trying to combine features of these 2 demos: http://jquery.bassistance.de/validate/demo/milk/ http://jquery.bassistance.de/validate/demo/multipart/ specifically, i want the ability to use custom error messages and to declare conditions in the page head, as in the 1st demo, as well as to use the accordion feature of the 2nd. if i use the code from the milk demo in the head, e.g., $(document).ready(function()
[jQuery] Looking for plugin to refresh images randomly
Hello, I am looking for some jquery plugin that would replicate what is done on this page http://www.lorigrahamdesign.com/index.php Basically there are 5 images which keep changing (fade in/out) randomly and when clicked they take the user to a new page. I remember seeing lots of jquery plugins regarding this but am not coming across them now. I would appreciate if someone can guide me in this regard?
[jQuery] Reverse slideUp/slideDown
When using slideDown, you will see the content. Using slideUp will hide the content. Now I want to use slideUp to view the content, so it will start from nothing and slide to an object from bottom to top. Is there a good way to do this, or should I fox it with animate and scrollTop?
[jQuery] Has anyone now how to simplify the following expression by avoiding using attr("id")
Has anyone now how to simplify the following expression by avoiding using attr("id") alert($("#"+$(obj).attr("id")+"~p:last").attr("id")); I need this because not every image could have an id. <script language="javascript" type="text/javascript"> function ExpandCollapseOnLeftPanel(obj) { if ($(obj).attr("src") == "/Content/Images/arrow_bot.gif") { // expand $(obj).attr("src", "/Content/Images/arrow_side.gif"); $("#" + $(obj).attr("id") + "~p:last").css("display", "block"); } else //collapse { $(obj).attr("src",
[jQuery] Superfish Menu
Hello, I'm trying to use de Superfish menu in a site i'm developing. I would like to change the jquery animation but i really don't know how. In the menu options there is a line like this: "animation : {opacity:'show'}". But i can't make it work if i change the word 'opacity'. Thakns in advance and sorry for my bad enshlish :( Diego
[jQuery] Superfish - Not Rendering on Postback
Hello, I am using Superfish for the menu system on a 3.5 asp.net webform. Everything is working good except during postbacks. For instance we use the selected ID, during the postback event of a dropdown list to filter data for another list. The menu is rendering fine until the postback event. From what I can tell the menu is not rendering at all and none of the superfish events seem to be firing. In the master page for the site I've got the following code to execute the menu. <script type="text/javascript">
[jQuery] Test message - Please disregard
Testing out an issue on the list. Please disregard. Rey jQuery Team
[jQuery] Adding/Removing and Resizing jScrollPane - Reinitializing jScrollPane
I am building a little widget which is using jScrollPane to add a scrollbar for where the data doesn't fit inside the alloted space. When the user clicks on the data, I hide what they had, and show the clicked data in a different format. Sometimes the data needs a scrollbar, sometimes not, and sometimes the ammount of scrolling needs to be resized. I've taken a look at how Kevin Luck reinitializes the jScrollPane with ajax data (mine is not loaded via ajax, just a different display of the data),
[jQuery] error when uploading files
I get an error "Error: Form elements must not be named "submit"." when i have a form with the ability to upload files. If a file is selected for upload i get the error, and not when there is no file for upload. why is that? what difference does it make if there is a submit button?
[jQuery] Port Prototype Code to jQuery?
Hi All, I want to refactor (port) the following PrototypeJS code to jQuery. I'm in the process of learning jQuery and currently stuck with porting this piece of code... Any idea's? [code] var total = 0; // For each fieldpair that has a child with a checked input // we get the sibling with a text input and add that value // to the total. $$(".fieldpair").each(function(fieldpair) { if (fieldpair.down("input:checked")) { var input = fieldpair.down('input:text'); total += parseInt(input.value); } });
jquery ie8 help
hey, im making a site using jquery cycle for some images to fade in and out this works fine in firefox, safari etc.. but in ie8 while the image fades in it has a black border or artifacts around it then they go away and they return on the fade out, i have tried everything i have researched on google and nothing has worked you can check it out at designpilotonline DOT com /newsite any help would be greatly appreciated
IE7 Question
In IE7 the first alert shows all of the data. The second alert shows up empty. function handleLoading(data) { alert(data); var $content = $("<div></div>").html(data); alert($content.html()); ... } This works fine in FF3.5 & Chrome. Any guess what's happening and how to fix it? Here's more of the code in case that helps... function handleLoading(data) { alert(data); var $content = $("<div></div>").html(data); alert($content.html()); var $visualBadge
JQERY newbie ?
I'm using the following code to override a link's onClick event. I want to load the link's href into my div. 1. function handleLoading(data) { 2. var $content = $("<div></div>").html(data); 3. var $visualBadge = $("#visualBadge"); 4. 5. $visualBadge.children("div").replaceWith($content); 6. $visualBadge.find("a").click(handleClick); 7. } 8. 9. function handleClick(evt) { 10. var link = this; 11.
[jQuery] How to unbind data?
Hi everyone I'm trying to write a function that will pass through the id of a clicked element, and then use that id for spellchecking the word that's been clicked on. However, although this seems to work, when i click on another word, it returns the previous corrected word rather than the new one - as if it's storing the same data all the time. I was advised to unbind the event but that doesn't seem to work... Here is my code - but let me quickly explain. First off, there is a div with text in which
Using a checkbox control in Flexigrid
Hi guys, I want to display my grid entries with a checkbox as the left-most column and be able to select one, many or all entries. Something like gmail does. Does anyone know how I can achieve this? thanks in advance Tony
[solved]How to do terms with checkbox?
Hi There is a <input name="checkbox" type="checkbox" value="checkbox" /> and <asp:imagebutton id="buttonRegister" /> in an aspx form. I added the Ajax script. If I uncheck the checkbox, it would pop up. However, if I checked it, it still pop up. What's wrong with the code? $(document).ready(function() { $("#ctl00_cphContent_buttonRegister").click(function(e){ if(!$("#checkbox").is(':checked')) { alert("you did not check the agree to terms..."); e.preventDefault();
[jQuery] slide one div out left while sliding one in right
I have a container div with two inner divs. I have one inner div visible taking up 100% of the visible area and another hidden div. I want the visible div to slide to the left while simultaneously sliding the other div in from the right. This works fine except that while the right div is sliding in, it appears below the left div. How can this be done? Here is the code: <script type="text/javascript" src="js/jQuery/jquery.js"></script> <script type="text/javascript" src="js/jQuery/effects.core.js"></
Next Page