How call a method php from a button javascript

Hi, i have a form and i need when a user click on a button type javascript, it call a method php and return a value.
thanks you…
Does exists a macro in sc for that? or How can i do it?

Is possible do it? does exits a macro SC for this case?

No afaik there’s no macro for that. In fact what you are trying to do is just a standard ajax event. You click on a javascript button, and then you need to communicate to the server and get a value back. Should be doable not not with the standard scriptcase components. But I’m not a javascript guru so if it’s possible then someone else might react.

Ok. Albert Thanks you. I will test others options with javacript and ajax.

Hi,

I used workaround for it:

  1. Try to create blank application with yours PHP code with return value at the end (e.g. as [var_global_value]) (out)
  2. in JS code: 2a) send header to: yours_blank_app_http_path, 2b) {value} = [var_global_value] (in)

daretzki