Article View: pl.comp.lang.javascript
Article #50574Re: Wlasny plugin jQuery i this
From: Gadjo Delhi
Date: Sat, 19 Feb 2011 10:28
Date: Sat, 19 Feb 2011 10:28
16 lines
1591 bytes
1591 bytes
On 16 Lut, 20:23, "aaaa" <a...@aaaaaaaaaaaaaaaaaaa.com> wrote:
> if (settings.onChange != null)
> {
> settings.onChange(a, b, c);
> }
>
> I teraz (this) z $(this).val(a+b+c); odnosi sie do mojego pluginu, a nie do
> pola (.piesek).
> Mozna jakims trikiem zrobic, zeby odnosilo sie do .piesek?
coś w tym stylu może zadziała albo przynajmniej naprowadzi na właściwy
trop:
$(this).each(function () {
settings.onChange.call(this, a, b, c);
});
Technical Details
Message-ID:
<e9723f6a-1ca3-4a36-b92f-fb27861d4f1e@m13g2000yqb.googlegroups.com>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!newsfeed.pionier.net.pl!news.glorb.com!postnews.google.com!m13g2000yqb.googlegroups.com!not-for-mailReferences:
<4d5c2420$0$2459$65785112@news.neostrada.pl>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!newsfeed.pionier.net.pl!news.glorb.com!postnews.google.com!m13g2000yqb.googlegroups.com!not-for-mail From: Gadjo Delhi <jkarczm@gmail.com> Newsgroups: pl.comp.lang.javascript Subject: Re: Wlasny plugin jQuery i this Date: Sat, 19 Feb 2011 02:28:00 -0800 (PST) Organization: http://groups.google.com Lines: 18 Message-ID: <e9723f6a-1ca3-4a36-b92f-fb27861d4f1e@m13g2000yqb.googlegroups.com> References: <4d5c2420$0$2459$65785112@news.neostrada.pl> NNTP-Posting-Host: 77.222.225.69 Mime-Version: 1.0 X-Trace: posting.google.com 1298111280 23805 127.0.0.1 (19 Feb 2011 10:28:00 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Sat, 19 Feb 2011 10:28:00 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: m13g2000yqb.googlegroups.com; posting-host=77.222.225.69; posting-account=ukSJYQoAAABD2vgYb1rKe_GwS1cpVBbH User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b12pre) Gecko/20110218 Firefox/4.0b12pre,gzip(gfe) Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit