CoreCommunity ExtensionsIncubatorDistributionsTYPO3 4.5 ProjectsTYPO3 4.6 ProjectsTYPO3 4.7 ProjectsTYPO3 6.0 ProjectsTYPO3 6.1 ProjectsTYPO3 6.2 Projects (+)

Bug #11886

Search does not work with multiple plugins on the same page

Added by Christian Weiske over 2 years ago. Updated over 2 years ago.

Status:Resolved Start date:2011-01-04
Priority:Must have Due date:2011-01-10
Assignee:Dirk Wildt % Done:

100%

Category:PHP Spent time: -
Target version:3.6.1 Estimated time:0.50 hour
Votes: 0

Description

Using the browser (pi1) multiple times on the same page and searching in the 2nd or third plugin does not work, because the first instance clears the piVars in pi1/class.tx_browser_pi1_config.php.

    if($bool_unset_piVars)
    {
        unset($this->pObj->piVars);                                                                                                                                             
    }

Apparently that influences the piVars in the following instances, so that they see no piVars anymore.

browser-fix-11886-multiple.diff (3.8 kB) Christian Weiske, 2011-01-04 18:19

History

Updated by Christian Weiske over 2 years ago

Update: The problem is not unsetting the variable.

The issue is that $uid_plugin_current from $this->pObj->piVars['plugin'] is always empty.

Updated by Christian Weiske over 2 years ago

Attached is a patch that fixes the issue with multiple plugins on the same page.

  1. The plugin content ID is available in the template marker array now
  2. Each template search form needs to contain the plugin content ID, because otherwise we cannot determine the plugin filled by the user.
    <input type="hidden" name="tx_browser_pi1[plugin]" value="###PLUGIN###" />
    

With that new code, all the current/selected plugin detection code in class.tx_browser_pi1_config.php::prepare_piVars() begins to work.

Updated by Dirk Wildt over 2 years ago

  • Due date set to 2011-01-10
  • Category set to PHP
  • Status changed from New to Resolved
  • Assignee set to Dirk Wildt
  • Target version set to 3.6.1
  • % Done changed from 0 to 100
  • Estimated time set to 0.50

Also available in: Atom PDF