[jQuery] Delay for $get.Script() callback function
The documentation for $.getScript() function explicit says: *If you load functions via getScript, make sure to call them after a delay.* [1] It is suppose that callback functions are always called after a request. So, it is suppose too that this requeriment is valid for $.get(), $.post, $.getJSON etc? But documentation doesn't mention the requeriment for other kinds of requests. Or, am I missing something? Can someone explain me the needs for this requirement? What does it means exactly? [1] http://docs.jquery.com/Ajax/jQuery.getScript#urlcallback
[jQuery] Overrridden $.ajaxSetup() options
I have had setup the following: $.ajaxSetup({ dataType: 'xml', error: function(xhr) { $('#error_msg').html(' Error ' + xhr.status + ' - ' + xhr.statusText + '') }) Now I want make one call to a HTML document. So I state: $.get('uzudo', function(data) { $('#insert_here').html(data) }, 'html' ); it is suppose that the data type:html passed to the $.get() function overriddes the default data type: xml. This isn't working! I am getting a 200 Ok status on error message and
[jQuery] Why won't these values work for an ajax function?
<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"> <head> <meta http-equiv=Content-Type content="text/html; charset=us-ascii"> <meta name=Generator content="Microsoft Word 12 (filtered medium)"> <style> <!-- /* Font Definitions */ @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4;} @font-face
[jQuery] unload garbage collection 1.3.2 patch
ISSUE: Garbage cleanup is not assigned to an anonymous function. Sometimes unonload is used by other logic that may need jQuery to perform certain tasks. The ability to unbind/bind the garbage collection routine is handy to bump execution order. SUGGESTED SOLUTION: Assign garbage collection routine to a named closure. PATCH FILE: 3106,3111c3106,3111 < jQuery( window ).bind( 'unload', function(){ < for ( var id in jQuery.cache ) < // Skip the window < if ( id != 1 && jQuery.cache[
Lightbox after timeout?
When users of my site reach a certain point of inactivity, I need a lightbox to show the content of an html page, Any suggestions on the best plugin to do this with? All I can find is lightboxes that work with href tags. I need the lightbox to show after timeout.
[jQuery] Find if a checkbox is ticked or not by user
Hi, I am having a simple issue but can't get it work. I've searched other similar posts but still no good luck. I've got a checkbox on my form not checked by default and it's up to the user to select it. <input id="chk01" name="chk01" type="checkbox"> I then want to detect if user has selected it or not in jQuery (triggered by some event) I've tried to use $("#chk01").attr("checked") which always gives me "undefined" value no matter if it is checked or not. Also tried $("#chk01").is(':checked') which
[jQuery] magical setTimeout in IE
Hi, I'm not an expert in this, I've checked list archive and I didn't find nothing similar. If You know why this is happening please let me know. HTML is something like that: <form name="test" method="get" action="something"> <input name="handler" id="browser" type="radio" value="browser" checked="checked" class="defaultHandler"/> <input name="handler" id="browser2" type="radio" value="browser2" /
[jQuery] access to tablesorterPager's internel functions?
I am using the tablesorter and tablesorterPager plugin, and I would like the table to go to the first page each time the user performs a sort on a column. To do this I added a click event to the headers, and then I wanted to invoke the moveToFirstPage function in the tablesorterPager plugin, but I'm not sure how to do this. Is it possible? Thanks
[jQuery] Attaching tooltip to Ajax Load Event
I have a script that loads in data via an .load call: function listLoad() { $("#listoflists").load("/cart/admin/files/mailinglist.html", {nodetails: "yes",action:"loadlists"}); } This script is called everytime something else is added, again via a .load event: $("#do_create_list").click(function(){ $("#create_list_results").load("/cart/admin/files/mailinglist.html", {nodetails:"yes",listname:$('.listname').val (),action:"create_list"},setTimeout(listLoad(),400)); }); The issue that I am having,
[jQuery] Jquery makes two ajax requests in one!!
I have a strange problem. I have to do an ajax request after a select box changes (change event) so i have the following code: $('#comprensori_id').change(function() { var comprensorio_id = $(this).val(); $.ajax({ type: "GET", url: "", data: "comprensorio_id=" + comprensorio_id, success: function(data, msg){ $('#comuni_id').empty(); $('#comuni_id').append(data);
[jQuery] treeview
Hi, I would like to know if it is possible to link treeview links to anchor tags rather than to a whole html page. Any help will be much appreciated. Thanks.
[jQuery] jQuery tab hiding content
My jQuery tabs are not always showing content when the tab panels are clicked. I have 5 tabs, 3 of which are produced via ajax calls. When I click on 2 of the 3 dynamically produced data panels, their content is not shown. However, when I view their source in the web browser I can see the desired html. Interestingly, when I add static code to the dynamic panel, the panel then shows all the content. For example: <div id="list" class="ui-tabs-panel"> <!-- List Tab --> <h4>Listing:</h4> // when I remove
[jQuery] [validate] Either this field OR this field OR both
Using the validate plugin, I need to validate if either one field OR another has been filled in. It's fine if both fields have been filled in as well. Can anyone think of a way to make that happen? Thanks!
[jQuery] Problem with links loading in current panel
Well, Links in my panel should be loaded inside the current panel I must be doing something terribly wrong, but I really can't find what that is. I'm not really used to work with both js and ajax, so it could be something easy (sure hope so). This code I've put in the head of my page: <script type="text/javascript"> $(function() { $("#tabs").tabs(); }); $('#tabs').tabs({ load: function(event, ui) { $('a', ui.panel).click(function() { $(ui.panel).load(this.href); return false; }); } }); </script>
[jQuery] How can I freeze the title row in a table?
I have a table with lots of rows, and when I scroll down, I can't see the row with the column titles. How can I freeze that row in place so I can still see it as I scroll down?
easy toolpic ..... not work with IE... :-(
Hi! I use this easy toolpic script: http://cssglobe.com/lab/tooltip/01/ I have changed so: (for image area shape) this.tooltip = function(){ /* CONFIG */ xOffset = 10; yOffset = 20; // these 2 variable determine popup's distance from the cursor // you might want to adjust to get the right result /* END CONFIG */ $("area.tooltip").hover(function(e){ this.t = this.title; this.title = ""; $("body").append("<p id='tooltip'>"+ this.t +"</p>"); $("#tooltip") .css("top",(e.pageY - xOffset) + "px") .css("left",(e.pageX
[jQuery] Newbie help on Radio select
Hi all, I'm new to Jquery and I have a problem I'd like to ask. I've followed a code snippet online to add a background color to a table column, but my problem is that when the 2nd row is selected, the 1st row disappears. How can I make each row remain on the td I've selected? Here's the code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/ TR/html4/strict.dtd"><html> <head> <title></title> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/ jquery.min.js"
[jQuery] prepend() and add events to prepended elements
Hi, I have such a piece of code: $('body').prepend('<div id="lightbox"><div class="lb-display"><div class="lb-bg"><div class="header no-bg sid"><h2 class="header">Embed Code</h2><a href="#" class="popupExit">exit</a></div></div></div></ div>'); Then I would like to add a click event to a.popupExit but it doesn't work correctly. I'm doing it in this way: $('a.popupExit').click(function() { $('#lightbox').css("display", "none"); return false; }); Anyone can give me some clue how to do it right?
Dynamic click event handlers
I'm working on a site that has a custom "coda slider" type navigation. Basically all "pages" are on a horizontal line and there's a frame so you only see one at a time. I have "< Prev" and "Next >" buttons on the bottom and when you click them, they slide the horiz line over to the right spot. So the Prev/Next buttons have dynamic click handlers. My horiz frames scroll very smoothly in Chrome and IE7 (ha) but they're grindingly messed up in Firefox. By grindingly messed up, I mean they barely show
[jQuery] JQuery, JqGrid, and Ajax
Hello: I am trying to develop a similar functionality as here:http:// koshersavings.ca/SelectItems.php When the user to clicks an row item, I want items to be loaded based on the selection, dynamically. I am trying to do the same, but using jqgrid, and ajax. The current code is here: (also note below) http://pssnet.com/~devone/ajqtable/summary35.html Basically, when the user double clicks it loads a corresponding table. But, when they select another, it will not reloaded. Any help appreciated. Thanks.
[jQuery] How to tell apart focus event
Hi, <form> Name: <input type="text" id="my_name" name="my_name"> </form> Is it possible to tell apart focus event? jQuery("#my_name").focus(function (evt) { if( ??? ){ //execute this if focus was triggered by user clicking on the text field } else { //execute this if focus was triggered by method call like this //document.getElementById("my_name").focus(); } });
[jQuery] jQuery UI tabs: show struts action response in the current tab panel and switch to another tab
Hi, I am trying to use UI tabs for create tabs for something like this: Tab1:Tab2 Here is the problems I came across: 1. I want to show the struts action reponse in the current tab (let's say Tab1). However, the response is shown as a full page in the browser. can someone post sample jQuery code on how to make this happen? 2. If the struts action throws an exception and the struts action form validation fails, I want the response (error page/form validation errors, etc..) to be shown in the current
[jQuery] Learning about functions and methods (I am confused)
Hy (function($){ $.myPlugin = function(){ holla: function(){ alert('holla'); } } $.myPlugin.hello = function(){ alert('hello von Plugin'); } })(jQuery); // Works finde: $.myPlugin.hello(); // It does not work. Why? $.myPlugin.holla(); Is there a posibility to write a method in: ... snip $.myPlugin = function(){ // Write methode here } } ...snip So that $.myPlugin.holla(); will work? Thanks!
jQuery within Javascript?
This might not be possible at all - I've tried the code and it's not working so I'm guessing it probably isn't possible, but it could also be I've done something wrong! This is the code i have that works: $(document).ready(function(){ $("#bgChangerAnchor1").click(function () { $("#mainContainer").css("background","url(backgrounds/bg_1.jpg)"); }); $("#bgChangerAnchor2").click(function () { $("#mainContainer").css("background","url(backgrounds/bg_2.jpg)"); }); $("#bgChangerAnchor3").click(function
[jQuery] jQuery within Javascript?
This might not be possible at all - I've tried the code and it's not working so I'm guessing it probably isn't possible, but it could also be I've done something wrong! This is the code i have that works: [code] $(document).ready(function(){ $("#bgChangerAnchor1").click(function () { $("#mainContainer").css("background","url(backgrounds/bg_1.jpg)"); }); $("#bgChangerAnchor2").click(function () { $("#mainContainer").css("background","url(backgrounds/bg_2.jpg)"); }); $("#bgChangerAnchor3").click(function
[jQuery] [validate] Dotnetnuke and form validation
Hi, I'm using dotnetnuke cms in a current development and I'd really to use validate for my forms. I haven't actually tried it but I know that the entire page in DNN is rendered as a form and that 'forms' within the page are psuedo forms - i.e. a group of inputs normally wrapped in a DIV and with some psuedo submit code on the accept button. If I point validate at the DIV wrapping my 'form' fields will it work (or is it looking for the form element). Can I intercept the pseudo submit button with
[jQuery] [tooltip] Way to make the tooltip plugin accessible to browsers with no mouseover?
The tooltip plugin is slick, but there's one vital thing it appears to be missing: the ability to click instead of hovering. Why do I want that? Some browsers, like the iPhone, don't have the mouseover event at all. The tooltips are completely unavailable to those browsers. Is there a hack to support this?
[jQuery] Problem Containts for select words
I am using the function to search for words in containts TR. I have three words well (Sunday and Monday, Sunday and Monday and Sunday) Only is selected and the second Saturday and Sunday and Monday. I was also selected to Sunday but could not. Thanks to All Im using $('table#horario tbody tr td:nth-child(' + n + '):contains(' + textoCelula + ')').parents('tr').addClass('destacar'); Containts handle the months
[jQuery] Superfish stacked sub menus
Has anyone any thoughts on how to modify Superfish so that submenus show in a stack rather than to the right of the parent menu? Example: http://www.katalysis.net/assets/images/stacked-superfish.png
[jQuery] jQuery UI Autocomplete - Removing items / detecting all values from multiselect
Hello, Is there a way to always know what values are selected inside of a jquery ui autocomplete widget? I know there is a "result" event that fires when you select a value, but what about when you remove a value? Thanks, Rob
[SOLVED]Find the correct label for input field
I want to make something that when I click a input field (so the input field has 'focus') , the corresponding label becomes bold. I first wrote this: Jquery: $(document).ready(function(){ $("input").focus(function(){ var selectname = this.name; $("input[name="+selectname+"]").prev().addClass("bold"); }); }); HTML <label for="name">Name:</label> <input name="Name" type="text"/> <label for="email">E-mail:</label> <input name="Email" type="text"/> ... this works perfect, when
JQuery UI Resizeable and DIV with overflow: auto
Hi all, I tried to use the Jquery UI Resizable with a DIV that is styled with overflow:auto and it appears that I can only resize when I see the upper part of the DIV (which was present when initializing). If I scroll down it is impossible. I am using JQuery Version 1.2.6 and JQuery UI 1.5.3. Did anyone come across this issue or has hint how to solve it? Thanks in advance. Best regards dr_d00m
[jQuery] Using Thickbox 3 to play a Flash Intro?...
Does anyone know if I can have the Thickbox Plugin Pop up when someone navigates to the page and play a small Flash intro
Get button event
Hi, I'm very new to JQuery and never worked with it before but a friend of my gave me a hint to solve my problem with JQuery, so here I am. The thing I want to do is the following: I have a webpage in PHP that contains a button that will open a popup window. In that popup window I load the content of an other site with an iFrame. On that site is a form with some questions (a test), radio buttons and a submit button. When the user clicks on the submit button it will load another page (which is not
[jQuery] addClass on ahref link on the fly
Hi I've got a list of image with links and need to add a class on the fly on the ahref link. The output is like that <ul> <li> http://www.site.com/ http://www.imageurl.com/img.png </li> <li> http://www.site.com/ http://www.imageurl.com/img.png </li> <li> http://www.site.com/ http://www.imageurl.com/img.png </li></ul> and I want this (class="tooltip2") : <ul> <li> http://www.site.com/ http://www.imageurl.com/img.png </li> <li> http://www.site.com/ http://www.imageurl.com/img.png </li> <li> http://www.site.com/
[jQuery] UI Tabs and Events
Woo, first post! ^___^ Hello everyone, I've been using jQuery UI Tabs for a mini staff discussion forum/blog at work, and things have been going really well so far, up until I came across this stumbling block yesterday. The tabs are used to dynamically load different categories of posts into the central content area. Each post has a comment form (created on the fly when the user clicks the "comment" link) and a comments list (populated dynamically using json when the user clicks the "read comments"
Hiding all DIVs >= x
Hi, I have a page were you can place divs with the class "teaser". To get the amount of teasers I use $("div.teaser").length. Now I want to add a function to hide all divs which have a higher number than 10. So, from 0-10.show divs, from 11-x hide them. Any idea who to write something like this? thx T.C.
[jQuery] [autocomplete] how to handle special characters?
Hi there, while using autocomplete, I've noticed that characters & and ' get escaped as & and ' Example, autocomplete displays Barbara’s Straight Son but when I choose this the field shows Barbara's Straight Son Any ideas how I can avoid this? Thank you for your time!
[jQuery] [validate]
Im using asp.net and we use linkbuttons to submit our forms. The linkbuttons get rendered as hyperlinks with a javascript function firing a postback. is there anyway i can get the validation plugin to fire on click of the hyperlink and then fire the postback if valid.
[jQuery] adding columns to table row
Hi, i'm trying to make a really basic 'tab bar' for a project. i looked at the stuff out there (ui tabs, and flytabs) but wanted something simpler. i basically need to create a bunch of horizontal cells that can be added to, and don't need any div-switching or anything for the content (just links). i decided a single table with a row would work, and tried to figure out how to add new columns/cells to the table. i tried: <script> function create_table() { $('#test').append('<table border=\'1\'><tr><td
Next Page