Closed (outdated)
Project:
Drupal core
Version:
7.x-dev
Component:
ajax system
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
7 Nov 2011 at 23:02 UTC
Updated:
6 Apr 2014 at 07:13 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
rfayI've definitely never tried that. Multistep forms I've seen often, but don't think I've done AJAX.
Comment #2
dobe commentedI was just trying to do the same thing and I am unable to get this to work. I nearly replicated the ajax_example but nothing gets done.
-Jesse
Comment #3
dobe commentedUpdating the version as I am using latest version of Drupal
Comment #4
burkeker commentedSame here. I've replicated the ajax_example and assigned it to hook_install_tasks... the throbber shows but no results returned.
Comment #5
pirog commentedThe error that is produced here is
"Invalid form POST data." which seems to happen when Drupal is unable to load the form data from the cache.
Comment #6
pirog commentedSo for some reason drupal cannot get or set cached forms during the install profile workflow. I do not know why this is and can't investigate further. I've attached a patch which seems to provide a decent workaround and it would be great to get some feedback as this is definitely not my area of expertise.
Comment #7
pirog commentedWhoops! Here is a patch without the weird color characters.
Comment #8
pirog commentedNoticed this doesn't play nice with ajax_base_page_theme
Comment #9
andrew_mallis commented+1
Comment #10
gromani14 commented+1
Comment #11
Matias Andreatta commented+1
Comment #12
sjbassett commented+1
Comment #13
dariogcode commented+1
Comment #14
mrynearson commented+1
Comment #15
laceysanderson commentedI also can't get AJAX to work on an installation profile form. I have tested it using the Examples Modules forms exactly (not even reproduced, just used that function while defining the installation steps) and can't get it to work even with the supplied patch.
I'm attaching my installation profile (enables the Devel & Examples module and provides the tasks using the Example modules Ajax Example Forms) with drush makefile to aid in debugging of this issue.
To reproduce simply download the installation profile attached and uncompress it in your [drupal root]/profiles directory. Also download the Examples and Devel modules. Then when installing Drupal select profile=ajax_testing_profile. This allows you to click through each of the Examples Module Ajax forms as though they were installation tasks.
Comment #16
pirog commentedShould likely rework this to make use of drupal_installation_attempted()
Comment #17
pirog commentedComment #18
pirog commentedActually. drupal_installation_attempted() only returns true when on install.php. However this ajax request is going through index.php so drupal_installation_attempted() will always be false. We could update drupal_installation_attempted() to return true for ajax install events as well and then use that... or we could keep what we have in the patch above.
Comment #19
pirog commentedI like this less because i'm not sure how this will impact other usage of drupal_installation_attempted() but here it is for discussion