Comment 9 for bug 529252

Revision history for this message
Josh Koenig (joshkoenig) wrote : Re: [Bug 529252] Re: Batch API does not use ajax

The most recent "suggested start VCL" for Pressflow also passes the has_js
cookie, since this could be a legitimate reason to uniquely cache pages:

https://wiki.fourkitchens.com/display/PF/Configure+Varnish+for+Pressflow

<https://wiki.fourkitchens.com/display/PF/Configure+Varnish+for+Pressflow>This
should be included in the most recent releases of the Pantheon AMIs.

-j

On Thu, Oct 28, 2010 at 12:44 PM, Kurt Gray <email address hidden>wrote:

> On Acquia Hosting we rearranged the VCL so that we check for the SESS
> cookie and pass *before* normalizing the Cookie (removing the has_js,
> etc, etc) which allows Drupal to see the entire original Cookie for at
> least logged-in users.
>
> --
> Batch API does not use ajax
> https://bugs.launchpad.net/bugs/529252
> You received this bug notification because you are a member of PANTHEON
> Developers, which is subscribed to Pantheon.
>
> Status in Pantheon - open-source system configuration for enterprise
> Drupal: Triaged
> Status in Pressflow: Triaged
>
> 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.
>
>
>