By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
460,046 Members | 1,350 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 460,046 IT Pros & Developers. It's quick & easy.

Ajax.Updater (prototype.js) and updating a div with a php function

P: n/a
Hello Everyone,

altought by English is not so ggod, I try to explain my problem...

With the prototype ajax.updater it's possible to update a div trough
a given url.
Is there any possibility to update it with a function?

Wenn cklicking on a link, the layer 'mainContent' show be updated with
the function Shop::cart()

Thanks for your answer.

Nov 1 '07 #1
Share this Question
Share on Google+
2 Replies


P: n/a
On Nov 1, 1:44 pm, chrissi <cschl...@gmail.comwrote:
Hello Everyone,

altought by English is not so ggod, I try to explain my problem...

With the prototype ajax.updater it's possible to update a div trough
a given url.
Is there any possibility to update it with a function?

Wenn cklicking on a link, the layer 'mainContent' show be updated with
the function Shop::cart()
For questions specific to Prototype.js you are more likely to have
success on the Prototype group

http://groups.google.com/group/rubyonrails-spinoffs

The regular contributors in comp.lang.javascript generally dislike
Prototype.js for many good reasons. If you can avoid using it and use
almost any other library you will be making a better choice. There is
currently a long thread in comp.lang.javascript about JavaScript
libraries. It is a very sensitive issue around here.

Peter

Nov 1 '07 #2

P: n/a
chrissi wrote:
Hello Everyone,

altought by English is not so ggod, I try to explain my problem...

With the prototype ajax.updater it's possible to update a div trough
a given url.
Is there any possibility to update it with a function?

Wenn cklicking on a link, the layer 'mainContent' show be updated with
the function Shop::cart()

Thanks for your answer.

First of all, Shop::cart() is not a javascript function. So what are
you talking about? It's probably a server-side function, in which case
Ajax.updater is exactly what you want (if you insist upon using
Prototype). You just need to determine the URL that maps to
Shop::cart(), and if there isn't one, make one. If you need help
figuring out how to do this, it would be a better question for a group
about your server-side language.

Jeremy
Nov 2 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.