Batch API does not use ajax
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
DEPRECATED Pantheon |
Triaged
|
High
|
Greg Coit |
Bug Description
When running code in Pressflow using Drupal's Batch API, I notice that it refuses to run each batch as an ajax call in the background. Instead it does an entire page refresh on each new batch. After some investigation, it seems the Batch API code is looking for a cookie called has_js which was is set in drupal.js in Drupal, but has been removed from Pressflow. The cookie should either be set, or the batch.inc file modified to use javascript regardless of the cookie being set.
Here is the code in drupal.js that is missing from Pressflow:
// 'js enabled' cookie
document.cookie = 'has_js=1; path=/';
You can find the code that looks for this cookie in the includes/batch.inc file inside the _batch_start() function.
Related branches
- Pressflow Administrators: Pending requested
-
Diff: 57 lines (+19/-5)3 files modifiedincludes/common.inc (+7/-0)
misc/drupal.js (+7/-5)
misc/jsenabled.js (+5/-0)
Changed in pantheon: | |
importance: | Undecided → High |
assignee: | nobody → Greg Coit (gregcoit) |
Changed in pressflow: | |
status: | Confirmed → Triaged |
We dropped it intentionally, but there are probably better solutions in general to support downstream caching proxies.