Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
php like $_POST['submit'] on comments form
Hi folks,
All is in the title : do you know (I think you know :) how to test within <txp:php> tags the submit comments event?
Tanks for your help.
Cheers,
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline
Re: php like $_POST['submit'] on comments form
if (gps('parentid') && gps('submit')) {
// Comment posted
}
This condition is true when the comment is previewed or posted.
You can also create a callback function attached to the “comment.save” event. This event is fired before the comment is saved (not fired on preview).
Offline
Re: php like $_POST['submit'] on comments form
Hi Juanjo :)
Thanks lot for you help : it works perfectly!
Best regards,
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline