hey.guys..i met a problem with the function onBeforeWrite () on Page type.
i want to execute a function once click the [SAVE]or[SAVE and Publish] Function..
but when i put the onBeforeWrite() into Page Type. In the backend, when i click the save button, it shows [Javascript Parse Error],
Where do you think the problem will be?!
We've moved the forum!
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
It could be your Debug::show() causing the issue. If you have Firebug enabled you can see what the error returned is by looking at the console panel -> response tab.
Thanks, willr, the problem is i didnt click the Php extension [clurt]. but i am using the method in my code area...
The firebug do helps a lot.. thanks for your suggestion.
Hi I am trying to use the same onBeforeWrite for Keywords/Description as you are using, is this working for you?
I am finding it is not adding any keywords or description
Cheers