[jQuery] Help for a noob: AJAX, Autocompletes and JSON
Hi, Im new to ajax and serverside scripting (forgive me for the rediculous questions i will ask i'm only 15). I want to create a page where there is an auto-comples plugin that will pull the values from a JSON database(?) Once the user clicks on the value it will populate a container div with other values from the JSON database. So for example: I search for a name and when i click that name it will populate a div with, for example : an email adress, phone number etc. I really need to have a step
[jQuery] Attaching a jQuery event to a dropdown in an ASP.net Repeater?
Hi, I've got an ASP.net repeater which has an unknown number of rows, that I'm passing as a variable into the client-side code. Each repeater item has two dropdowns in it, one of which I need to attach to a jQuery event to create a cascading dropdown. I've put the change(function() { into a for..next loop, along with the target control. It's not pretty, but it seems logical. Problem I have is whenever the function is called, the ID of the target control is the max value of the loop + 1. Why is my
[jQuery] Get following rows in a table until id not match certain pattern
Hi, I have a situation where a user clicks on something in a particular table row which should cause all following rows in that table that have a particular format of id to toggle visibility.. so for example <tr id="top11_21"><td><a href="#" id="top11_21click">click here</a></ td>...rest of row data</td></tr> <tr id="act11_21_1"><td>...</td></tr> <tr id="act11_21_2"><td>...</td></tr> ................ <tr id="act11_21_30"><td>...</td></tr> <tr id="top11_22"><td><a href="#" id="top11_22click">click
How to center a popup at the end of page (scrolled down max)
Hi guy! Before we start, I'll mention that I followed this tutorial : http://yensdesign.com/2008/09/how-to-cr ... ng-jquery/ So if you want to know my code, this is what I'm using! The problem is with this code... the popup does not pop at the end of a page where I call it. For example, I have a page with a height of... lets say 4000px. Yes, ok my browser have a 800px height... but my page don't and I have a scroll bar to go at the end. I just don't know how to code so that the popup get centered
[jQuery] jQuery, JSON and AJAX (help please)
Hi, Im new to ajax and serverside scripting (forgive me for the rediculous questions i will ask i'm only 15). I want to create a page where there is an auto-comples plugin that will pull the values from a JSON database(?) Once the user clicks on the value it will populate a container div with other values from the JSON database. So for example: I search for a name and when i click that name it will populate a div with, for example : an email adress, phone number etc. I really need to have a step
[jQuery] Binding Events on a Click
Hello, as a complete beginner in the world of jQuery I'm struggling both with the concept and coding of what I am trying to achieve and would appreciate any help you guys can offer :-) I'd like to have a hyperlink on a page, that when clicked reveals some hidden text below the hyperlink AND at the same time opens a new browser window to a specified URL (which would have been declared in the HTML code NOT the jQuery bind code). There will be several of these 'Click here to reveal password and open
jQuery: deactive site while loading
Hello from Germany, I have following problem: If you open a dialog in jquery, the website will be "deacitve" and the dialog would show. I want, that the website will be "deactive", but there shouldn't show any dialogs. I'm looking forward to your answers... P.S.: I hope you understand what I mean, my English is not so good
[jQuery] BUG: fadeIn callback gives error!
hey =) here is my code function fadeInFeaturedGame() { $("#featuredgame").fadeIn("slow", setTimeout("fadeOutFeaturedGame()", 5000)); } function fadeOutFeaturedGame() { $("#featuredgame").fadeOut("slow", fadeInFeaturedTvShow()); } function fadeInFeaturedTvShow() { $("#featuredtvshow").fadeIn("slow", setTimeout("fadeOutFeaturedTvShow ()", 5000)); } function fadeOutFeaturedTvShow() { $("#featuredtvshow").fadeOut("slow", fadeInFeaturedMovie()); } function fadeInFeaturedMovie() { $("#featuredmovie").fadeIn("slow",
[jQuery] how to get the response header of an ajax request
Hello I want to access the headers of pages I load through ajax. However I don't know how to do this with jQuery First of all, I'm only interested in the headers, not its content, so $('#someID').load("somefile.html") ; is not really what I want. Is there a way I can get the XMLHttpRequest object so I can do xmlDoc.getAllResponseHeaders() Thnx in advance
[jQuery] ASP.NET Placeholder, JQuery, and live() event
I have a placeholder that houses controls that starts with it's VISIBILITY set to FALSE. This makes the controls non-existant to JQuery initially. So I found the LIVE() event, and have been trying to get it to work alongside autotab (http://www.lousyllama.com/sandbox/ jquery-autotab) with no luck. Any suggestions? BTW, the commented portions work so long as the controls are loaded with the page. $(document).ready(function() { $('#txtEmployee').live('load', function(){ $(this).autotab({ target:'txtJob',
[jQuery] including JQuery JS changes font size in table cells
Greetings, I have a strange situation. I've just added an include of the JQuery JavaScript file and the font size of text in some table cells has increased. I've also noticed a text field displaying shorter (less height) but with the same font size, so all you see it the tops of the characters. The page doesn't have the cleanest CSS. The page is built dynamically, so it would be tricky to try to put together a simple test case. However, I'm surprised that including a JS file and not using anything
[jQuery] Design pattern for animate()
I have a small hud-syle control I've built for a project. I'm using the following code to activate a collapse button on the hud, and to resize the hud so that it can accommodate some wide data. $('li.hud-left-tab').click(function() { // First, if the hud is collapsed, slide it down $("#data").slideDown(20); // Next, if it's been expanded, shrink it hud.animate({"width" : hudWidth_init}, 90); hudChild.css({"width": hudWidth_init}); $("#map-filter-popdown-shadow").hide();
.click doesn't seem to respond to elements added with jQuery
I'm working on creating a little suggestion/autocomplete code for form fields. Here is the code I currently have written: $(document).ready(function() { $("#city").keyup(function() { $.getJSON("http://iburris.ath.cx/autosuggest/city/"+$("#city").val(), function(data) { if (data == "") { $("#results").css("display", "none"); } else { results = "<ul>"; $.each(data, function(i, item) { results += "<li class=\"autosuggest_results_item\"
[jQuery] (validate) Display default validation errors, not title
Is there a way of telling the validation plug-in to use it's default error messages when the title on the control is set? The default validation error messages are good for most of my cases so I'd rather not have to explicitly set the messages for each and every one of them. For example, if I attach a "required" validation rule to a textbox and set its title to something, I don't want that title to appear as the error message when they leave the field blank and I'd rather not have to explicitly set
Calling a function outside of .js file, can it be done?
In my index file I have global.js sourced into the head, which contains the following function. function gotoShop() { currentPage = "shop"; checkMenu(); $('div#holder').scrollTo({top:'0px', left:'2860px'}, scrollSpeed); return false; } I'm trying to call this function from the index file by using (with script tags) : $(document).ready(function(){ gotoShop(); }); But it doesn't work, the function works fine when called inside the global.js file, so basically how can
[jQuery] Jquery/Javascript Developer - 3 month+ contract - To $50/hr - Custom Jquery Exp
<DIV> <DIV style="FONT-SIZE: 10pt; COLOR: #000000; FONT-FAMILY: Geneva, Arial, Sans-serif">We are looking for an advanced Jquery/web developer. Specifically we need someone who has created jquery plugins/custom jquery. </DIV> <DIV style="FONT-SIZE: 10pt; COLOR: #000000; FONT-FAMILY: Geneva, Arial, Sans-serif"> </DIV> <DIV style="FONT-SIZE: 10pt; COLOR: #000000; FONT-FAMILY: Geneva, Arial, Sans-serif">This will be a 3 month+ contract position. It will be Monday - Friday 9 am - 5 PM. </DIV> <DIV style="FONT-SIZE:
selecting only the element under the cursor
Hi, I'm trying hard to select only the element under the mouse cursor, but for example, when I do this: $(document).ready(function() { $("div").hover( function() { $(this).addClass("setBorder"); }, function() { $(this).removeClass("setBorder"); }); }); it sets the border for each div element. so if i'm hovering an inner div, it also influences the outer div: <div><div></div></div> I only want the div right under the cursor. Is there a way to send the element's id to the function above? something
[jQuery] if button clicked then do this else do that
Hello, I am trying to do something like this. if a button is clicked call one function $('.saveButton').click(function(){ ////call one function }); else call another function. But I don't have any idea how to implement if else in a clicked event. Can any one help me?
[jQuery] jQuery UI Tabs and Ajax
Hi together, I give the question in UI Group but nobody answer there: I'm really new to jQuery and UI. What I'm trying is to build a view in CakePHP with the jQuery UI Tabs. The first part, integration the informations from my Cake controller in Tab 1 to 4 and is working. In Tab 5 and Tab 6 I want to show informations which are in relation to the dataset of Tab1 to Tab4. I.e. I'm calling a Post-View. In Tab 5 I want to show the attachements (1 : n relation). So I do the following: <div id="tabs">
[jQuery] Accordion with dynamic loading data
Hello I am needing an accordion with dynamic data loading on each tier. Does anyone have a good example of this. I thought I would ask before I took the dive. Thanks, TS
[jQuery] :contains selector not working in IE
I have the following code working in FF but not IE: function processSearchResult(xData, status){ var resultHTML = ""; if (status == "success") { $(xData.responseXML).find("QueryResult").each(function() { var x = $("<xml>" + $(this).text() + "</xml>"); x.find("Document").each(function(){ var title = $("Properties>Property>Name:contains('TITLE')", $ (this)).next().next().text(); var url = $("Action>LinkUrl", $(this)).text(); var title
.unique explanation?
$(document).ready(function () { $('<div></div>').appendTo('#newsHoldingPanel').load('news.asp?newsSectionid=8&NoOfNewsItems=5 .listStyleRMnews li'); $('<div></div>').appendTo('#newsHoldingPanel').load('news.asp?newsSectionid=2&NoOfNewsItems=5 .listStyleRMnews li'); $('<div></div>').appendTo('#newsHoldingPanel').load('news.asp?newsSectionid=13&NoOfNewsItems=5 .listStyleRMnews li'); }); Hi, I've got a list of various news sources being aggregated into one <ul> - can anyone tell me how I can remove
[jQuery] General information -To get selected index of SELECT (list) using jQuery
Jquery selectedindex Need to remember that JQuery returns an array of matching elements, even if you use the '#' selector that returns only one elements based on the ID. So to find the selectedIndex of a list: function Method() { var index = $('#myList')[0].selectedIndex; };
[jQuery] How to remove default click behavior when double-clicking?
Hi guys, I'm wondering how to remove default click behavior of an <a> which is the parent of an <img>, when double clicking on the parent <div>? What I would like to achieve is that a user can edit the image when double- clicking on it (lightbox) and just follow the link when simply clicking on it. Thanks! tripleL
jquery works in Firefox,Safari, but not in IE
Ok, So check out http://www.lawsondesignfirm.com The index jquery works fine on all three browsers (last I checked) Now go to http://www.lawsondesignfirm.com/about-biz.php or any other secondary page. The jquery has gone loopy and is not working! It seems my CSS partially works, my jquery does not work at all... totally lost on why my jquery is not activating. Any suggestions on why would be helpful.
[jQuery] [autocomplete] How to send the partial word typed by user to ajax url?
Hello Gurus, Is it possible to send the partial word typed by user to ajax url in bassistance.de/jquery-plugins/jquery-plugin-autocomplete/? This will help me to use the sql syntax - select abc from tab_name where abc like "%user_word%" and limit the results to speed up. Also, I have a select drop down. I want to pass on the value of currently selected item (e.g. country) to the ajax url. How can I do this? Thanks.
[jQuery] Tablesorter sort all / sort current.
I'm using tablesorter to display a list of my search results. I want to be able to sort the viewable results or (depending on whether a checkbox is checked) go back to my app and sort all of the results. For example, say I have 2 columns. columnA and columnB. The user performs a search and finds 1000 records. (I obviously dont want to load all of these for performace resaons) So I show the top 20 search results which are initially sorted by columnA. If the user then decides to sort by columnB tablesorter
[jQuery] Tablesorter sort all / sort current.
I'm using tablesorter to display a list of my search results. I want to be able to sort the viewable results or (depending on whether a checkbox is checked) go back to my app and sort all of the results. For example, say I have 2 columns. columnA and columnB. The user performs a search and finds 1000 records. (I obviously dont want to load all of these for performace resaons) So I show the top 20 search results which are initially sorted by columnA. If the user then decides to sort by columnB tablesorter
[jQuery] Tablesorter sort all / sort current.
I'm using tablesorter to display a list of my search results. I want to be able to sort the viewable results or (depending on whether a checkbox is checked) go back to my app and sort all of the results. For example, say I have 2 columns. columnA and columnB. The user performs a search and finds 1000 records. (I obviously dont want to load all of these for performace resaons) So I show the top 20 search results which are initially sorted by columnA. If the user then decides to sort by columnB tablesorter
[jQuery] Problem in the autocomplete functionality in jquery
Hai, I have one email sending section. the can be fully worked on the basis of the ajax functionality. But I dont need to create the instance of the autocomplete in the $(document).ready(); Because my need is to create the instance of the autocomplete after the completion of the login.My login is working on the basis of ajax functionality.After the login, the email section div will come without refresh the page.I need to create the instance of the autocomplete in this time. I am trying for creating
[jQuery] (Validation) How to submit a form without validating
Hi, I am using the Jquery validationss plugin for my form validations. Now I have a situation where I have two submit buttons in a single form (say button A and button B). For button A, I want to run validations but for button B I don't want to run the validations and submit the form without validating.. How can i do this? Thanks.
how to detect if user input is a chinese character?
Hi guys, I got a textarea and I need to detect instantly if user input is a chinese character or not. IS there anyway jquery can help this? Thanks & Regards, Mark
[jQuery] jquery unchecking checkbox?
Hi all I'm implementing the standard select all/none functionality for table rows and got this problem that i can't overcome. I use this code snippet to do selection: $(selAll, tableSelector).toggle( function(e) { $('input[type=checkbox]', tableSelector).attr('checked', 'checked'); }, function() { $('input[type=checkbox]', tableSelector).removeAttr('checked'); } ); selAll is selector for checkbox that should select all/none checkboxes in table, tableSelector is... well... table selector. However
Bug jQuery 1.3.2 & FF3.5 - $("input[name='']")
This code used to work before i upgraded to FF3.5. Is there any other way to achive the same thing? $("input[name=''],textarea[name='']").each(function(i) { this.name = this.id; });
[jQuery] <3 Solitaire
Hi Check out the slick card game I just made - at http://www.lovesolitaire.com It entirely made in jQuery (1.3.3pre). It's also strangely addictive - so be careful! Love to hear any feedback any of you have! weepy
[jQuery] $(document).unload() does not fire.
Hello, I am extensively using jquery.ajax calls to display data on my web page (which build using partial rendering). In certain navigation flow a user move from one page to another. Before he moves I need to capture information filled in by user in first page(form) and save it in java script variable. Since my complete page is built using partial rendering the first form gets unloaded and new form gets loaded making ajax call. In order to capture the data user has filled in first form I have tried
[jQuery] Firefox 3.5 and same-site requests?
In firefox 3.5, http://www.chrisevert.org/ throws an error that I haven't seen previously: [Exception... "Component returned failure code: 0x805e000a [nsIXMLHttpRequest.open]" nsresult: "0x805e000a (<unknown>)" location: "JS frame :: http://www.chrisevert.org/a/scripts/jquery-1.3.2.js?recache=1247683374 :: anonymous :: line 3517" data: no] Line 3517 of jquery-1.3.2: http://skitch.com/expertseries/ba4fu/jquery-1.3.2 The request itself is local, via $().load('/url/local/file.php'); Maybe something
[jQuery] Can this plugin be structured better?
Hey, I'm in the process of developing a new plugin but the way I have structured the codes doesn't seem quite right to me so I'm hoping someone might be able to offer a better way to do it. The plugin itself has different behaviour if called on different types of elements (images, divs etc) with a range of shared functions used across all element types. This is the basic structure I have so far: (function ($) { $.fn.editable = function (options) { var defaults = { // default value declarations }
[jQuery] Chained Autocomplete selects
Hi there. I have a page that loads two other pages in with load. In one of the files there are two select lists, chained together using the Cascade plugin. I have embedded the Cascade plugin in the page that gets loaded. This works fine. However, the first list contains upwards of 2200 items and people are having trouble finding the proper choice. So now I need to add a filter or auto complete functionality. I'm having a problem getting the wheels rolling on this one...anyone have an example or suggestion
What is the best way to implement this?
The user should be able to add multiple attributes to a product, like this: Attribute 1 --- Category: <select> box Description: <input type="text"> And then you should be able to click a plus (+) button, and a new select box and text field should show to add attribute 2 and so on. I'm thinking of solving this by doing something like this, but I'm not sure if that's the best way? Feels a little "ugly" for jQuery var index = 0; function plusButton() { $('#wrap').append("<p><select name='box["
Next Page