[jQuery] getJSON doesnt remove <script>...</script>
Ive noticed that $.getJSON never attempts to remove the script tags it inserts. Is this a bug or by design? -Tom
[jQuery] OT: PHP to read jQuery API XML
<span style="font-family: trebuchet ms;">I am working on an API Browser. </span><br style="font-family: trebuchet ms;"><span style="font-family: trebuchet ms;">Rather than transform the whole XML structure on the client-side, I am using PHP to get and return only the parts I need. </span><br style="font-family: trebuchet ms;"><span style="font-family: trebuchet ms;">I am hoping this is a speed improvement.</span><br style="font-family: trebuchet ms;"><br style="font-family: trebuchet ms;"><span
[jQuery] easiest question all day
can someone show me an example of creating a simple variable and appending that variable to the document body? Here is my simple example (that doesn't work)... var GitRDone = "smoke'n hot"; $GitRDone.appendTo('body'); Thanks, Frank
[jQuery] jquery looping is slow
Hi, looping with jquery is quite slow, but still I want to continue with jquery looping(not custom looping) for reasons I can't explain right now. In my scenario I've to loop through rows of table and update the sequence of rows on table dynamically. suppose I've table with id "tableId". <table id="tableId"> <tr> <th>sq </th> <th>name </th> <th>ID </th> </tr> <tbody> <tr> <td class="sq">sq </td> <td>name </td> <td>ID </td> </tr> <tr> <td>sq </td> <td>name </td> <td>ID </td> </tr> <tr> <td>sq </td>
Welcome to the jQueryHelp
The purpose of this forum is to offer the quickest form of topic based conversation for jQuery users. Currently, there is only a mailing list which offers latent responses, but does have the largest user base and is a great resource. Though, there have been many requests for a forum so I have happily taken the initiative to set something up. Hopefully we can grow as a community here and help each other learn and get through problems and make a new home for jQuery users. Sincerely, Chrys Bader (aclevercookie.com)
[jQuery] Installation of UI?
[ If this is a duplicate I apologize -- it's been about 15 minutes and I don't see it on the list so I'm trying again. ] Hi all. I'm attempting to move to jQuery from MooTools, as I (generally) like the jQuery documentation better. However, I'm having trouble using the tableSorter function. I've downloaded jQuery 1.2.1 and UI 1.0. My JavaScript includes look like... <script src="/javascripts/jquery-1.2.1.js?1190074502" type="text/ javascript"></script> <script src="/javascripts/ui.tablesorter.js?1190019796"
[jQuery] Can anyone suggest a jQuery way of improving this UI? Screenshot included.
Hi all, So I created a portion of a project which users are having quite a bit of difficulty working with. If you take a look at the following screen shot, it'll give you the general gist of the particular page: http://catalyst.httpd.org/tmp/photos.png Here, users can order their pictures by inputting a priority number in a text input as you can see. When they're done with their modifications, an AJAX call is made to the server to update the database with the respective info via the 'Update Photos'
[jQuery] Why is this accordion crashing in IE7?
Demo is at http://vizualbod.com/accordion/demo.html
[jQuery] UI Photo Demo on Safari
Howdy, I'm wicked impressed with the photo demo of the new jQuery UI kit. Unfortunately, it doesn't seem to work on Safari. Is this a known issue (I couldn't find mention on this list with a couple of searches)? If it is, what's the ETA for a fix? Thanks, David
[jQuery] Effiecint way to create an object for checkboxes onload
Hi I've multiple criteria of checkboxes on one page. Each criteria contains differnt number of checkboxes. I've 8 criterias of checkboxes. For example <div class="refSearchCuisineForm"> <div><input type="checkbox" >A</div> <div><input type="checkbox" >B</div> <div><input type="checkbox" >C</div> </div> <div class="refSearchEntreeForm"> <div><input type="checkbox" >A1</div> <div><input type="checkbox" >B1</div> <div><input type="checkbox" >C1</div> <div><input type="checkbox" >D1</div> <div><input
[jQuery] Job Posting: Javascript/JQuery Developer
Venture-funded hot startup seeks an experienced JQuery/JavaScript developer for an exciting project to be used in the science and research worlds. Our multinational team has diverse backgrounds in academics, sciences, bio-tech, and hi-tech, and was founded on the observation that individual scientists have too much to read and understand, and also no convenient way to combine and evaluate existing information into potentially valuable new knowledge. The primary responsibility of the developer is
[jQuery] Update div
How update multiple div by ajax from php?
[jQuery] ajax response url
Hi, is there a way how to read url of ajax response? Usually it is the same url I called it with, but sometimes the target url is changed by redirect (code 302). So can I somehow read the "final" url? Thanks
[jQuery] loading into scrollable div?
I'm using the load() function to insert external html files into a scrollable div container. The problem is that if you scroll down in the content of the div, then do an action that loads new text into the div, the scroll stays where you were rather than returning to the top of the content. Is there a way around this?
[jQuery] jQuery UI - How do I get the X and Y of the DROP div
I'm using the example at: http://docs.jquery.com/UI/Droppables and I have the BLOCK dragging and able to drop it, but I want the BLOCK to take the X and Y position of the DROP div, I'm not sure how to find that out Also what are the ev, ui in the drop: function? Will UI give me the actual DROP div incase i have more than 1?
[jQuery] Determining the source of a load
We have a website that requires login. When we go to the site, if the login has expired we get a screen that logs us in, then redirects us to our initial request. The problem is that if the request is a jquery/ajax .load(...., 'mydiv'), it does not go into the div it justs loaded the whole bloody page into the window, thus ruining the page setup. I think the answer is to check the returning page source and then either reload the page or continue depending if I am logged on or not. Anyone have any
[jQuery] jQuery UI
Draggable for the UI has options, like GRID but there are no examples on how to use these options. Anyone know how?
[jQuery] How to return a click event from the container function
Hi, I'm currently working on a function which shows a inline dialog, so I can use html in the dialog box. In the dialogbox I've put a button to close the dialog box. If the button is clicked I want the function showDialog() to return a value. The problem is that it's out of the scope when I'm in the click() function. It there a solution? this.showDialog = function(msg, buttons) { $('#inline_dialog').show().swapDepths(); var buttons = (buttons) || '<div class="clear-block"></div><div id="inline_alert_close_button"></div>';
[jQuery] textareas and contains()
I am currently at war with the contains function. :-( Here's my snippet which doesn't work. $('#myTextarea').bind("keyup", function(){ if ($('#myTextarea').attr('val').contains('hello')) { log.empty().html('test'); } I want to bind a function to a textarea - On every 'keyup' event, jQuery should search the text inside the textarea for the word 'hello'. If that word is found it should print out a debug message to a layer. I already tried
[jQuery] PERFORMANCE TIP: removeClass()
<div><strong>Do not do:</strong></div> <div>$(...).removeClass('a').removeClass('b').removeClass('c');</div> <div> </div> <div><strong>Instead do:</strong></div> <div>$(...).removeClass('a b c');</div> <div> </div> <div>Same applys to addClass()</div> <div> </div> <div>I had 15 classes I had to remove and Firefox was a champ at chained removeClass calls, IE was taking 760ms!</div> <div> </div> <div>-js</div>
[jQuery] Spolsky's Strategy Letter VI
This is interesting in the context of jQuery's core optimization vs. larger, less-optimized libraries: ----- The developers who put a lot of effort into optimizing things and making them tight and fast will wake up to discover that effort was, more or less, wasted, or, at the very least, you could say that it “conferred no long term competitive advantage,” if you’re the kind of person who talks like an economist. <http://www.joelonsoftware.com/items/2007/09/18.html> ----- - Bil
[jQuery] Localization and using JQuery
I have an idea to get a mockup of a new site working in 2 languages WITHOUT being connected to a relational database. So my idea is to have an xml file with custom tags, a version for the English language and a version with the Japanese language. Can I use JQuery to traverse an xml document in the same directory and find the custom tag, grab the innertext and replace it in the html (or add it)? Can I get some sample code? Would this be too slow for production but good for a mockup site? Here is an
[jQuery] [SITE SUBMISSION] Google Code
The next time you hear someone say that jQuery isn't a mature framework, be sure to point them to this URL: http://code.google.com/ The way I see it is if Google feels confident enough to use jQuery, then that speaks volumes and the naysayers can take a hike! Rey...
[jQuery] Toggle working, but 2 clicks are needed ... (noob question?)
hi, here's the code I use: <pre> <span class="control hide"> <a href="#" onClick="toggleFnct($(this))"> <?php echo $html->image('nav/expand.png', array('class' => 'expand'));?> <?php echo $html->image('nav/reduce.png', array('class' => 'reduce'));?> </a> </span> function toggleFnct(handle) { handle.parent().toggle( function(){ $('img.expand').show(); $('img.reduce').hide(); $('#rss0').hide(); }, function(){ $('img.expand').hide(); $('img.reduce').show(); $('#rss0').show(); } ); } </pre> But using
[jQuery] Bigstring's jQuery front-end
Hey I wanted everyone to check our site, I used jQuery and corner.js plugin for the font-end. Thanks to all of you! Just another fine example of what can be accomplished, with JQuery! http://www.bigstring.com
[jQuery] $.getJSON and timeouts
Hi guys, Is there any way to handle timeouts when using $.getJSON() ? I tried to setup ajax "timeout" options to 2500 (2.5 sec), but as getJSON does not use a XHR, it seems not to work. Any help would be grately appreciated, thanks in advance, Matt
[jQuery] Browser Crash on SlideToggle (IE)
I have a strange situation where the browser crashes when a SlideToggle animation is applied. It happens with Internet Explorer 6 and 7. What makes it particularly odd is that it only happens for part of the site. Steps to reproduce: Go to http://www.nelctp.nhs.uk Click on Help in the bar at the top Then click on SiteMap The browser then becomes unresponsive. If you click on SiteMap on any other pages (as long as they are not under /help/) this problem does not occur and it slides down as intended.
[jQuery] Presentation pointers
Hi folks, I'm going to be giving a talk to my local CFUG on jQuery, and specifically using jQuery in conjunction with ColdFusion. I've been writing a tutorial on my blog on this subject, but haven't finished it yet (it's a three-parter). However, this talk looming in the future has lit a fire under my butt so I'm all gung-ho now, and my talk will pretty much be my blog article (completed). My problem now is that I've never given a presentation before. I think I can do a pretty good job, but I'd like
[jQuery] tablesorter pager error
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><title></title> <META http-equiv=Content-Type content="text/html; charset=windows-1251"> <meta http-equiv="Content-Style-Type" content="text/css"> <style type="text/css"><!-- body { margin: 5px 5px 5px 5px; background-color: #ffffff; } /* ========== Text Styles ========== */ hr { color: #000000} body, table /* Normal text */ { font-size: 9pt; font-family: 'Courier New'; font-style: normal; font-weight: normal; color: #000000;
[jQuery] adding custom attr on html elements?
if i have <a href="#" class="test" arg1="10" arg2="100">test</a> $("a.test").click(function() { arg1 = $(this).attr('arg1'); arg2 = $(this).attr('arg2'); // code using args }); is this acceptable way of using attr or should i avoid this?
[jQuery] Multi-Lingual Methodology
Can I create custom HTML attributes and have Jquery/DOM support in IE6+ ? Example: <a class="utilityLinks" href="index.html" xmlVal="topNavLinkHome">Home</a> | <a class="utilityLinks" href="#" xmlVal="topNavLinkLogin">Login</a> The idea here is that I would fire a function on load that would traverse the entire HTML document doing a unique lookup everywhere it finds the xmlVal attribute and replacing the elements text value (with a foreign language). The lookup would access a separate XML document
[jQuery] include children of previous siblings conditionally
Given the following as an example, does anyone know how I can highlight cells r2c1 and r2c2 whenever row 3 is moused over? Maybe something like, "add the children of the previous sibling to the selection criteria only if they contain a rowspan attribute"? http://www.tubenation.com/jquery/highlightable.html
[jQuery] Actions without to accumulate:
I've two calls to same link, first with a effect (slideToggle), and the second with a other action (toggleClass). for example $( "a" ).click( function() { $( "div" ).slideToggle(); return false; }); $( "a" ).click( function() { $( "div" ).toggleClass( "active" ); return false; }); Thus, every time that I click on link, the actions ( slideToggle and toggleClass ) accumulate. If I does click twice, the first time would stay ok, but the second time would show and hide the 'div' and would
[jQuery] tablesorter pager error
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><title></title> <META http-equiv=Content-Type content="text/html; charset=windows-1251"> <meta http-equiv="Content-Style-Type" content="text/css"> <style type="text/css"><!-- body { margin: 5px 5px 5px 5px; background-color: #ffffff; } /* ========== Text Styles ========== */ hr { color: #000000} body, table /* Normal text */ { font-size: 9pt; font-family: 'Courier New'; font-style: normal; font-weight: normal; color: #000000;
[jQuery] help - NewB question; creation of a very, very basic slideshow with XML import
Ok, I'm learning jQuery for the moment, but I have one problem I can't solve... :( I've just wrote a script that imports an XML-file with images (<image path="folder/image.jpg" />). I've succesfully appende them to a Div named - very original - "#test2". The images are given a class "importImg". Now I want to make a simple slideshow of the loaded images, so after the XML is loaded I call a function Slide() like follows: function Slide(){ $('img.importImg').each(function(index) { $(this).show(1000);
[jQuery] AJAX, sessions, and HTTP Status Codes
I've been thinking about using HTTP Status codes and a global ajax event to deal with session timeouts. Here's a little example: <a href="http://erikandcolleen.com/erik/projects/jquery/ajaxlogin/">http://erikandcolleen.com/erik/projects/jquery/ajaxlogin/ </a> Seems to work well in FF and Safari (both OSX). Is this a sound way of dealing with this? And are there any recommendations about particular response codes to use? --Erik
[jQuery] Now, what does this *really* mean?
<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] Form plugin throws "options.url.indexOf is not a function" error
Hi I am just starting to use jquery so have downloaded the latest jquery.js version (v 1.2.1). I wanted to utilise form submission so also grabbed the jquery.form.js However it throws an error on line 209 jquery.form.js "options.url.indexOf is not a function" Can anyone help me to get this working please? Cheers Tom
[jQuery] Wild cards in id names, class names and element names
Hi, Is it possible to use the same type of wildcards used in attributes, on id names, classes names and element names. For example, one could use the following to capture a range of attributes: # E[@foo^=bar] an E element whose "foo" attribute value begins exactly with the string "bar" # E[@foo$=bar] an E element whose "foo" attribute value ends exactly with the string "bar" # E[@foo*=bar] an E element whose "foo" attribute value contains the substring "bar" I would like to write something like $(/(id.*name)/)
[jQuery] Basic jQuery and Links?
Is it possible to use the "a" href attribute without the browser changing urls? This example alerts the file and then changes the browser to text.html $("a.wrapper").click(function() { alert($(this).attr('href')); $('div#wrapwindow').load('text.html'); }); I'd like to load this into a div, which works if I use a different "a" attributes such as rel... $("a.wrapperWorks").click(function() { alert($(this).attr('rel')); $('div#wrapwindow').load('text.html'); }); Using href="#" is also undesired
Next Page