The title module's search functionality does not work when register_globals is turned off.

Comments

killes@www.drop.org’s picture

Title: title module's search functionality does not work » Re: [drupal-devel] bug #1852 : title module's search functionality does not work

On 5 Jun 2003, Dries wrote:

> 05/06/2003 - 09:18 : Dries
> The title module's search functionality does not work when
> register_globals is turned off.

I think we already discussed this.
title.module used to set the global variable $keys, but now search_data
expects this variable to be in $_POST["keys"].
I think Al posted a solution for this.

Cheers,
Gerhard

al’s picture

Title: Re: [drupal-devel] bug #1852 : title module's search functionality does not work » Re: [drupal-devel] bug #1852 : title module's search functionali
Assigned: Unassigned » al
ax’s picture

works for me with latest cvs (yes, with register_globals turned off).

what doesn't work is the call to get_node_from_nid($node->nid) at line 25, because this function got removed again [1]. just removing this line makes it work again (because node_show() calls node_view() which doesn't care if it gets passed an array or an object - array2object() also makes objects to objects Only local images are allowed. ink" alt="Eye-w
ink" />).

[1] http://lists.drupal.org/pipermail/drupal-devel/2003-May/025211.html

al’s picture

Latest patches in CVS should have fixed this.
Please verify this is working and mark CLOSED if so.

al’s picture

moshe weitzman’s picture

Title: Re: [drupal-devel] bug #1852 : title module's search functionali » title module's search functionality broken
Component: Base system » search.module

Still busted. Note this link which uses a word found in our current lead story - http://drupal.org/title/remarkably

Dries assures that we are using latest title.module at drupal.org. Not sure if we are using latest common.inc and search.module which are also involved.

moshe weitzman’s picture

Fixed. I've just uploaded a patch for this to my sandbox (see 2 patch files named 006...).

The search functionality in title.module is so handy.

al’s picture

Assigned: al » moshe weitzman

pls. don't mark fixed 'til it's hit CVS.

dries’s picture

The patches might fix the problem but make the search module even more clumpsy: adding a $keys parameter is excellent however we should remove all occurrences of $keys = $_POST["keys"] but one instead of adding clutter around it ... the caller should resolve the proper $keys; the callee should not overwrite the $keys passed by the caller.

dries’s picture

Thanks for updating your patches Moshe. Committed to CVS. Marking this as "fixed".

moshe weitzman’s picture

Title: title module's search functionality broken » title module's author field is empty
Assigned: moshe weitzman » dries

reopening this bug as one more issue remains outstanding. the 'author' field is always empty when looking at a results page like http://drupal.org/title/download for example. the 1 line patch is in my sandbox (005...)

dries’s picture

Priority: Critical » Normal

Fixed in both the HEAD and DRUPAL-4-2-0 branch. Marking it as such.

moshe weitzman’s picture