Skip Navigation

[Resolved] CRED post-form not working reliable

This support ticket is created 7 years, 2 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 42 replies, has 2 voices.

Last updated by Christian Cox 7 years, 1 month ago.

Assisted by: Christian Cox.

Author
Posts
#494362

Hi Christian! No news from my end. On weekend it was really quiet on the webserver ...

In GoogleAnalytics there is one click on the submit-button for yesterday, but no registered success-message-page. The analytics user-explorer shows the click on the button, and then a page with _tt-parameter, but without the _success-message-parameter. Wordfence found a human user from Czechia for this action. But we didn't get a notification, no new post in the database. No logs in the error-logs, and in mail-error-log always the same notification - again and again - one with a similar timestamp than the form-transmission - last one about an hour ago:

[26-Feb-2017 16:59:57 UTC] PHP Notice:  Trying to get property of non-object in /myserver/wp-content/plugins/cred-frontend-editor/library/toolset/cred/embedded/classes/common/cred_functions.php on line 72

I don't know what this is all about. Perhaps the Czech user didn't fill out the form correctly and closed the window after false validation? That would explain why there is no success-message ... So perhaps all is working fine now.

But the php-notice bothers me a bit. Although I found out, that this notice shows up, when sending a false validated form. So perhaps this is "normal"? And it's always called when bots do arrive on the form? ... What do you think?

#494721

Do you have access to POST information and headers for any of the requests that generate that PHP notice? I would like to pass that information to our developers so they can see how the notice is generated.

#494762

I'm sorry, I don't know where to have a look for that infos?

As far as I can say, if the cred-form is shown, a CRED-auto-draft is created in the database. And if you don't fill in any of the fields and you send an empty form, the error occurs (and the validation messages appear on frontend). Does that help you?

#494776

I'm afraid it doesn't help me much, because I cannot replicate the notice locally. When I follow the steps you gave, I don't see any PHP notices generated. Is there a specific form or page I should go to?

You said "if you don't fill in any of the fields and you send an empty form, the error occurs (and the validation messages appear on frontend)."

I'm not sure I understand how this would happen. Which validation messages are you referring to? JavaScript front-end validation errors are shown if you attempt to submit an empty form, but that also means Javascript prevented the form from submitting. So no PHP notice could be generated in this case - it's all front-end validation.

If I disable JavaScript, I don't see any validation messages because nothing prevents the form from submitting successfully.

#494792

If you have my credentials, you can test it on my website:

Log in and go to > Mail Bank > Error Logs
Last log is from a few minutes ago 19:49:40 UTC (cause I tried the steps just now).
In another browser don't log in, go to hidden link.
Click on the enquiry-button beside a room - the CRED-form opens in the modal-window.
Don't fill in anything, just submit the form (I know, it's not submitted, because of the false validation).
Now switch back to the backend in the other browser.
Refresh the Mail Bank Error Logs.
So there is a new php-notice with "property of non-object in cred_functions.php on line 72.

If you do so in your local-machine, isn't there any php-notice?

#494824

No, there is no similar PHP notice created on my local environment. Also, I just tested on your environment and no new notice is created when I submit the form - it appears the new notice is created whenever I load or refresh the page. It seems to have nothing to do with form submission...can you confirm?

I'll reach out to our developers and see if they have any insight about what's happening in this function, and if there's anything specific we can check. It appears to be part of the process that converts an Auto-Draft into an actual post, which is definitely pertinent to the problems you've been experiencing.

#495011

Oh, you are right: It isn't the form-submission which is throwing the php-notice. It's the page-load. And this happens on all pages, except my homepage. Strange. There should be the exact same functions for CRED than on all other pages ...

One good message from my side: Every logged CRED-action in GoogleAnalytics for the last days worked fine in WordPress. The new posts are saved and the confirmation-e-mails were sent. So for now it seams as if the CRED-update (or any of our other changes) solved my issues. Hopefully! I'll keep observing.

#495141

Okay thanks, let's continue to observe and follow up periodically. I'll let you know if the developers have any insight for me on the notice.

#495852

Hi, just wanted to give you a quick update. Today I had a chance to test your site locally while running PHP 5.4.45. I'm not seeing the same notice you are experiencing, so I'm a bit stumped. Unfortunately I'm not able to find the same MySQL version you are running on their community archives. Let's keep in touch though, especially if you find any dropped CRED entries.

#496022

Okay, Christian, so you mean, that the PHP-notice could be a problem of my older PHP- and mySQL-versions? That could make sense, yes ... If your developers have another clue for me to get rid of the php-notice, that would be fine.

But the last days there are no dropped CRED entries. Anything seems to work fine now. Hopefully ...

#496311

That's right, I was thinking that your PHP and MySQL versions could be contributing. I will let you know if I hear anything else from our develolpers.

#497384

Just writing, because the cleanup-robot wants to close the thread.
Nothing new from my side. As I can tell, everything's alright now with CRED ... Waiting for the developer-reply ...

#497566

Nothing from our developers on the notice, we have been unable to replicate it on our side. We are unable to install the version of MySQL your host is using, as it is no longer available in the MySQL archives.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.