Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Steps to reproduce:
- Install Ctools and Panels, latest versions
- Create a Panel using
Node edit form: node ID
context for an argument - Add some field editing panes to that panel and node form submit buttons
- Save the panel and edit some node with the just defined panel form
- On save, there is WSOD and PHP fatal error occurs:
PHP Fatal error: Call to undefined function bootstrap_form_process() in mydirectory/includes/form.inc on line 1850
I'm using latest version of Bootstrap. It works fine with Bartik theme. Is this somehow related to https://www.drupal.org/node/2156371?
I tried to create custom module with:
function bootfix_init() {
include_once(drupal_get_path('theme', 'bootstrap') . '/includes/process.inc');
}
but it didn't help.
EDIT: The strange thing is that this error doesn't happen, if I enable and override default node_edit page. Export of both pages is enclosed.
Comment | File | Size | Author |
---|---|---|---|
#2 | ctools_pages_export.txt | 7.99 KB | milos.kroulik |
Comments
Comment #2
milos.kroulik CreditAttribution: milos.kroulik commentedComment #3
clemens.tolboomThis is probably a duplicate of #2156371: Fatal error: Call to undefined function _bootstrap_process_element() which is closed as they think it's a core issue. I close this as #2156371: Fatal error: Call to undefined function _bootstrap_process_element() has more information. Feel free to reopen but better comment on the other issue.
Comment #4
MartijnBraam CreditAttribution: MartijnBraam as a volunteer commentedI've just stumbled across this issue and it's not in all cases related to the other issue.
This exact error can also happen if you have a drupal form with a lot of fields. In my case I have around 150 fields on my edit page because of a gallery with the paragraphs module. If you cross max_input_vars limitation in php you get the error in this issue in addition to this one:
If you raise the max_input_vars limit in php then the bootstrap_form_process() error is also solved. I haven't looked under the hood to check why this is happening but i guess that php corrupts the form when you have to many fields.
Comment #5
chobart CreditAttribution: chobart commentedAs wrote MartijnBraam increasing max_input_vars in php.ini solves the problem.
Comment #6
markhalliwellIt is, in fact, a duplicate of the related issue aforementioned.
Comment #7
tarekdj CreditAttribution: tarekdj as a volunteer commentedFor the record : I fixed it using this little hack (You need to patch bootstrap theme)
https://gist.github.com/tarekdj/d924005620d4b942f4e3bc1fe8e28c2b
Comment #8
jienckebd CreditAttribution: jienckebd as a volunteer commentedThis is a duplicate of https://www.drupal.org/node/2156371 . The Ajax updates from Panels are causing the same problem as the Ajax updates in that issue.
As markcarver pointed out several times in that issue, this is not an issue with the Bootstrap theme. But you can add the below to one of your modules as a bandaid to keep your site running.
This will restore the admin theme in the Ajax callback. This worked for me, but I imagine it could have a negative effect in some cases for Ajax requests not within the admin theme. But it's working okay for my site.
Comment #9
Stanislav_B CreditAttribution: Stanislav_B commentedTo fix this issue in my project i have used solution similar to provided in #8, but with little changes:
Comment #10
Helice CreditAttribution: Helice commented#4 solved my problem. Thank you!
Comment #11
Anonymous (not verified) CreditAttribution: Anonymous as a volunteer commented#8 fixed the issue for me... I didn't have to add the patch to bootstrap theme just create a module as its said there. Thank you !!!
Comment #12
markhalliwellNeither #8 nor #9 should be needed.
That is the whole point behind why drupal_theme_initialize() adds the current page's theme key to
ajaxPageState
in Drupal settings and whysystem/ajax
uses the theme callback ajax_base_page_theme() in system_menu().Suffice it to say, if a contrib module is borking because of the above, it sounds like it IS NOT USING the
system/ajax
callback or core's Ajax API properly in the first place.If it's using its own AJAX callback path, then it will need to either Implement the theme callback
ajax_base_page_theme()
in it's menu hook definition or something that essentially mimics that theme callback so it returns the proper theme.Comment #13
arne_hortell CreditAttribution: arne_hortell commented#4 worked for me, perfect result.
Comment #14
eaajithe CreditAttribution: eaajithe commented#4 worked for me
I checked my php.ini
; How many GET/POST/COOKIE input variables may be accepted
max_input_vars = 2500
then increased it up 10000
; How many GET/POST/COOKIE input variables may be accepted
max_input_vars = 10000
Restarted Apache. Error Gone
Comment #15
Bobby Endarr Ramdin CreditAttribution: Bobby Endarr Ramdin commentedThis error had me scratching my head.
max_input_vars is already set to 10000 in php info reading off the server.
It happened only when logged in as admin and not using bootstrap theme, so I've read try stark, seven bartik they didn't work.
When I set the admin default to bootstrap the error disappears..
So using Bootstrap for both anonymous and admin worked for me /// Drupal 7
Comment #16
nugten CreditAttribution: nugten commented#8 worked for me. Thank you very much!!
(code copied from comment #8)
Comment #17
philsward CreditAttribution: philsward commentedSince the "duplicate" is locked, I'll throw out over here that max_input_vars = 1500 worked for me.
For anyone who increases that value and it doesn't work, make sure the phpinfo file shows that the value has been updated. Some folks say that increasing it to 2000 worked for them.
MAKE SURE YOU RESTART APACHE. I increased the value using the cPanel EA4 PHP INI Editor, saved it and still ended up having to restart apache. Don't assume your system has properly updated the value if you're using a GUI editor. Check and make sure it has updated.
Comment #18
nrashok CreditAttribution: nrashok as a volunteer and commented#4 solved my problem. Thanks a ton
Comment #19
samhaldia CreditAttribution: samhaldia as a volunteer and commented#4 Solves this issue for me as well.
Comment #20
DuneBL#4 solve my day
Comment #21
trudog CreditAttribution: trudog commentedNone of the solutions above worked for me. It turned out that, in my case, it was a ThemeKey issue. I was able to fix the error by adding the theme as a "safe theme" in ThemeKey ajax settings.
Comment #22
miguelbraga CreditAttribution: miguelbraga as a volunteer commentedHi trudog, what is this solution you are suggesting? I'm not a developer and I'm facing the same problem with adminimal.