[jQuery] Re: document Ready function in the Ajax Response

2008-11-11 Thread ravithokala
>From index.jsp i am calling datePicker.jsp through ajax. index.jsp <%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <[EMAIL PROTECTED] uri="/struts-tags" prefix="s"%> Date Picker $(document).ready(function() { $("select").change(f

[jQuery] Re: Trouble with "this"

2008-11-11 Thread Hector Virgen
Thanks for the all of the info, it has been very useful! My head isn't spinning as much as it was yesterday, and I thank you all for that :) -Hector On Tue, Nov 11, 2008 at 9:20 PM, Michael Geary <[EMAIL PROTECTED]> wrote: > > > > From: Michael Geary > > > Hector's head must be spinning by now,

[jQuery] Re: Script to keep draggable windows in the main window not working?

2008-11-11 Thread pd
I'm completely guessing but i think these lines might be the problem: newTop= window.height - $(this).outerHeight(); newLeft= window.width - $(this).outerWidth(); maybe try: newTop= $(window).height() - $ (this).outerHeight

[jQuery] Re: Trouble with "this"

2008-11-11 Thread Michael Geary
> > From: Michael Geary > > Hector's head must be spinning by now, if he's continued to > > read this thread. > From: RobG > I hope he(?) has, discussions are a great way get to > understand things. Very true! > Just to be clear, the term "method" is defined in ECMA-262 > section 4.2 as "a f

[jQuery] Re: 2 forms with SimpleModal

2008-11-11 Thread Xtophe
Dear Eric, Many thanks for your answer but I'm lost :-( In fact, I downloaded your example SimpleModal-contact. In your page index.html, you put the code : and a button . In my case, what have I to do ? It thought I had to replace this line (script src='js/contact.js' type='text/javascript'

[jQuery] Re: Parsing JSON with JQuery

2008-11-11 Thread nic
Ok I've cut my JSON data results so that I can make it a bit simpler. The data I now get is just: {"employees":["Joe","David"]} Hoping this will make it easier to traverse ... Still working on it, like I said I'm such a newbie with this so ...

[jQuery] Re: Trouble with "this"

2008-11-11 Thread RobG
On Nov 12, 12:53 pm, "Michael Geary" <[EMAIL PROTECTED]> wrote: > Hector's head must be spinning by now, if he's continued to read this > thread. I hope he(?) has, discussions are a great way get to understand things. > I tried to give an easy way to understand how "this" works, from the poin

[jQuery] Re: Traversal: Aggressive "next" to blast through all parents?

2008-11-11 Thread ricardobeat
Oh, I tested the script I posted earlier again on FF3 and IE7 and it works fine. Only if you call it with a non-existant element's selector as a parameter it will loop infinitel - it's rough as I said :) On Nov 11, 8:15 pm, Sam H <[EMAIL PROTECTED]> wrote: > Sorry - but your script causes an infi

[jQuery] Re: Traversal: Aggressive "next" to blast through all parents?

2008-11-11 Thread ricardobeat
Hmm. So you want it to grab only the last element found? Why not a straight simple $('.gotme') selector? In case you actually want all elements *between* those two, what would be the expected behavior for parents? Say you have this: something somethingelse $('#start-here').crawl('#end-here'

[jQuery] Re: jQuery + jQuery.form ajaxForm file upload problems

2008-11-11 Thread Sam Coughlin
Hi, Sam again here. Just thought I'd let everyone know I had to change the headers to be content type HTML and it worked fine. On Nov 12, 4:02 pm, Sam Coughlin <[EMAIL PROTECTED]> wrote: > Hi Mike, thanks for the reply. > > It's sending it as "application/json" at the moment. I will try > sendin

[jQuery] Re: Parsing JSON with JQuery

2008-11-11 Thread nic
Hi Mike, Thanks for your reply. i tried: return row.employees[0]; to see if it would give me back the first item, in this case, "Joe". I get the error "row.employees is undefined". So I tried: return row.employees; which gave me the entire: "{"field1":null,"field2":null,"field3":null,"field4

[jQuery] Re: jQuery + jQuery.form ajaxForm file upload problems

2008-11-11 Thread Sam Coughlin
Hi Mike, thanks for the reply. It's sending it as "application/json" at the moment. I will try sending it as text/plain and get back to you. On Nov 12, 3:57 pm, Mike Alsup <[EMAIL PROTECTED]> wrote: > > I have made a basic test case with a few text inputs and it works > > perfect with just them.

[jQuery] Re: jQuery + jQuery.form ajaxForm file upload problems

2008-11-11 Thread Mike Alsup
> I have made a basic test case with a few text inputs and it works > perfect with just them. > > However if I add a file input to them the json object is sent to the > browser as a file download and the success method is never hit. Is this happening on all browsers? What is the mime type of th

[jQuery] Re: Trouble with "this"

2008-11-11 Thread Michael Geary
Hector's head must be spinning by now, if he's continued to read this thread. I tried to give an easy way to understand how "this" works, from the point of view of the code that is running inside a function. > The assertion was that a call using an unqualified identifier > in the global scope w

[jQuery] jQuery + jQuery.form ajaxForm file upload problems

2008-11-11 Thread Sam Coughlin
Hi, I have made a basic test case with a few text inputs and it works perfect with just them. However if I add a file input to them the json object is sent to the browser as a file download and the success method is never hit. Anyone figure this out? I know the code that returns the json objec

[jQuery] Re: Parsing JSON with JQuery

2008-11-11 Thread Mike Alsup
> function formatItem(row) { >                 return row; > > }; I'm not sure that formatItem is allowed to return more than one item, but you could return the first employee like this: function formatItem(row) { return row.employees[0]; }; or better yet, use the search term to do somethi

[jQuery] Script to keep draggable windows in the main window not working?

2008-11-11 Thread CodingCyborg
I have a script to keep the draggable windows from leaving the main window they are in. When I comment out the code everything else works perfectly. But if I allow this code to be included, not everything loads, the windows won't move, but nothing shows up in error console. jQuery(documen

[jQuery] Parsing JSON with JQuery

2008-11-11 Thread nic
Hi, I have the following JSON data: {"field1":null,"field2":null,"field3":null,"field4":null,"employees": ["Joe","David"]} I'm using JQuery autocomplete and just need the values from employees (Joe and David). Right now I have this in my JavaScript" $("#myinput").autocomplete("myaction.action

[jQuery] Re: get the class that starts with ...

2008-11-11 Thread Richard D. Worth
Don't forget that elements can have more than one class (each separated by a space), so such a test will only pass if it's the first in the list. - Richard On Tue, Nov 11, 2008 at 6:22 PM, Rik Lomas <[EMAIL PROTECTED]> wrote: > > To get a class that begins with 'rate', you can do > $('*[classNam

[jQuery] Re: pirobox plugin released

2008-11-11 Thread Shawn Grover
I'd think that leaving the spaces and such in there make it more readable. And the more readable, the more "reusable" the code is by others. If you really want lightweight, then minimize or pack the library and use that version. But the "developer" version should be as developer friendly a

[jQuery] Re: pirobox plugin released

2008-11-11 Thread Isaak Malik
The one in the non-packed zip file is the same, can you provide us with the original file in the non-packed zip file? Also, I noticed there are parts that can be tweaked by using chaining. On Wed, Nov 12, 2008 at 1:56 AM, diego <[EMAIL PROTECTED]> wrote: > > You mean this http://www.pirolab.it/pi

[jQuery] Re: links going to "top" of page

2008-11-11 Thread Klaus Hartl
On 12 Nov., 00:15, "Rik Lomas" <[EMAIL PROTECTED]> wrote: > On links, you need to return false as this is the default behaviour > when a link is clicked e.preventDefault() should do the same... --Klaus

[jQuery] Re: pirobox plugin released

2008-11-11 Thread diego
You mean this http://www.pirolab.it/pirobox/js/pirobox.js ?? unreadable? I changed all the original variables and removed all the spaces to get the script more lightweight. Just this :) On 12 Nov, 01:47, "Isaak Malik" <[EMAIL PROTECTED]> wrote: > I just peeked at the source code and I'm wonderin

[jQuery] Re: pirobox plugin released

2008-11-11 Thread Isaak Malik
I just peeked at the source code and I'm wondering if this is the original version? It's quite unreadable. And of course, copyright notice will be kept untouched On Wed, Nov 12, 2008 at 1:43 AM, diego <[EMAIL PROTECTED]> wrote: > > This is great, the only thing i ask, is to leave my name up ther

[jQuery] Re: pirobox plugin released

2008-11-11 Thread diego
This is great, the only thing i ask, is to leave my name up there in the js, and if you want, a link back to my page :) Diego On 12 Nov, 01:38, "Isaak Malik" <[EMAIL PROTECTED]> wrote: > Oh, I didn't see the unpacked version and it was right under it... Thanks :) > > I may use this in a current

[jQuery] Re: pirobox plugin released

2008-11-11 Thread Isaak Malik
Oh, I didn't see the unpacked version and it was right under it... Thanks :) I may use this in a current project after some testing :) On Wed, Nov 12, 2008 at 1:34 AM, diego <[EMAIL PROTECTED]> wrote: > > Hi Isaak,i really hate explorer i work with firefox, for debug my > script,and when i o

[jQuery] Re: pirobox plugin released

2008-11-11 Thread diego
Hi Isaak,i really hate explorer i work with firefox, for debug my script,and when i open explorer i'm really scared of what can happen.. sure that is open source, you can download both version, packed and unpacked,just click the anchor 'download' on the nav. Diego On 12 Nov, 01:27, "Is

[jQuery] Re: pirobox plugin released

2008-11-11 Thread Isaak Malik
It doesn't sound strange at all, we can expect anything from IE ;) It is very interesting indeed but what about the license + source code? Is this an opensource library, if so can you also provide a non-packed version? On Wed, Nov 12, 2008 at 1:13 AM, diego <[EMAIL PROTECTED]> wrote: > > Hi Isaa

[jQuery] Re: $.post with an array of variables

2008-11-11 Thread Isaak Malik
Create a string instead and see if that works for you? Example: var str = '?'; str += 'freshbox=' + encodeURIComponent(freshBoxType); //etc... On Tue, Nov 11, 2008 at 8:37 PM, tukutela <[EMAIL PROTECTED]>wrote: > > Hi all, > > I have an array of variables that is built from the following: > > d

[jQuery] Re: pirobox plugin released

2008-11-11 Thread diego
Hi Isaak, i've tested it in ie6/7, ff2/3 , safari mac/pc , opera 9.5/9.6 , G. chrome, and the only problem i found it's with ie7,the animation is not as smooth as in firefox, it may sound strange but it works better with IE6, and not with ie7. It's ok in opera safari e chrome. The best performance

[jQuery] Re: pirobox plugin released

2008-11-11 Thread Isaak Malik
Very interesting piece of work :), have you performed cross-browser tests? On Wed, Nov 12, 2008 at 12:55 AM, diego <[EMAIL PROTECTED]> wrote: > > Hi all, i've finished my first plugin, hope you like it, any question > or opinion it's welcome. > > http://www.pirolab.it/pirobox/ > > I developed thi

[jQuery] Re: Trouble with "this"

2008-11-11 Thread RobG
On Nov 12, 2:30 am, ricardobeat <[EMAIL PROTECTED]> wrote: > On Nov 11, 10:54 am, RobG <[EMAIL PROTECTED]> wrote: > > > No, it's not. What object is the following functions called as > > methods of: > > > (function(){})(); > > window? No, it isn’t called as a property of any object. The functio

[jQuery] pirobox plugin released

2008-11-11 Thread diego
Hi all, i've finished my first plugin, hope you like it, any question or opinion it's welcome. http://www.pirolab.it/pirobox/ I developed this plugin, by studying the docs.jquery, it's amazing what you can do with this library. Tnx to all the jquery developers. Diego Valobra

[jQuery] jeditable & autocomplete - time to revisit?

2008-11-11 Thread [EMAIL PROTECTED]
Hi, I would like to combine autocomplete (http://bassistance.de/jquery- plugins/jquery-plugin-autocomplete/) functionality with inline editing of jeditable. (http://www.appelsiini.net/projects/jeditable) I have looked at previous postings and done a google search and turned up an instance where s

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread John Ruffin
Absolutely right! In my .jsp I had something like this: I changed it to this (no spaces): and I was able to access the element below (showed in the console). function woa(res) { alert(res.responseText); var dom = parseXML(res.res

[jQuery] Re: get the class that starts with ...

2008-11-11 Thread Rik Lomas
To get a class that begins with 'rate', you can do $('*[className^="rate"]') Note that the attribute is className, not class $('*[className^="rate"]').each(function () { alert( $(this).attr('className').split('rate')[1] ); }); 2008/11/11 debussy007 <[EMAIL PROTECTED]>: > > > Hi, > > How is i

[jQuery] Re: get the class that starts with ...

2008-11-11 Thread Jeffrey Kretz
Try $('[class^=rate]'); -Original Message- From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of debussy007 Sent: Tuesday, November 11, 2008 3:15 PM To: jquery-en@googlegroups.com Subject: [jQuery] get the class that starts with ... Hi, How is it possible to get the

[jQuery] Re: links going to "top" of page

2008-11-11 Thread Rik Lomas
On links, you need to return false as this is the default behaviour when a link is clicked $("a").click(function(e){ $.get($(this).attr("href"),{},function(data){ $("#rating").html(data); }) return false; }) 2008/11/11 rpetras <[EMAIL PROTECTED]>: > > > Hi all, > > New to JQuer

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread Michael Geary
That sounds like whitespace before the From: John Ruffin > > Michael, I tried your test verbatim as the callback to my > $.ajax { complete : yourFunctionNameHere }. Worked like a > charm. I saw the expected results in the console. > > However, when switch your xml to be evaluated out for th

[jQuery] get the class that starts with ...

2008-11-11 Thread debussy007
Hi, How is it possible to get the class that starts with 'rate' of an element ? the class could be rate1, rate5, rateXYZ. I don't know what follows the substring 'rate'. I need to get the number that follows rate. Thank you for any help ! -- View this message in context: http://www.nabble.co

[jQuery] Re: Custom sorter/parser for tablesorter

2008-11-11 Thread Rodent of Unusual Size
On Nov 11, 9:37 am, MorningZ <[EMAIL PROTECTED]> wrote: > Here's an example if my question above is answered by "yes, that's > correct" > > http://paste.pocoo.org/show/90863/ That only handles the aspect of ignoring the alpha characters. It does *not* appear to handle the issue of sorting 40125

[jQuery] Re: remote issue

2008-11-11 Thread Alexsandro_xpt
Up On 5 nov, 13:19, Alexsandro_xpt <[EMAIL PROTECTED]> wrote: > P.S. > > I am mean about NewsLetter Form, find it on middle of the page in the > next text "Receba nosso informativo por e-mail:" > > Thz. > > On 5 nov, 13:17, Alexsandro_xpt <[EMAIL PROTECTED]> wrote: > > > Inhttp://jquery.bassistan

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread Mike Alsup
> Mike, you lost me a bit.  If Tomcat is serving an xhtml facelet or > jsp, not sure how to tweak it to change the mime-type. For jsp: response.setContentType("text/xml"); or response.setContentType("application/xml"); You can use Firebug to inspect the content-type on the response header.

[jQuery] Re: Custom sorter/parser for tablesorter

2008-11-11 Thread Mike Nichols
> Yuck, why "patch" the js file when a custom parser could just be > built? IIRC, the custom parser changed from being able to sort as a set to go an item by item comparison, which eliminated being able to do a natural sorting algorithm. This is a bit different from Rodent's requirements but rema

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread John Ruffin
Michael, I tried your test verbatim as the callback to my $.ajax { complete : yourFunctionNameHere }. Worked like a charm. I saw the expected results in the console. However, when switch your xml to be evaluated out for the xhr.responseText - I get an "error" in firebug "XML or text declaration

[jQuery] Re: How to call axis2 ws with jQuery, json or REST

2008-11-11 Thread hydrokool
Not sure if it'll help but just from a quick glance you seem to be missing the ending "});" part. With "});" added: $.ajax({ type: "POST", url: "http://localhost:8080/.../getIt? userId=1&output=json", data: "{}",

[jQuery] Re: has anyone come across a plugin like this ?

2008-11-11 Thread Andy Matthews
I'd be interested in this as a plugin as well. On Nov 11, 4:21 pm, heysatan <[EMAIL PROTECTED]> wrote: > That's a start. > > On Nov 10, 4:13 pm, Microbe <[EMAIL PROTECTED]> wrote: > > > Demand # 1 > > > :o) > > > On Nov 11, 8:57 am, heysatan <[EMAIL PROTECTED]> wrote: > > > > Hi Sean, > > > > I b

[jQuery] Re: has anyone come across a plugin like this ?

2008-11-11 Thread heysatan
That's a start. On Nov 10, 4:13 pm, Microbe <[EMAIL PROTECTED]> wrote: > Demand # 1 > > :o) > > On Nov 11, 8:57 am, heysatan <[EMAIL PROTECTED]> wrote: > > > Hi Sean, > > > I built this breadcrumb animation.  Due to time limitations at the end > > of the project I wasn't able to make it into a pl

[jQuery] Validator Plugin ajaxSubmit

2008-11-11 Thread lance123
Hi To All, I am having a problem with Safari using the standard test example the loading image starts prior to any activity in fields or buttons: http://jquery.bassistance.de/validate/demo/ajaxSubmit-intergration-demo.html Really looking forward to getting ajax and validation co-existing :) Th

[jQuery] Re: Traversal: Aggressive "next" to blast through all parents?

2008-11-11 Thread Sam H
Sorry - but your script causes an infinite loop for some reason. And jQuery's "nextUntil" doesn't work either, it doesn't survive past the end of the sibling tree. I need my function to go PAST the end of the list of siblings, up through parents, etc., all the way to the end of the document if n

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread Michael Geary
You could just run an XML parser on the returned text: http://groups.google.com/group/jquery-en/msg/3b15af17889ee816 -Mike > From: John Ruffin > > I tried to set the $ajax{ dataType : xml } attribute but the response > still showed in responseText not responseXML.

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread John Ruffin
Mike, you lost me a bit. If Tomcat is serving an xhtml facelet or jsp, not sure how to tweak it to change the mime-type. I tried to set the $ajax{ dataType : xml } attribute but the response still showed in responseText not responseXML. Any other ideas? On Nov 11, 3:31 pm, Mike Alsup <[EMAIL P

[jQuery] Re: Tab divs disappear

2008-11-11 Thread Klaus Hartl
And you're not using Ajax tabs? Rotate and Ajax together is not supported right now. --Klaus On 11 Nov., 20:39, aaron <[EMAIL PROTECTED]> wrote: > $(function() { >                 $('#tabs_container > ul').tabs( {fx: { opacity: > 'toggle' } }).tabs('rotate', 5000); >         }); > > On Nov 7, 4

[jQuery] Re: jQuery.getScript and Browser Cache

2008-11-11 Thread Panman
True, combining files would be the best option. I'm thinking in the case where I would like to detect weather or not a specific plugin is required. So if x element exists then include x plugin. Just looking for something like the Dojo require, which loads its' modules. Another option I thought o

[jQuery] Re: Jquery Xml and XPath

2008-11-11 Thread Karl Swedberg
On Nov 11, 2008, at 12:09 PM, Klaus Hartl wrote: XPath is not supported by jQuery (since a while). There once was a plugin that adds support, but I am not sure if that is maintained still. It still works. you can find it here: http://plugins.jquery.com/project/xpath --Karl Kar

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread Mike Alsup
> In Firebug, xhr.responseXML is null.  Is there something explicitly I > need to do in order to populate it? Your server needs to set the correct mime-type.

[jQuery] conditional remote validation

2008-11-11 Thread spellingcity
There is a particular scenario where I don't want the remote validation to actually get executed. In particular, this is when you have a field, say a "username" field and the user is editing the field and the value of the field is their current username. This is considered a valid username and r

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread John Ruffin
In Firebug, xhr.responseXML is null. Is there something explicitly I need to do in order to populate it? On Nov 11, 3:09 pm, Mike Alsup <[EMAIL PROTECTED]> wrote: > > > enctype="application/x-www-form-urlencoded"> > > > > > Here I want to get the value of iiForm:iiDude. > > Why not use respons

[jQuery] Re: jQuery.getScript and Browser Cache

2008-11-11 Thread Michael Geary
Are you going to always be loading these .js files into your page? If so, the most efficient option by far is to concatenate all of them into a single .js file that you load with a single tag. Maybe explain more about why you want a bootstrap file, and what exactly you want it to do? -Mike >

[jQuery] Re: [autocomplete] - IE 6 and IE 7 Scroll bar problem."

2008-11-11 Thread Akio
Just editing the subject so it shows [autocomplete] On Nov 11, 11:26 pm, Akio <[EMAIL PROTECTED]> wrote: > Jorn, > > Thank you for showing interest in my problem. > > It shows the problem on all inputs with a scroll bar. You can try it > on Single City (local) or Single Bird (Remote) > onhttp://

[jQuery] Re: how to use another javascript funtion (and outside variables) inside jquery model

2008-11-11 Thread Michael Geary
That looks like just what Oli needs - thanks, Ricardo. The selector is not quite right in the click handler. Don't strip off the leading '#' character, because you would just have to add it back in to make a jQuery selector. Also, for efficiency, I would suggest using IDs instead of classnames f

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread Mike Alsup
> enctype="application/x-www-form-urlencoded"> > > > Here I want to get the value of iiForm:iiDude. Why not use responseXML since you're returning an XML doc? Maybe something like: $('#iiForm\:iiDude', xhr.responseXML).attr('value');

[jQuery] Re: validate

2008-11-11 Thread christine . panus
That would be the groups option, I'm still trying to make it work, but here's the documentation I've found:http://docs.jquery.com/Plugins/Validation/Reference#Validating_multiple_fields_with_one_method I've got my rules and my groups option both in the validate _javascript_ call.  If you figure ou

[jQuery] jQuery.getScript and Browser Cache

2008-11-11 Thread Panman
Are browsers able to cache calls from jQuery.getScript (http:// docs.jquery.com/Ajax/jQuery.getScript)? I'm just trying to determine either to use that or just use HTML tags to get jQuery plugin files and such. Would like the most officiant option. The reason being, I'd like to break out the firs

[jQuery] validate

2008-11-11 Thread jalanbyers
Hi, I am using the amazing validator plugin by Mr. Zaefferer.. I'm unable to find any documentation on using multiple fields within a single validation rule (e.g. adding a single validation to 3 social security number fields rather than validating each field separately and using a single errorCon

[jQuery] Re: How to parse XMLHttpRequest.responseText from $.ajax(complete: function())

2008-11-11 Thread John Ruffin
Here is the "entire" response if this helps: http://www.w3.org/TR/xhtml1/ DTD/xhtml1-transitional.dtd"> http://www.w3.org/1999/ xhtml"> $(function(){ alert(" READY FUNCTION made it to ii.faces"); }); Welcome2 Hey You