Forums / Developer / Problems with advanced search and custom extension

"Please Note:
  • At the specific request of Ibexa we are changing this projects name to "Exponential" or "Exponential (CMS)" effective as of August, 11th 2025.
  • This project is not associated with the original eZ Publish software or its original developer, eZ Systems or Ibexa".

Problems with advanced search and custom extension

Author Message

David Syers

Friday 10 October 2003 8:14:10 am

I don't know if anyone else has come across this problem before, but I could not find anything using the search.

I have created a custom fetch function called "common" in a module called "external_actions". This fetch function is used to read a table of application variables to decide if logged in users should be tracked amount other things. It also as default it accesses the $_SESSION variable and extracts the LastAccessesURI and extracts the NodeID from it. This is then returned in the variable "ext_session_node_id" and this is used to find out the section_id to display the correct pagelayout template.

This is working fine on every other page on the site, including the normal site search. But the moment I try the advanced search I get the following error:

Fatal error: Call to undefined function: attribute() in /home/f/web_sites/Development/Exponential/kernel/classes/ezcontentobjecttreenode.php on line 779
Fatal error: Exponential did not finish it's request

Any help would be very much appreciated.

David Syers

Tuesday 14 October 2003 4:52:13 am

Well it turns out that in the end it was not my custom extension at all.

The problem lay in one of my templates where I had accidently passed an array as a fetch function parameter instead of the array value.

David Syers

Tuesday 14 October 2003 7:48:39 am

Now it turns out that I was a bit hasty earlier and it turns out that I was passing the correct value (I just mistook it for an array at first).

There is a bug with the |reverse operator when you are under the advanced search.

ie. If $node.path_array was equal to array(1,2,47,94) and you did

{set node_array_reversed=$node.path_array|reverse}

under any other view (as far as I am aware anyway) you would expect $node_array_reversed to be:

array(94,47,2,1)

However under the advanced search you get

yarrA

So it looks like under the advanced search |reverse is returning the type text "Array" reversed.