Quicktabs not able to pass arguments when using AJAX

QuickTabs AJAX Errors when passing Arguments
QuickTabs AJAX Errors when passing Arguments

I have three tabs in a QuickTabs block on a Panels Page. Each is set to a callback function like so:

Tab 1 Callback: list/autos/%1/ford
Tab 2 Callback: list/autos/%1/chevy
Tab 3 Callback: list/autos/%1/honda

If I set the tabs to load with AJAX, all arguments come through to the callback function as expected - arg(0) is list, arg(1) is autos, arg(2) is the 1st arg from the URL, and arg(3) is the manufacturer. EXCEPT the default tab, which gets only the original URL args, not those specified in the callback string.

If I set the tabs to NOT load via AJAX, they ALL fail, getting only the original URL args. It's as if the callback args are not yet available while the panel is still loading/rendering.

In short, it seems the args are empty when page is first being constructed. I haven't traced why yet, but the following fix did the trick at line 46 of QuickCallbackContent.inc in the plugins directory, just after the public render() function at line 45:

if (get_class($this) == 'QuickCallbackContent' && empty($args)) $args = array('junk_value', $this->settings['ajax_path']);

I'm not sure I should make a patch out of this yet as it doesn't necessarily fix the core issue, but this is working for now and is a good indication of where other problems may lie? I'm also not certain that the core issue is a Quicktabs thing - it could be CTools/Panels or elsewhere.

Tags: