Create my own "Update" button?

I think this is an easy answer for someone. I need to create my own button to “Save” or “Update” the form I am on… I want it to do other things besides just save the form, that’s why I need it.
How do I do this?
Thanks!

PS. I would like it to be a PHP button type, so I can do some database stuff when clicked.

That’s what the events are for.

Put all your “special” PHP stuff in onBeforeInsert and / or onAfterInsert and they will get run using standard Update button.

onBeforeUpdate and / or onAfterUpdate

Great to use that events when we press update :slight_smile:
But how to execute update from macro ? i am that dumb or this is tricky ? :slight_smile:
I mean - prepare my own button / a hreff then use macro to execute scriptcase update procedure

Why you need thath when you can use events?

[QUOTE=info@eat.pl;34901]Great to use that events when we press update :slight_smile:
But how to execute update from macro ? i am that dumb or this is tricky ? :slight_smile:
I mean - prepare my own button / a hreff then use macro to execute scriptcase update procedure[/QUOTE]

If you know how to break the php processing in the editor and recreate it, you can do pretty much everything, the limit is your imagination and skills to improvise with what you have.
However, its tricky and if you don’t know where to go you’ll just break your app, so, if you’re a begginer I suggest you try to make it works using the events.

Hope you figure it out.