Definition at line 37 of file class.ilLikeForumSearch.php.
◆ __createPostAndCondition()
ilLikeForumSearch::__createPostAndCondition |
( |
| ) |
|
Definition at line 39 of file class.ilLikeForumSearch.php.
40 {
42
44
45
46
47
48
49
50 $concat =
$ilDB->concat(
51 array(
52 array('pos_subject','text'),
53 array('pos_message','text'))
54 );
55
56 $and = " AND ( ";
57 $counter = 0;
58 foreach ($this->query_parser->getQuotedWords() as $word) {
59 if ($counter++) {
60 $and .= " OR";
61 }
62 #$and .= $concat;
63 #$and .= ("LIKE ('%".$word."%')");
64 $and .=
$ilDB->like($concat,
'clob',
'%' . $word .
'%');
65 }
66 return $and . ") ";
67 }
References $DIC, and $ilDB.
◆ __createTopicAndCondition()
ilLikeForumSearch::__createTopicAndCondition |
( |
| ) |
|
Definition at line 69 of file class.ilLikeForumSearch.php.
70 {
72
74
75 $field = 'thr_subject ';
76 $and = " AND( ";
77
78 $counter = 0;
79 foreach ($this->query_parser->getQuotedWords() as $word) {
80 if ($counter++) {
81 $and .= " OR ";
82 }
83 #$and .= $field;
84 #$and .= ("LIKE ('%".$word."%')");
85 $and .=
$ilDB->like($field,
'text',
'%' . $word .
'%');
86 }
87 return $and . " ) ";
88 }
References $DIC, and $ilDB.
The documentation for this class was generated from the following file: