Please am having this problem when the site is on example.com/upload_folder/web/ and I set the agreement url to be /upload_folder/web/ agreement
On edge says "Hmmm...can’t reach this page", on opera "This page isn’t working example.com redirected you too many times. ERR_TOO_MANY_REDIRECTS" and on chrome "This page isn’t working example.com redirected you too many times. Try clearing your cookies. ERR_TOO_MANY_REDIRECTS"
I have the redirect feature on cpanel actiavted, to redirect example.com/upload_folder/ to example.com/upload_folder/web since drupal actual files are in the folder "web"
When I use /agreement displays the existing agreement terms of use agrement on the site at https://example.com/terms-of-use-agreement/ which is not even related and has a totally different use terms.
Error log reports:
when the user tries to login "page not found 10/31/2019 - 03:12 /projectdin/web/terms-of-use"
when admin is saving the agreement page setting "php 10/31/2019 - 03:11 Warning: call_user_func_array() expects parameter 1 to…"
the full admin error prints:
Location https://example.com/upload_folder/web/admin/config/people/agreement/manage/term_of_use?destination=%2Fprojectdin%2Fweb%2Fadmin%2Fconfig%2Fpeople%2Fagreement
Referrer https://example.com/upload_folder/web/admin/config/people/agreement/manage/term_of_use?destination=/projectdin/web/admin/config/people/agreement
Warning: call_user_func_array() expects parameter 1 to be a valid callback, no array or string given in Drupal\Core\Form\FormValidator->doValidateForm() (line 282 of core/lib/Drupal/Core/Form/FormValidator.php).
Drupal\Core\Form\FormValidator->doValidateForm(Array, Object) (Line: 238)
Drupal\Core\Form\FormValidator->doValidateForm(Array, Object, 'agreement_form') (Line: 118)
Drupal\Core\Form\FormValidator->validateForm('agreement_form', Array, Object) (Line: 576)
Drupal\Core\Form\FormBuilder->processForm('agreement_form', Array, Object) (Line: 319)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 93)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 151)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 693)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'validatePath' not found or invalid function name in Drupal\Core\Form\FormValidator->doValidateForm() (line 282 of core/lib/Drupal/Core/Form/FormValidator.php).
Drupal\Core\Form\FormValidator->doValidateForm(Array, Object) (Line: 238)
Drupal\Core\Form\FormValidator->doValidateForm(Array, Object, 'agreement_form') (Line: 118)
Drupal\Core\Form\FormValidator->validateForm('agreement_form', Array, Object) (Line: 576)
Drupal\Core\Form\FormBuilder->processForm('agreement_form', Array, Object) (Line: 319)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 93)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 151)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 693)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)Any direction on this will be appreciated
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | interdiff-3091300-4-5.txt | 1.17 KB | mradcliffe |
| #5 | agreement-3091300-base_path-5.patch | 1.91 KB | mradcliffe |
| #4 | agreement-3091300-base_path-4.patch | 617 bytes | mradcliffe |
Comments
Comment #2
ojchris commentedComment #3
ojchris commentedComment #4
mradcliffeYes, I think this is a bug. It is expected that this would work when Drupal is installed in a sub-directory. I think if I concatenate the agreement path to the base path from the request, then that should resolve the issue.
Let's see if this passes tests, but could you try and apply the patch here to see if it resolves the issue?
Comment #5
mradcliffeFound a couple of issues including the validation issue @ojchris37 reported in the first comment.
Comment #6
ojchris commentedthank you for the follow up. Which of the patch to test? what to do with the txt file in #5?
Comment #7
mradcliffeUse the patch in #5. The text file is known as an interdiff. t shows the changes between 2 patch files. You can ignore this file.
Comment #8
mradcliffeWere you able to apply the patch in #5, and see if that worked for you, @ojchris37?
Comment #9
ojchris commented@mradcliffe the patch resolved it, works now BUT the tab http://sitemy.com/web/admin/config/people/agreement/agreements does not indicate what user has accepted the terms with a good marker, everything remains X.
Also where do I go to change the success text "Thank you for accepting our agreement" to something else. I wouldn't mind hard coded change in the interim
Comment #10
ojchris commentedThe marker indication is important I realize
Comment #11
ojchris commentedComment #13
mradcliffeThank you for confirming that the patch works and reporting the issue! I've committed to the development branch of Agreement 8.x-2.x-dev. I should be rolling an actual stable release shortly.
Also we usually create new or follow-up issues for unrelated bugs or feature requests. It helps to declutter and focus an issue. I created #3094948: Agreement Records view not displaying agreed checkmark to look into the Agreement Records page not showing check marks. However I have not been able to reproduce this manually so far.
A Agreement success, confirmation and revocation text can be configured by going to Administration > Configuration > People > Agreements, clicking the Edit button for the agreement you wish to configure, and then these are listed underneath the "Settings" fieldset. This is collapsed by default for me when using the Claro theme.