Welcome Guest, Not a member yet? Register   Sign In
Using models with Scriptaculous's AJAX
#4

[eluser]adaykin[/eluser]
What do you mean by index.php shortcut thing?

I am able to make ajax posts with prototype fine, here's an example of something that I am using in my code:

Code:
new Ajax.Request('http://localhost/AskMary/pageeditor/savepage', {
          method: 'post',
          parameters: { section: $(form['content']).getValue(), content: tinyMCE.get('pageValue').getContent() },
        onSuccess: function(transport) {
            var response = transport.responseText;
            $('updateMsg').update(response);
            $('updateMsg').show();
            new Effect.Highlight('updateMsg');
        },
        onException: showError
    });

So the controller name is pageeditor, and I am calling the savepage function inside of it.

http://localhost/AskMary is my base url.

I am using mod_rewrite, as described in the wiki


Messages In This Thread
Using models with Scriptaculous's AJAX - by El Forum - 08-19-2009, 07:07 PM
Using models with Scriptaculous's AJAX - by El Forum - 08-19-2009, 07:25 PM
Using models with Scriptaculous's AJAX - by El Forum - 08-19-2009, 10:55 PM
Using models with Scriptaculous's AJAX - by El Forum - 08-19-2009, 11:00 PM
Using models with Scriptaculous's AJAX - by El Forum - 08-20-2009, 01:15 AM
Using models with Scriptaculous's AJAX - by El Forum - 08-20-2009, 03:15 AM



Theme © iAndrew 2016 - Forum software by © MyBB