t 50 if not 100 posts in the feed, which the
previous Google Groups interface allowed me to retrieve. I would like
the zoho feeds to give more items, perhaps with an optional "?num=50"
type argument in the url.
Matt Kruse
--
You received this message because you are subscribed to the
he moment to help implement it.
Check the archives. This comes up every few months, everyone agrees it
would be cool, everyone agrees it could be implemented relatively
easily, yet no one wants to spend the time to build, test, and release
it. Bummer.
Matt Kruse
--
You received this message bec
bject ?
new window.XMLHttpRequest() :
new window.ActiveXObject("Microsoft.XMLHTTP");
In FF:
return (true && false || false)? : new window.ActiveXObject
("Microsoft.XMLHTTP")
ERROR:
"window.ActiveXObject is not a constructor"
Matt Kruse
--
You recei
fail in IE6 with ActiveX disabled, pop up a scary
warning to an unsuspecting user, and stop scripts from running.
Just because window.ActiveX exists doesn't mean that
window.ActiveXObject("Microsoft.XMLHTTP") will be successful.
You still need try/catch to avoid the potential erro
nctionality will even be supported in the user's
browser. Right now there isn't even a way to check for ajax support
and degrade gracefully if it doesn't exist.
jQuery.support.ajax = (xhr()!=null);
Hope that helps some more,
Matt Kruse
--
You received this message because you are
n memory use doesn't raise any red flags to me, it
could just be how IE handles the new code differently. You'd have to
repeat the test many times and watch Drip to see if the memory use
steadily rises over time to know if there is still a real leak.
Matt Kruse
--
You received this m
in that includes
the xhr object, etc. You need to do something like
jQuery.noop = function(){};
and set
xhr.onreadystatechange = jQuery.noop;
Matt Kruse
--
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post t
s wasn't immediately obvious
originally, and polling seemed like a "good enough" alternative?
Matt Kruse
--
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-...@googlegroups.com.
To
I agree, but it is a change in the API and may make it difficult for
some to upgrade (it removes functionality). The wandering API
sometimes makes it difficult to upgrade jQuery versions, which is why
I have some projects stuck on 1.2.6 and one that was just recently
upped from 1.1.2! :(
Matt Kr
lowing cases:
#1)
Dummy
Empty
$('#x').val('')
should select the second option.
#2)
z
x
$('#x').val('x')
should select the first option only.
#3)
y
y
$('#x').val('y')
should select the second option only.
#4)
z
this:
Dummy
Empty
$('#x').val('') ==> Will not select the second option!
> I can see why this optimization was done, but I think that this will
> cause problems for a lot of people!
Agreed, the change is broken! Wasn't there a test case for the above
scenario?
n you'll have a more robust, feature-tested, efficient, correctly-
documented fix to this "problem".
Again, though, my suggestion is to just remove it. I don't think
generalized library code should try to normalize behavior that is not
demanded by the specs and that can be easi
I debugged a tricky problem today in an app that came down to jQuery
hanging IE. I know v1.1.2 is ancient, but I am trying to understand
the root cause, so I'm just curious if anyone else has seen anything
like this. Just trying to gather info.
The problem:
On one page in a webapp, the content is
ow in the world would jQuery know if you're trying to filter on the text
> content "div" or on a descendant div element?
>
> --Karl
>
> On Dec 17, 2009, at 4:35 PM, Matt Maxwell wrote:
>
> It's a selector or a string of text. jQuery already contains the ability
&
But :has() and :contains() do two completely different things. :contains()
> filters based on text contents while :has() filters based on selectors. So,
> I think it would be a really bad idea to try to combine them.
>
> --Karl
>
>
> On Dec 17, 2009, at 3:48 PM, Matt Maxwell wro
I think .has() should return a bool, :has() should be combined with
:contains() (the finished filter named :contains()), and .contains() should
go away.
That seems to make the most sense to me, anyways.
On Thu, Dec 17, 2009 at 9:20 AM, Karl Swedberg wrote:
> On Dec 16, 2009, at 11:14 PM, John Re
t
called in both cases.
So
$o.attr('width') == $o.width()
and
$o.attr('width',5) == $o.width(5)
Matt Kruse
--
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-...@g
css, html, text, data,
> width, height, and offset (and the events).
Hmmm... $('').attr('data') => ???
You may run into a number of cases that may need "special handling",
at which point you have to have really good documentation about the
intent of the m
tributes do you plan to map to
methods - just height and width? Or more?
Matt Kruse
--
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-...@googlegroups.com.
To unsubscribe from this gro
've never been a fan of head-in-the-sand. I can find the pearls of
wisdom in the posts there without taking anything personally. And
there is a lot of good, robust, deep stuff posted there that you won't
find in blog posts or discussions here. To each his own.
Matt Kruse
--
You received
to do the extra check. It's silly, of
> course, since the extra argument shouldn't do anything.
Never seen that problem, and I'm too lazy to look for it. I'll trust
you on that one. May want to add a note to that effect in the source.
Explanatory documentation is valuable.
Mat
nk all these cases/differences are currently handled and I
> don't think they can be handled in a reasonable way.
This case seems to be handled with this code:
if ( !jQuery.support.style && notxml && name == "style" ) {
if ( set ) {
elem
elem.getAttribute( name, 2 )
: elem.getAttribute( name );
could be simplified to:
var attr = elem.getAttribute(name,2);
Matt Kruse
--
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this
to
tread those waters, but that seems kind of like a "see no evil, hear
no evil" attitude.
> Matt, I definitely welcome your help or feedback to the jQuery
> project, but please provide your own test cases, test suites, and bug
> reports from now on - this goes for anyone else as wel
ecessary.
It's been pointed out that most users don't really need to interact
with attributes to begin with. In most cases, they want to get/set
properties of objects, not their attributes. A prop() method might be
more clear, along with attr() if you really, really need to get/set
attr
7;t do what the documentation says it does, and
is a constant (justified) source of criticism of the jQuery library.
Any hopes of fixing it up soon?
Matt Kruse
--
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group
On Dec 5, 5:42 pm, Mike Taylor
wrote:
> You're probably getting the Exception 5 due to the "-" in the attribute
> name, which is illegal.
Should jQuery crash when passed a value it doesn't like?
Matt Kruse
--
You received this message because you are subscribed to
I would do something like
$("select.country").change(function () {
var country = $(this),
country_id = country.attr("id"),
state = country.next("select.state");
});
state isn't the DOM element, it's the jQuery object, so you'd have to go
alert(state.attr("id"));
Hope this helps.
Also, I agree w
My first guess would be the use of :DropDownList.
Why not use a more specific selector for your find?
Also, I'm not sure this is the right place for this question.
On Fri, Nov 20, 2009 at 5:53 AM, Nizam wrote:
> Hi,
> In the below Code takes too much of time for execute I don't know
> did I
ike it does an ajax call to
retrieve each stylesheet, which is not efficient, and ignores css
defined in-page.
Instead, consider looking through document.styleSheets and
inspecting .cssText of each and parsing that.
Matt Kruse
--
You received this message because you are subscribed to the Google
ading their jQuery version, because it would
require going in and fixing lots of code. I wish there was more
backwards-compatibility!
Matt
On Oct 2, 5:58 am, DBJDBJ wrote:
> Matt Kruse has an nice and simple jQuery "ideas page". I could not
> make it work for me.
>
> h
Have you tried using fadeTo or animate instead? I had similar issues
with IE8 a while ago and from what I recall switching to fadeTo did
the trick.
On Sep 23, 12:08 am, Mad-Halfling wrote:
> Hi, I originally posted this in the general discussion, but it is
> probably more appropriate here.
>
> A
t; To append 50.000 options to a select element ?!
> The latest Chrome Beta on the same W7 machine, jQ unit test reports 1
> millisecond (which can't be right)
> Same is on the latest FF ...although FF "complaints" message box
> popped-up.
>
> Maybe n
Well, the select lists everyone that has access to utilize the ticketing
system for submitting feedback/kudos on them, so everyone needs to be in the
select.
I'll try the suggestions here.
Thanks for all the good advice!
On Tue, Sep 22, 2009 at 3:49 AM, DBJDBJ wrote:
>
> Web 2.0 Apps and "multi
The thing is, I need the actual text of the selected option. I wound up
using a mix of DOM/jQuery on this, but was just wondering if anyone had
experienced similar issues.
I didn't actually set the innerHTML to nothing, I did:
document.getElementById("select").parentNode.removeChild(document.getE
Slightly slower actually. Maybe a few milliseconds, I believe. I don't
recall the exact times.
I could set up another test case with some timing if you want.
On Mon, Sep 21, 2009 at 11:00 AM, Samer Ziadeh wrote:
> How does it perform if you remove the .find(), so you get $('#mySelect
> option:s
bal (or containing) scope, while the
second would be local to the function. However, in reality since the
'var' is found first, both variables refer to the same item.
This is a reason why it is common and recommended practice to declare
all local variables at the top of a function, usin
proof of concept plug in, so I'll post here
> again with the example.
See a short discussion and proof-of-concept here:
http://groups.google.com/group/jquery-dev/browse_frm/thread/5360f7b3d67a2ddc
Matt Kruse
--~--~-~--~~~---~--~~
You received this message
ined.
Depending on what type of element you are calling this on, the results
may be the same (input, for example), or different (img, for example).
It's always best to avoid using attr() because of it's poor
implementation. IMO.
Matt Kruse
--~--~-~--~~~---~--~-
I recently posted this bug regarding selectors with commas in IE 7. It
includes a minimal test case.
http://dev.jquery.com/ticket/4999
I was just wondering if anybody had had the time to look into it. :)
-matt
--~--~-~--~~~---~--~~
You received this message
n a maze of questions, and the easiest way out is to avoid
the need for isFunction to begin with (ie, stop all the overloading).
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development"
en keeping IE6 becomes more painful than upgrading will these
last hold-outs change. I suspect that time is coming soon...
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" gr
how/hide an element with a fade effect.
Use animate instead:
$obj.animate( {'opacity':0} ); // fade out
$obj.animate( {'opacity':1} ); // fade in
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
ht to/from 0 as long as the units are px -
always use 1 instead. I can't think of why this would be a problem in
any browser, would it?
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Deve
y should
normalize browser behavior, not label common and perfectly valid
situations as "unsupported" simply because the fix requires some
additional work. That's a very disappointing approach to development,
IMO.
Matt Kruse
--~--~-~--~~~---~--~~
You
Or if you really wanted to use jQuery a little:
$('#testSelect options')[idx].selected = true;
> Is this a bug in JQuery?
Yes. Avoid the attr() function in jQuery, it's been broken for a long
time.
Matt Kruse
--~--~-~--~~~---~--~~
You rec
s" I recommend that developers
never chain across multiple lines. I always encourage assigning $()
calls to a variable, then using that variable.
Any line beginning with a . should be discouraged, IMO.
Just my $.02...
Matt Kruse
--~--~-~--~~~---~--~~
You rec
some point
in the future. It's kind of a cool way to see what's going on in the
"jQuery Cloud".
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group
On May 19, 9:19 am, diogobaeder wrote:
> Brainstorming: what about a $.each2 method, to avoid messing with the
> original signature (name + parameters), but using
> Array.prototype.forEach?
Why not just call Array.prototype.forEach in your code if it exists?
M
e better to put the debugging into the source itself, then
use a builder to create a debug version and a release version.
In the absence of that, though, it would be fantastic to have a group
of people working on a debug plugin.
Matt Kruse
--~--~-~--~~~---~--~
ty selector results, invalid arguments,
etc. It could also detect possible conflicts like this that would
cause jQuery to misbehave and alert the developer.
Once development is done, you swap in the "production" version of
jQuery and avoid the penalty his that comes with all
k failed (inferring its existence is just as bad as browser
detection).
(btw, I tested the above code on a sample case, but not against the
test suite)
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"
ns of how jQuery should behave and point to an alternative. :)
In the example case:
#foo { padding: 5px 10px; }
you may want to consider returning [5,10,5,10] for example.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to t
.javascript/msg/aa56d57c625b404c
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-dev@googlegroups.com
To unsubscribe from this group,
On Apr 17, 2:21 am, Rick wrote:
> It would be nice to have a function to test for JQuery equality.
As previous discussed here:
http://groups.google.com/group/jquery-en/browse_thread/thread/002d7543186ddaa6
This is a bit cleaner and uses !== which is better than !=
$.fn.equals = function(compar
and the exact layout/objects in
question, but I've used this solution several times and it's been
sufficient for me. It may be enough for the OP.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
&q
hat uses jquery's return value and adds
in your calculations for your offset body.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send
then
using it is probably a bad idea to begin with, as internals often
change.
Any callers using args could easily be updated to avoid its usage, but
whether that's worth it is up to John, I guess.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message beca
This is the current .each() function:
-
// args is for internal usage only
each: function( object, callback, args ) {
var name, i = 0, length = object.length;
if ( args ) {
if ( length === undefined ) {
for ( name in object
test for it. The guys over at comp.lang.javascript are especially
good at detecting and correcting for quirky behavior in browsers
without the need for sniffing at all.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the
different thins like:
> $('input[value='+$(this).text()+']')[0].remove();
When you do [0] you get the first DOM element, which is no longer a
jQuery object, so it doesn't have the remove() method.
Instead, you want this:
$(
u need to detect this? What problem are you trying to
solve?
This is exactly why any type of browser sniffing is inherently error-
prone, and feature-detection strategies should be used instead.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you a
jQuery often, but
I still write POJS in most cases unless jQuery would make something
significantly easier or more concise, or fix browser quirks that I
don't want to do myself.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subs
the jQuery internals, as a jQuery
method should.
If you just want to remove an object from the DOM, just use simple,
standard javascript.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Develo
hings like selectors that return
no matches and passing complex selectors to .is (which often tripped
up many developers in the past).
Putting debug code into the core itself for a "debug version" and then
filtering it out for the "release version" of jQuery would
and codify some of
> these notions.
I hope you'll take a quick look at
http://www.javascripttoolbox.com/libsource.php/contextmenu/source/jquery.contextmenu.js
I don't propose it as a perfect or ideal solution. But it's one
approach, and
n an {options} parameter instead of a hard-coded list of
options
11. Provide useful examples
12. Use a good code structure like ;(function($){ })(jQuery) and other
common recommendations
That's a short brain-storm at least. Key concept when writing a
general-use plugin - Avoid Assumptions! :)
M
projects that I've worked on. If you're
looking for any new thoughts on the issue, I'd like to participate.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" g
On Feb 16, 12:31 pm, John Resig wrote:
> There were some logic changes ... how :visible/:hidden work
Previously, elements with visibility:hidden were not :visible, but now
they are (tested in IE6,FF3). Was this an intentional change?
Matt Kr
ibility
to leave them out.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-dev@googlegroups.com
To unsubscribe from this g
On Jan 29, 8:24 pm, Yehuda Katz wrote:
> $("p").bind("keydown[keyCode=119]", function() {})
Could you also just redefine 'keydown' as a plugin?
$('p').keydown( 119, function(){} );
or
$('p').keydown( [119,120,121], function(){} );
or
$(
On Jan 29, 3:50 pm, Diego Perini wrote:
> None of them specify if the field would be submitted or not, if I
> recall correctly all of the form elements values should be serialized
> and submitted, "enabled", "disabled" and "hidden".
Disabled form
> it's acceptable to "blow up" in your ultimate else clause?
Falling back to a particular fix just because the standard way didn't
work is just plain faulty logic. It's just waiting to fail.
Intentionally falling into an "else&
(activex_test())
use_activex = true
else
ajax_available = false
endif
endif
This way, my script could check ajax_available early to see if it's
going to succeed. I can then make choices based on that.
Another example of this approach is: http://www.cinsoft.net/mylib.html
It's a lit
table
devices, embedded devices, kiosks, higher security, etc) is the bigger
concern.
Consider an IE6 user in an environment where the administrators have
disabled ActiveX and ajax is not available. What happens? Will jQuery
choke, or continue to function in the most optimal way? Is there any
correct way to fix
it. You need to test to see how the feature behaves to know which fix,
if any, is most appropriate.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
d making other
assumptions about the browser based on that property).
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-dev@g
inding the best solutions if anyone is interested. I think
it's an interesting technical challenge.
On Jan 26, 7:35 pm, Kevin Dalman wrote:
> @Matt: Re: "Why not just check the value, and if it is 0 or undefined/
> null, apply the "visibility" fix?"
> Because
On Jan 26, 1:02 pm, Kevin Dalman wrote:
> @Matt: This may be functional...
> useIframe:/*...@cc_on @*//*...@if (@_win32) true, @else @*/false,/*...@end @*/
> But using a conditional comment 'hack' is just browser/platform
> sniffing by another name.
It's a diff
On Jan 26, 10:38 am, Elijah Insua wrote:
> that is really smelly, IMHO
Why would you think it is smelly? It's technically sound and, IMO, the
preferred solution.
Matt
--~--~-~--~~~---~--~~
You received this message because you are subscribed to th
On Jan 26, 10:36 am, Jörn Zaefferer
wrote:
> How do you get that code through a minifier?
A good minifier shouldn't mess it up. A custom-built minifier I use
works fine.
Matt
--~--~-~--~~~---~--~~
You received this message because you are subscribe
ince the problem only exists on windows, this will save other
platforms from the unnecessary inclusion of the iframe.
No one should be using browser sniffing or inferring this problem from
things like maxHeight! This problem and solution has been around for
many years and d
ewhere? (I browsed the bug
tracker but it's difficult to find things).
It's not always possible to run pages in standards mode. If jQuery 1.3
will break my quirks pages, I need to know what to look for.
Matt Kruse
On Jan 14, 8:45 am, John Resig wrote:
> Hey Everyone -
>
> jQ
t the standard method, it will
always be used.
If a browser doesn't support standards but supports an alternate, it
will be used.
If neither are supported, an incorrect fix is NOT applied and assumed
to work, and the code can either blow up and s
Query user and advocate
(for the right situations), so I say this not because of some desire
to nit-pick or criticize, but because I want the js framework that I
use to be as solid as possible.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you
I cant seem to set the value of any select elements using val. Input
type=text is working fine.
So I have something like:
$('#usa_reference_state_id').val("2")
alert($('#usa_reference_state_id').val() )
and the alert is "" so no value was set. I am 100% sure that 2 is in
the list
hen it should be all the same from your point of
view. But if it becomes a non-binary situation, the existing logic
fails whereas the other method would not.
In the end, it works as-is and I'm thankful for it. It's just a bit
disappointing to see the effort
You should be testing for non-standard functionality,
not testing for the standard behavior and if it's not correct then
assuming what the fix should be.
Is there any reason feature detection was implemented in this way?
Matt Kruse
--~--~-~--~~~---~--~
cument.getElementById() or document.getElementsByTagName(), just to
start.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-dev@goo
in
the jQuery code, create a jQuery variable that references the
document. Any code not in the expected environment can change it as
needed.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development&q
ource that
includes error-checking and warnings built-in as a "developer"
package. But assuming that won't happen, this is a way to "patch in"
this kind of functionality.
Any thoughts?
Matt Kruse
SOURCE:
http://code.jquery.com/jquery-</a>
latest.
he stuff that they think is
most important.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery-dev@googlegroups.com
To unsubsc
e only
one I use. It works well enough for me without modifying jQuery core.
Matt Kruse
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to jquery
p://groups.google.com/group/jquery-en/browse_frm/thread/1f6790e31d33e32a
$('#one').click(" alert('you clicked me!'); ");
instead of
$('#one').click( function() { alert('you clicked me!'); } );
Matt Kruse
--~--~-~--~~~---~--~-
94 matches
Mail list logo