Post your requirements here

search of word in articles of private sections

the word is not found, only in case of associate.

WorkflowSupport request
StatusProblem has been recorded

may be a bug, because i am an editor of the private section ....

when an article is in private section, it' s active.article row has a value of "N", restricted. When i try a search , i cannot found because, i am not associate, only editor. The editor of a section is authorised to manage articles, the search request must take in account the = "N" ....

after several checking, i suggest the improvement below in articles.php

the modified code in search function:

* search for some keywords articles anchored to one precise section
* This function also searches in sub-sections, with up to three levels of depth.
* Only articles matching following criteria are returned:
* - article is visible (active='Y')
* - article is restricted (active='R'), but the surfer is an authenticated member,
* or YACS is allowed to show restricted teasers
* - article is restricted (active='N'), but surfer is an associate
* - article has been officially published, or the surfer is a logged user
* - an expiry date has not been defined, or is not yet passed
* @see search.php
* @param the id of the section to look in
* @param the search string
* @param int the offset from the start of the list; usually, 0 or 1
* @param int the number of items to display
* @param mixed the layout, if any
* @return NULL on error, else an ordered array with $url => ($prefix, $label, $suffix, $icon)

function &search_in_section($section_id, $pattern, $offset=0, $count=10, $layout='full') {
global $context;


To share the knowledge for a better future