ILIAS  trunk Revision v11.0_alpha-1713-gd8962da2f67
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
class.ilLikeGlossaryDefinitionSearch.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
31 {
32  public function __createWhereCondition(): string
33  {
34  $concat = " term ";
35 
36  $and = " WHERE ( ";
37  $counter = 0;
38  foreach ($this->query_parser->getQuotedWords() as $word) {
39  if ($counter++) {
40  $and .= " OR";
41  }
42  $and .= $this->db->like($concat, 'text', '%' . $word . '%');
43  #$and .= $concat;
44  #$and .= ("LIKE ('%".$word."%')");
45  }
46  return $and . ") ";
47  }
48 }