[Proto-Scripty] Re: accessing to fields in class method

2009-02-06 Thread marioosh
On 6 Lut, 12:09, "T.J. Crowder" wrote: > You need to bind your onSuccess function to 'this', more here: > Thanks very much :) i did it and works good --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Prototype & scrip

[Proto-Scripty] accessing to fields in class method

2009-02-06 Thread marioosh
I have Channel class with element field, but i don't know how in Ajax.Updater get to this field. Is this possible without passing another parameters to method updateById ? var Channel = Class.create({ initialize: function(element) { this.element = $(element); }, updateById: function (i

[Proto-Scripty] Calling function passed as parameter

2009-02-17 Thread marioosh
I have a problem with calling function passed as parameter in class definition. I get error when i call fun(). How can i correct this ? var Slider = Class.create({ initialize: function (elContainer) { this.elContainer = elContainer; if($(this.elContainer).g

[Proto-Scripty] Re: Calling function passed as parameter

2009-02-17 Thread marioosh
On 17 Lut, 12:14, "T.J. Crowder" wrote: > Hi, > > What's the error? > -- Error: Cannot convert undefined or null to Object Slider class is a base class and doit() method is redefined in subclasses. I see that calling fun() works, but i get error in redefined method doit(). Redefinition here:

[Proto-Scripty] Re: Calling function passed as parameter

2009-02-17 Thread marioosh
On 17 Lut, 13:30, david wrote: > Hi craig, > > I've tested the following code, and it works in FF3 !! > Test this (http://pastie.org/391632) - it does not work in FF: http://www.w3.org/1999/xhtml";>

[Proto-Scripty] Re: Calling function passed as parameter

2009-02-17 Thread marioosh
I see...yes, that works! thanks very much!! :D ps: sorry for my english ;) On 17 Lut, 18:41, david wrote: > Hi marioosh, > > TJ is right, when you call the doit function via fun, the 'this' value > is equal to Object window. > So you need a little more bindin

[Proto-Scripty] How to fire 'click' on element ?

2009-02-20 Thread marioosh
hello;) i have code like below. I need to simulate click on #log_in button when i press enter on input fields. My code doesnt work. Why ? What can i do to make this works ? [cut] $(this.elContainer).down('#log_in').observe('click', function() {

[Proto-Scripty] Ajax.Request and php global variable

2009-03-03 Thread marioosh
I have a code as below: test1.php: -- test1.js: -- Event.observe(document,'dom:loaded', function() { new Ajax.Updater('debug','test2.php', { onComplete: function() { } }); }); test2.php

[Proto-Scripty] Re: Ajax.Request and php global variable

2009-03-03 Thread marioosh
And how about $var is an php object of some class ? $var = new Foo(); Is possible to pass $var by: parameters : {var: '', } ?? On 3 Mar, 14:10, "Alex Mcauley" wrote: > Or if you mean passing the contents of the php variable $var to 'test2.php' > then you can do so like this > > --> in your

[Proto-Scripty] Re: Ajax.Request and php global variable

2009-03-03 Thread marioosh
Explaining [sorry for my english ;)]: I need $var that is object of some class, and $var will point to the same object in test1.php, test2.php, test3.php ... where: test1.php, test2.php ... are scripts that will be used in new Ajax.Request(... I need something like above. --~--~-~--~---

[Proto-Scripty] Finding tags inside CDATA section

2009-04-03 Thread marioosh
I'm using javascript to hide images like below: $('mybody').select('img').each(function(elem) { elem.hide(); } How to do this when img tags are insinde CDATA section ? select method didn't found img tags inside CDATA :( --~--~-~--~~~---~--~~ You received this me

[Proto-Scripty] Changing href in onclick function

2009-05-15 Thread marioosh
I have . I want to do that (sorry for my poor english): When user click ph, i need to set href to some usable address (by sending request Ajax.Request) and fire onclick once again. I've done like below, but not works good :/ Please help... how to do this better ? $('ph').