[Proto-Scripty] Encoding problem with new Ajax.Request

2008-10-21 Thread Uzm
I've a small problem with new Ajax.Request. Actually, there isn't really a problem with the function itself, but with encoding. Here is my code: function getData() { new Ajax.Request('chat.php', { method: 'post', encoding: 'windows-1251', parameters: userId= + userId + msgtime= + msgtime,

[Proto-Scripty] IE6 Error

2008-10-21 Thread jschank
Hello, I'm using protoype.js in a rails application. The application works fine on Safari, FireFox (both windows and mac), however, when I load my app in IE6, I get an Error: Object doesn't support this property or method pop up. When I choose to debug that in the script debugger, I see that

[Proto-Scripty] Limit Drag and Drop on browser screen

2008-10-21 Thread Saiful Amri
Dear All... How to make drag and drop an element but it is not dragged over limit height and width browser size, it likes drag and drop on gmail's windows modal message... Thanks, Best Regards Saiful Amri --~--~-~--~~~---~--~~ You received this message because

[Proto-Scripty] Re: IE6 Error

2008-10-21 Thread T.J. Crowder
Hi John, This usually happens when you try to call a Prototype method on an Element instance that hasn't been extended [passed through $()]. On almost everything but IE, that's fine, but on IE you have to be sure to pass the instance through $(). There's an article on this in the new

[Proto-Scripty] Re: Encoding problem with new Ajax.Request

2008-10-21 Thread Saiful Amri
Dear... try using msgtime=+encodeURIComponent(msgtime) I think it does work, thanks Saiful Amri On Tue, Oct 21, 2008 at 1:12 AM, Uzm [EMAIL PROTECTED] wrote: I've a small problem with new Ajax.Request. Actually, there isn't really a problem with the function itself, but with

[Proto-Scripty] Re: Help needed

2008-10-21 Thread jason maina
[code] parent page ul id=tablist liSome text/li /ul child page(loaded in a div) ul id=tablist liChild some text/li /ul [/code] [css] #tablist{ padding:3px 0; margin-left:0; margin-bottom:0; margin-top:0.1em; font:bold 12px Verdana, Arial, Helvetica, sans-serif;

[Proto-Scripty] Re: Form field validation and masking

2008-10-21 Thread [EMAIL PROTECTED]
Thanks, I found what I was looking for form validation. Any suggestion for masking? Tom On 20 Říj, 17:52, kangax [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: Hi, do you know some prototypejs based alternative to fValidator (http:// zendold.lojcomm.com.br/fvalidator/) and iMask

[Proto-Scripty] Re: Encoding problem with new Ajax.Request

2008-10-21 Thread Baglan
If that's the only problem, why not deal with it on the server. I see that you're using PHP. That would be as easy as: $msgtime = str_replace('%3A',':',$_REQUEST['msgtime']); Considering that message is received by the server-side script almost instantly, you could forgo sending the time at all

[Proto-Scripty] Re: I use Updater with a webpage in different folder. I can't see images

2008-10-21 Thread Justin Perkins
Why don't you use paths to your images that are relative to the webroot instead of the directory they are in so that they work no matter where they are? The convention is to have a directory in your webroot called images and all your imagery goes in there. /images/c1/foo.jpg /images/c2/bar.jpg

[Proto-Scripty] Re: I use Updater with a webpage in different folder. I can't see images

2008-10-21 Thread Brian Williams
My Advice? Forget ajax and use an iframe or heck, even standard frames. In my opinion, you are trying to use a screw driver when you should be using a hammer. On Tue, Oct 21, 2008 at 1:36 PM, F. Ruiz [EMAIL PROTECTED] wrote: Thank you for your answer, but this is not valid for me. I'll

[Proto-Scripty] Re: PeriodicalExecuter vs. Ajax.PeriodicalUpdater: use cases and advice?

2008-10-21 Thread Baglan
I would imagine that Ajax.PeriodicalUpdater was conceived with a different intention in mind - something like showing online/offline status, maybe. All the chat-like examples I've seen (primarily for the RoR), used javascript generated on the server to re-start updating and sessions to keep track

[Proto-Scripty] trouble with delayedobserver

2008-10-21 Thread ecb
Here's the code. It's simple enough: blockquote new Form.Element.DelayedObserver( 'inputfield', .50, function() { simplefunction(); }) function simplefunction() { alert(here I am); } /blockquote The problem I'm having is that simplefunction is being called twice. Best Adam

[Proto-Scripty] Re: PeriodicalExecuter vs. Ajax.PeriodicalUpdater: use cases and advice?

2008-10-21 Thread Justin Perkins
Why aren't you just using the Ajax.PeriodicalUpdater, which supports the decay option? var poller = new Ajax.PeriodicalUpdater('some-element-id', '/foo/bar', {decay:10}); Also, if you pass an empty string as the first parameter, then you can pass pure JavaScript to be executed as opposed to

[Proto-Scripty] Re: IE6 Error

2008-10-21 Thread jschank
Hi T.J. Thanks for the reply. I've read the docs at the links you mention, but I'm still stuck. The problem (with me anyway) is that I'm a JavaScript noob, and the JavaScript calls that exist in my app get there via Rails. So I'm having a problem even finding the offending function. It seems to

[Proto-Scripty] Re: IE6 Error

2008-10-21 Thread jschank
T.J. I thought I'd add the clip of the only JavaScript code that I'm responsible for: (in case the problem is therein) $(document).ready(function() { // Build tabs... $('#tabs ul').tabs({ fx: { height: 'toggle', opacity: 'toggle' } }); // Animate the hiding of any

[Proto-Scripty] Re: IE6 Error

2008-10-21 Thread jschank
T.J. I did the remove of my JavaScript, and I still get the error. So it must be a problem with Rails or one of the plugins. I'll poke around on their boards and fora to see if they have mention of this. Thanks, John --~--~-~--~~~---~--~~ You received this

[Proto-Scripty] Re: PeriodicalExecuter vs. Ajax.PeriodicalUpdater: use cases and advice?

2008-10-21 Thread Justin Perkins
Well since the Ajax requests in Prototype will auto-eval the response, you can modify the page without updating just one div. It's the route I take most of the time. Say you set it up like this: new Ajax.PeriodicalUpdater('', '/some/url'); Then the response from /some/url could be:

[Proto-Scripty] Re: IE6 Error

2008-10-21 Thread jschank
Ok, I've solved this... Apparently, the problem stems from trying to use both prototype AND jQuery on the same page. I thought I needed prototype for active_scaffold (AS does require prototype) but I was able to remove both active_scaffold and prototype from my app. Now I no longer get the