1

On my civievent, people get the error message " could not find valid value for id" on wordpress 4.8.1

2
  • I'd like to help you, but I'll need some more information. What are the specific steps that led to this error? Viewing the event page? Registering for the event? Can you provide a screenshot? Does everyone get the error? Are you able to reproduce it consistently? Can you post a link to the event page so others can look at it? What is working? Other events? Are the any recent changes you're aware of that could help us diagnose the problem?
    – Sean
    Commented Sep 1, 2017 at 23:34
  • In addition to Sean's questions - the most helpful info you can give is the debugging info. In CiviCRM, go to Administer menu > System Settings > Debugging and Error Handling, select "Yes" to both "Enable Debugging" and "Display Backtrace", and press "Save". Repeat the steps that caused your error, and you'll see much a more detailed error. Please update this question with the expanded error and backtrace - and don't forget to disable debug/backtrace when you're done! Commented Sep 2, 2017 at 16:08

2 Answers 2

1

I had this problem intermittently for some time when embedding event registration forms using a Wordpress shortcode. It has to do with page caching. CiviCRM parses the shortcode to capture the event ID and adds the id value to the global $_GET object. If the page is loaded from cache (usually when the back/forward button is pressed) the code that parses the shortcode does not run, and the event ID is not added to $_GET.

I was able to fix this issue by making a page cache exception with the caching plugin I'm using.

I think this behavior is essentially a bug and CiviCRM should output a hidden form variable with the event ID so that it still gets passed to the "Thank You" page if the registration form is loaded from cache.

0
0

I'm getting the same for when participants confirm the registration to an event. Bug stack:

CRM_Core_Exception: Could not find valid value for id in /var/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/StateMachine/Registration.php on line 27

0   CRM_Utils_Request::retrieve('id', 'Positive', Object(CRM_Event_Controller_Registration), true)  /var/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/StateMachine/Registration.php:27
1   CRM_Event_StateMachine_Registration->__construct(Object(CRM_Event_Controller_Registration), true)   /var/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/Controller/Registration.php:27
2   CRM_Event_Controller_Registration->__construct('Event Registrati…', true, 'null', null, 'false')    /var/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:314
3   CRM_Core_Invoke::runItem(Array) /var/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:69
4   CRM_Core_Invoke::_invoke(Array) /var/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:36
5   CRM_Core_Invoke::invoke(Array)  /var/www/wordpress/wp-content/plugins/civicrm/civicrm.php:1199
6   CiviCRM_For_WordPress->invoke() /var/www/wordpress/wp-content/plugins/civicrm/includes/civicrm.basepage.php:380
7   CiviCRM_For_WordPress_Basepage->basepage_handler(Object(WP))    /var/www/wordpress/wp-includes/class-wp-hook.php:307
8   WP_Hook->apply_filters(null, Array) /var/www/wordpress/wp-includes/class-wp-hook.php:331
9   WP_Hook->do_action(Array)   /var/www/wordpress/wp-includes/plugin.php:522
10  do_action_ref_array('wp', Array)    /var/www/wordpress/wp-includes/class-wp.php:771
11  WP->main('')    /var/www/wordpress/wp-includes/functions.php:1310
12  wp()    /var/www/wordpress/wp-blog-header.php:16
13  require('/var/www/wordpre…')    /var/www/wordpress/index.php:17
14  {main}

And the error that the users see is Sorry, due to an error, we are unable to fulfill your request at the moment. You may want to contact your administrator or service provider with more details about what action you were performing when this occurred. Could not find valid value for id

3
  • Steve - this isn't an answer to the question. It could go as a comment to the question, but given how old the question is and that you are likely tobe using different versions of CiviCRM and WordPress and there wasn't enough info in the original question, I would delete this and start again.
    – Mick Kahn
    Commented Mar 25, 2022 at 14:37
  • could be Steve's lack of reputation. Steve, you did same on another ticket. Best to create some new tickets and reference the old ones. that will get you some more points so you should then be able to Comment
    – petednz - fuzion
    Commented Mar 25, 2022 at 21:38
  • Got it, thank you. I'm not sure how StackExchange works. I'll start a new ticket.
    – Steve
    Commented Mar 26, 2022 at 11:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.