@@ -29,7 +29,7 @@ |
||
29 | 29 | $startfaq = isset($_GET['startfaq']) ? (int)$_GET['startfaq'] : 0; |
30 | 30 | |
31 | 31 | /** |
32 | - * @param bool $showmenu |
|
32 | + * @param string $showmenu |
|
33 | 33 | * @param int $faqid |
34 | 34 | * @param int $answerid |
35 | 35 | * @param bool $merge |
@@ -549,11 +549,11 @@ |
||
549 | 549 | $faqid = isset($_GET['faqid']) ? (int)$_GET['faqid'] : 0; |
550 | 550 | xoops_cp_header(); |
551 | 551 | xoops_confirm(array( |
552 | - 'op' => 'del', |
|
553 | - 'faqid' => $faqObj->faqid(), |
|
554 | - 'confirm' => 1, |
|
555 | - 'name' => $faqObj->question() |
|
556 | - ), 'faq.php', _AM_SF_DELETETHISARTICLE . " <br>'" . $faqObj->question() . "'. <br> <br>", _AM_SF_DELETE); |
|
552 | + 'op' => 'del', |
|
553 | + 'faqid' => $faqObj->faqid(), |
|
554 | + 'confirm' => 1, |
|
555 | + 'name' => $faqObj->question() |
|
556 | + ), 'faq.php', _AM_SF_DELETETHISARTICLE . " <br>'" . $faqObj->question() . "'. <br> <br>", _AM_SF_DELETE); |
|
557 | 557 | xoops_cp_footer(); |
558 | 558 | } |
559 | 559 |
@@ -120,9 +120,9 @@ discard block |
||
120 | 120 | * Add appendix |
121 | 121 | * |
122 | 122 | * @access public |
123 | - * @param $permName |
|
123 | + * @param string $permName |
|
124 | 124 | * @param $itemId |
125 | - * @param $itemName |
|
125 | + * @param string $itemName |
|
126 | 126 | */ |
127 | 127 | public function addAppendix($permName, $itemId, $itemName) |
128 | 128 | { |
@@ -256,7 +256,7 @@ discard block |
||
256 | 256 | /** |
257 | 257 | * Constructor |
258 | 258 | * @param $caption |
259 | - * @param $name |
|
259 | + * @param string $name |
|
260 | 260 | * @param $groupId |
261 | 261 | * @param null $values |
262 | 262 | */ |
@@ -192,16 +192,16 @@ discard block |
||
192 | 192 | |
193 | 193 | $ret = '<h4>' . $this->getTitle() . '</h4>' . $this->_permDesc . '<br>'; |
194 | 194 | $ret .= "<form name='" |
195 | - . $this->getName() |
|
196 | - . "' id='" |
|
197 | - . $this->getName() |
|
198 | - . "' action='" |
|
199 | - . $this->getAction() |
|
200 | - . "' method='" |
|
201 | - . $this->getMethod() |
|
202 | - . "'" |
|
203 | - . $this->getExtra() |
|
204 | - . ">\n<table width='100%' class='outer' cellspacing='1'>\n"; |
|
195 | + . $this->getName() |
|
196 | + . "' id='" |
|
197 | + . $this->getName() |
|
198 | + . "' action='" |
|
199 | + . $this->getAction() |
|
200 | + . "' method='" |
|
201 | + . $this->getMethod() |
|
202 | + . "'" |
|
203 | + . $this->getExtra() |
|
204 | + . ">\n<table width='100%' class='outer' cellspacing='1'>\n"; |
|
205 | 205 | $elements =& $this->getElements(); |
206 | 206 | foreach (array_keys($elements) as $i) { |
207 | 207 | if (!is_object($elements[$i])) { |
@@ -369,19 +369,19 @@ discard block |
||
369 | 369 | private function renderOptionTree(&$tree, $option, $prefix, $parentIds = array()) |
370 | 370 | { |
371 | 371 | $tree .= $prefix |
372 | - . '<input type="checkbox" name="' |
|
373 | - . $this->getName() |
|
374 | - . '[groups][' |
|
375 | - . $this->_groupId |
|
376 | - . '][' |
|
377 | - . $option['id'] |
|
378 | - . ']" id="' |
|
379 | - . $this->getName() |
|
380 | - . '[groups][' |
|
381 | - . $this->_groupId |
|
382 | - . '][' |
|
383 | - . $option['id'] |
|
384 | - . ']" onclick="'; |
|
372 | + . '<input type="checkbox" name="' |
|
373 | + . $this->getName() |
|
374 | + . '[groups][' |
|
375 | + . $this->_groupId |
|
376 | + . '][' |
|
377 | + . $option['id'] |
|
378 | + . ']" id="' |
|
379 | + . $this->getName() |
|
380 | + . '[groups][' |
|
381 | + . $this->_groupId |
|
382 | + . '][' |
|
383 | + . $option['id'] |
|
384 | + . ']" onclick="'; |
|
385 | 385 | // If there are parent elements, add javascript that will |
386 | 386 | // make them selecteded when this element is checked to make |
387 | 387 | // sure permissions to parent items are added as well. |
@@ -402,20 +402,20 @@ discard block |
||
402 | 402 | $tree .= ' checked'; |
403 | 403 | } |
404 | 404 | $tree .= ' />' |
405 | - . $option['name'] |
|
406 | - . '<input type="hidden" name="' |
|
407 | - . $this->getName() |
|
408 | - . '[parents][' |
|
409 | - . $option['id'] |
|
410 | - . ']" value="' |
|
411 | - . implode(':', $parentIds) |
|
412 | - . '" /><input type="hidden" name="' |
|
413 | - . $this->getName() |
|
414 | - . '[itemname][' |
|
415 | - . $option['id'] |
|
416 | - . ']" value="' |
|
417 | - . htmlspecialchars($option['name']) |
|
418 | - . "\" /><br>\n"; |
|
405 | + . $option['name'] |
|
406 | + . '<input type="hidden" name="' |
|
407 | + . $this->getName() |
|
408 | + . '[parents][' |
|
409 | + . $option['id'] |
|
410 | + . ']" value="' |
|
411 | + . implode(':', $parentIds) |
|
412 | + . '" /><input type="hidden" name="' |
|
413 | + . $this->getName() |
|
414 | + . '[itemname][' |
|
415 | + . $option['id'] |
|
416 | + . ']" value="' |
|
417 | + . htmlspecialchars($option['name']) |
|
418 | + . "\" /><br>\n"; |
|
419 | 419 | if (isset($option['children'])) { |
420 | 420 | foreach ($option['children'] as $child) { |
421 | 421 | array_push($parentIds, $option['id']); |
@@ -26,7 +26,7 @@ |
||
26 | 26 | $startfaq = isset($_GET['startfaq']) ? (int)$_GET['startfaq'] : 0; |
27 | 27 | |
28 | 28 | /** |
29 | - * @param bool $showmenu |
|
29 | + * @param string $showmenu |
|
30 | 30 | * @param int $faqid |
31 | 31 | */ |
32 | 32 | function editfaq($showmenu = false, $faqid = -1) |
@@ -284,11 +284,11 @@ discard block |
||
284 | 284 | $faqid = isset($_GET['faqid']) ? (int)$_GET['faqid'] : 0; |
285 | 285 | xoops_cp_header(); |
286 | 286 | xoops_confirm(array( |
287 | - 'op' => 'del', |
|
288 | - 'faqid' => $faqObj->faqid(), |
|
289 | - 'confirm' => 1, |
|
290 | - 'name' => $faqObj->question() |
|
291 | - ), 'question.php', _AM_SF_DELETETHISQUESTION . " <br>'" . $faqObj->question() . "'. <br> <br>", _AM_SF_DELETE); |
|
287 | + 'op' => 'del', |
|
288 | + 'faqid' => $faqObj->faqid(), |
|
289 | + 'confirm' => 1, |
|
290 | + 'name' => $faqObj->question() |
|
291 | + ), 'question.php', _AM_SF_DELETETHISQUESTION . " <br>'" . $faqObj->question() . "'. <br> <br>", _AM_SF_DELETE); |
|
292 | 292 | xoops_cp_footer(); |
293 | 293 | } |
294 | 294 | |
@@ -338,25 +338,25 @@ discard block |
||
338 | 338 | $categoryObj = $allCats[$faqsObj[$i]->categoryid()]; |
339 | 339 | |
340 | 340 | $modify = "<a href='question.php?op=mod&faqid=" |
341 | - . $faqsObj[$i]->faqid() |
|
342 | - . "'><img src='" |
|
343 | - . $pathIcon16 |
|
344 | - . '/edit.png' |
|
345 | - . "' title='" |
|
346 | - . _AM_SF_EDITART |
|
347 | - . "' alt='" |
|
348 | - . _AM_SF_EDITART |
|
349 | - . "'></a>"; |
|
341 | + . $faqsObj[$i]->faqid() |
|
342 | + . "'><img src='" |
|
343 | + . $pathIcon16 |
|
344 | + . '/edit.png' |
|
345 | + . "' title='" |
|
346 | + . _AM_SF_EDITART |
|
347 | + . "' alt='" |
|
348 | + . _AM_SF_EDITART |
|
349 | + . "'></a>"; |
|
350 | 350 | $delete = "<a href='question.php?op=del&faqid=" |
351 | - . $faqsObj[$i]->faqid() |
|
352 | - . "'><img src='" |
|
353 | - . $pathIcon16 |
|
354 | - . '/delete.png' |
|
355 | - . "' title='" |
|
356 | - . _AM_SF_DELETEART |
|
357 | - . "' alt='" |
|
358 | - . _AM_SF_DELETEART |
|
359 | - . "'></a>"; |
|
351 | + . $faqsObj[$i]->faqid() |
|
352 | + . "'><img src='" |
|
353 | + . $pathIcon16 |
|
354 | + . '/delete.png' |
|
355 | + . "' title='" |
|
356 | + . _AM_SF_DELETEART |
|
357 | + . "' alt='" |
|
358 | + . _AM_SF_DELETEART |
|
359 | + . "'></a>"; |
|
360 | 360 | |
361 | 361 | $requester = sf_getLinkedUnameFromId($faqsObj[$i]->uid(), $smartModuleConfig['userealname']); |
362 | 362 | |
@@ -364,14 +364,14 @@ discard block |
||
364 | 364 | echo "<td class='head' align='center'>" . $faqsObj[$i]->faqid() . '</td>'; |
365 | 365 | echo "<td class='even' align='left'>" . $categoryObj->name() . '</td>'; |
366 | 366 | echo "<td class='even' align='left'><a href='" |
367 | - . XOOPS_URL |
|
368 | - . '/modules/' |
|
369 | - . $xoopsModule->dirname() |
|
370 | - . '/answer.php?faqid=' |
|
371 | - . $faqsObj[$i]->faqid() |
|
372 | - . "'>" |
|
373 | - . $faqsObj[$i]->question(100) |
|
374 | - . '</a></td>'; |
|
367 | + . XOOPS_URL |
|
368 | + . '/modules/' |
|
369 | + . $xoopsModule->dirname() |
|
370 | + . '/answer.php?faqid=' |
|
371 | + . $faqsObj[$i]->faqid() |
|
372 | + . "'>" |
|
373 | + . $faqsObj[$i]->question(100) |
|
374 | + . '</a></td>'; |
|
375 | 375 | |
376 | 376 | echo "<td class='even' align='center'>" . $requester . '</td>'; |
377 | 377 |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | |
28 | 28 | /** |
29 | 29 | * constructor |
30 | - * @param null $id |
|
30 | + * @param integer $id |
|
31 | 31 | */ |
32 | 32 | public function __construct($id = null) |
33 | 33 | { |
@@ -368,7 +368,7 @@ discard block |
||
368 | 368 | * create a new answer |
369 | 369 | * |
370 | 370 | * @param bool $isNew flag the new objects as "new"? |
371 | - * @return object sfAnswer |
|
371 | + * @return sfAnswer sfAnswer |
|
372 | 372 | */ |
373 | 373 | public function create($isNew = true) |
374 | 374 | { |
@@ -410,7 +410,7 @@ discard block |
||
410 | 410 | /** |
411 | 411 | * insert a new answer in the database |
412 | 412 | * |
413 | - * @param XoopsObject $answerObj reference to the <a href='psi_element://sfAnswer'>sfAnswer</a> object |
|
413 | + * @param sfAnswer $answerObj reference to the <a href='psi_element://sfAnswer'>sfAnswer</a> object |
|
414 | 414 | * @param bool $force |
415 | 415 | * @return bool FALSE if failed, TRUE if already present and unchanged or successful |
416 | 416 | */ |
@@ -474,10 +474,10 @@ |
||
474 | 474 | |
475 | 475 | if ($answerObj->isNew()) { |
476 | 476 | $sql = sprintf('INSERT INTO %s (answerid, `status`, faqid, answer, uid, datesub, notifypub) VALUES (NULL, %u, %u, %s, %u, %u, %u)', $this->db->prefix('smartfaq_answers'), $status, $faqid, |
477 | - $this->db->quoteString($answer), $uid, time(), $notifypub); |
|
477 | + $this->db->quoteString($answer), $uid, time(), $notifypub); |
|
478 | 478 | } else { |
479 | 479 | $sql = sprintf('UPDATE %s SET STATUS = %u, faqid = %s, answer = %s, uid = %u, datesub = %u, notifypub = %u WHERE answerid = %u', $this->db->prefix('smartfaq_answers'), $status, $faqid, |
480 | - $this->db->quoteString($answer), $uid, $datesub, $notifypub, $answerid); |
|
480 | + $this->db->quoteString($answer), $uid, $datesub, $notifypub, $answerid); |
|
481 | 481 | } |
482 | 482 | |
483 | 483 | if (false != $force) { |
@@ -269,7 +269,7 @@ discard block |
||
269 | 269 | * create a new category |
270 | 270 | * |
271 | 271 | * @param bool $isNew flag the new objects as "new"? |
272 | - * @return object sfCategory |
|
272 | + * @return sfCategory sfCategory |
|
273 | 273 | */ |
274 | 274 | public function &create($isNew = true) |
275 | 275 | { |
@@ -311,7 +311,7 @@ discard block |
||
311 | 311 | /** |
312 | 312 | * insert a new category in the database |
313 | 313 | * |
314 | - * @param XoopsObject $category reference to the {@link sfCategory} object |
|
314 | + * @param sfCategory $category reference to the {@link sfCategory} object |
|
315 | 315 | * @param bool $force |
316 | 316 | * @return bool FALSE if failed, TRUE if already present and unchanged or successful |
317 | 317 | */ |
@@ -333,10 +333,10 @@ discard block |
||
333 | 333 | |
334 | 334 | if ($category->isNew()) { |
335 | 335 | $sql = sprintf('INSERT INTO %s (categoryid, parentid, name, description, total, weight, created) VALUES (NULL, %u, %s, %s, %u, %u, %u)', $this->db->prefix('smartfaq_categories'), |
336 | - $parentid, $this->db->quoteString($name), $this->db->quoteString($description), $total, $weight, time()); |
|
336 | + $parentid, $this->db->quoteString($name), $this->db->quoteString($description), $total, $weight, time()); |
|
337 | 337 | } else { |
338 | 338 | $sql = sprintf('UPDATE %s SET parentid = %u, name = %s, description = %s, total = %s, weight = %u, created = %u WHERE categoryid = %u', $this->db->prefix('smartfaq_categories'), $parentid, |
339 | - $this->db->quoteString($name), $this->db->quoteString($description), $total, $weight, $created, $categoryid); |
|
339 | + $this->db->quoteString($name), $this->db->quoteString($description), $total, $weight, $created, $categoryid); |
|
340 | 340 | } |
341 | 341 | if (false != $force) { |
342 | 342 | $result = $this->db->queryF($sql); |
@@ -520,10 +520,10 @@ discard block |
||
520 | 520 | $ret = array(); |
521 | 521 | $limit = $start = 0; |
522 | 522 | $sql = 'SELECT DISTINCT c.categoryid, c.parentid, c.name, c.description, c.total, c.weight, c.created FROM ' |
523 | - . $this->db->prefix('smartfaq_categories') |
|
524 | - . ' AS c INNER JOIN ' |
|
525 | - . $this->db->prefix('smartfaq_faq') |
|
526 | - . ' AS f ON c.categoryid = f.categoryid'; |
|
523 | + . $this->db->prefix('smartfaq_categories') |
|
524 | + . ' AS c INNER JOIN ' |
|
525 | + . $this->db->prefix('smartfaq_faq') |
|
526 | + . ' AS f ON c.categoryid = f.categoryid'; |
|
527 | 527 | if (isset($criteria) && is_subclass_of($criteria, 'criteriaelement')) { |
528 | 528 | $sql .= ' ' . $criteria->renderWhere(); |
529 | 529 | if ($criteria->getSort() != '') { |
@@ -167,7 +167,7 @@ discard block |
||
167 | 167 | } |
168 | 168 | |
169 | 169 | /** |
170 | - * @param $field |
|
170 | + * @param string $field |
|
171 | 171 | * @return bool |
172 | 172 | */ |
173 | 173 | public function fieldExists($field) |
@@ -628,7 +628,7 @@ discard block |
||
628 | 628 | /** |
629 | 629 | * Use to update a table |
630 | 630 | * |
631 | - * @param object $table {@link SmartDbTable} that will be updated |
|
631 | + * @param SmartDbTable $table {@link SmartDbTable} that will be updated |
|
632 | 632 | * |
633 | 633 | * @see SmartDbTable |
634 | 634 | * |
@@ -25,7 +25,7 @@ |
||
25 | 25 | * Constructor |
26 | 26 | * |
27 | 27 | * @param string $uploadDir |
28 | - * @param array|int $allowedMimeTypes |
|
28 | + * @param integer $allowedMimeTypes |
|
29 | 29 | * @param int $maxFileSize |
30 | 30 | * @param int $maxWidth |
31 | 31 | * @param int $maxHeight |
@@ -509,7 +509,7 @@ discard block |
||
509 | 509 | |
510 | 510 | /** |
511 | 511 | * @param string $url |
512 | - * @return mixed|string |
|
512 | + * @return string |
|
513 | 513 | */ |
514 | 514 | function sf_getxoopslink($url = '') |
515 | 515 | { |
@@ -582,7 +582,7 @@ discard block |
||
582 | 582 | } |
583 | 583 | |
584 | 584 | /** |
585 | - * @param $name |
|
585 | + * @param string $name |
|
586 | 586 | * @param bool $optional |
587 | 587 | * @return bool |
588 | 588 | */ |
@@ -202,14 +202,14 @@ discard block |
||
202 | 202 | $modfootertxt = 'Module ' . $smartModule->getInfo('name') . ' - Version ' . $smartModule->getInfo('version') . ''; |
203 | 203 | |
204 | 204 | $modfooter = "<a href='" |
205 | - . $smartModule->getInfo('support_site_url') |
|
206 | - . "' target='_blank'><img src='" |
|
207 | - . XOOPS_URL |
|
208 | - . "/modules/smartfaq/assets/images/sfcssbutton.gif' title='" |
|
209 | - . $modfootertxt |
|
210 | - . "' alt='" |
|
211 | - . $modfootertxt |
|
212 | - . "'/></a>"; |
|
205 | + . $smartModule->getInfo('support_site_url') |
|
206 | + . "' target='_blank'><img src='" |
|
207 | + . XOOPS_URL |
|
208 | + . "/modules/smartfaq/assets/images/sfcssbutton.gif' title='" |
|
209 | + . $modfootertxt |
|
210 | + . "' alt='" |
|
211 | + . $modfootertxt |
|
212 | + . "'/></a>"; |
|
213 | 213 | |
214 | 214 | return $modfooter; |
215 | 215 | } |
@@ -444,70 +444,70 @@ discard block |
||
444 | 444 | if ($xoopsUser && $xoopsUser->isAdmin($xoopsModule->getVar('mid'))) { |
445 | 445 | // Edit button |
446 | 446 | $adminLinks .= "<a href='" |
447 | - . $modulePath |
|
448 | - . "admin/$page?op=mod&faqid=" |
|
449 | - . $faqid |
|
450 | - . "'><img src='" |
|
451 | - . $modulePath |
|
452 | - . "assets/images/links/edit.gif'" |
|
453 | - . " title='" |
|
454 | - . _MD_SF_EDIT |
|
455 | - . "' alt='" |
|
456 | - . _MD_SF_EDIT |
|
457 | - . "'/></a>"; |
|
447 | + . $modulePath |
|
448 | + . "admin/$page?op=mod&faqid=" |
|
449 | + . $faqid |
|
450 | + . "'><img src='" |
|
451 | + . $modulePath |
|
452 | + . "assets/images/links/edit.gif'" |
|
453 | + . " title='" |
|
454 | + . _MD_SF_EDIT |
|
455 | + . "' alt='" |
|
456 | + . _MD_SF_EDIT |
|
457 | + . "'/></a>"; |
|
458 | 458 | $adminLinks .= ' '; |
459 | 459 | // Delete button |
460 | 460 | $adminLinks .= "<a href='" |
461 | - . $modulePath |
|
462 | - . "admin/$page?op=del&faqid=" |
|
463 | - . $faqid |
|
464 | - . "'><img src='" |
|
465 | - . $modulePath |
|
466 | - . "assets/images/links/delete.gif'" |
|
467 | - . " title='" |
|
468 | - . _MD_SF_DELETE |
|
469 | - . "' alt='" |
|
470 | - . _MD_SF_DELETE |
|
471 | - . "'/></a>"; |
|
461 | + . $modulePath |
|
462 | + . "admin/$page?op=del&faqid=" |
|
463 | + . $faqid |
|
464 | + . "'><img src='" |
|
465 | + . $modulePath |
|
466 | + . "assets/images/links/delete.gif'" |
|
467 | + . " title='" |
|
468 | + . _MD_SF_DELETE |
|
469 | + . "' alt='" |
|
470 | + . _MD_SF_DELETE |
|
471 | + . "'/></a>"; |
|
472 | 472 | $adminLinks .= ' '; |
473 | 473 | } |
474 | 474 | // Print button |
475 | 475 | $adminLinks .= "<a href='" |
476 | - . $modulePath |
|
477 | - . 'print.php?faqid=' |
|
478 | - . $faqid |
|
479 | - . "'><img src='" |
|
480 | - . $modulePath |
|
481 | - . "assets/images/links/print.gif' title='" |
|
482 | - . _MD_SF_PRINT |
|
483 | - . "' alt='" |
|
484 | - . _MD_SF_PRINT |
|
485 | - . "'/></a>"; |
|
476 | + . $modulePath |
|
477 | + . 'print.php?faqid=' |
|
478 | + . $faqid |
|
479 | + . "'><img src='" |
|
480 | + . $modulePath |
|
481 | + . "assets/images/links/print.gif' title='" |
|
482 | + . _MD_SF_PRINT |
|
483 | + . "' alt='" |
|
484 | + . _MD_SF_PRINT |
|
485 | + . "'/></a>"; |
|
486 | 486 | $adminLinks .= ' '; |
487 | 487 | // Email button |
488 | 488 | $maillink = 'mailto:?subject=' |
489 | - . sprintf(_MD_SF_INTARTICLE, $xoopsConfig['sitename']) |
|
490 | - . '&body=' |
|
491 | - . sprintf(_MD_SF_INTARTFOUND, $xoopsConfig['sitename']) |
|
492 | - . ': ' |
|
493 | - . $modulePath |
|
494 | - . 'faq.php?faqid=' |
|
495 | - . $faqid; |
|
489 | + . sprintf(_MD_SF_INTARTICLE, $xoopsConfig['sitename']) |
|
490 | + . '&body=' |
|
491 | + . sprintf(_MD_SF_INTARTFOUND, $xoopsConfig['sitename']) |
|
492 | + . ': ' |
|
493 | + . $modulePath |
|
494 | + . 'faq.php?faqid=' |
|
495 | + . $faqid; |
|
496 | 496 | $adminLinks .= '<a href="' . $maillink . "\"><img src='" . $modulePath . "assets/images/links/friend.gif' title='" . _MD_SF_MAIL . "' alt='" . _MD_SF_MAIL . "'/></a>"; |
497 | 497 | $adminLinks .= ' '; |
498 | 498 | // Submit New Answer button |
499 | 499 | if ($xoopsModuleConfig['allownewanswer'] && (is_object($xoopsUser) || $xoopsModuleConfig['anonpost'])) { |
500 | 500 | $adminLinks .= "<a href='" |
501 | - . $modulePath |
|
502 | - . 'answer.php?faqid=' |
|
503 | - . $faqid |
|
504 | - . "'><img src='" |
|
505 | - . $modulePath |
|
506 | - . "assets/images/links/newanswer.gif' title='" |
|
507 | - . _MD_SF_SUBMITANSWER |
|
508 | - . "' alt='" |
|
509 | - . _MD_SF_SUBMITANSWER |
|
510 | - . "'/></a>"; |
|
501 | + . $modulePath |
|
502 | + . 'answer.php?faqid=' |
|
503 | + . $faqid |
|
504 | + . "'><img src='" |
|
505 | + . $modulePath |
|
506 | + . "assets/images/links/newanswer.gif' title='" |
|
507 | + . _MD_SF_SUBMITANSWER |
|
508 | + . "' alt='" |
|
509 | + . _MD_SF_SUBMITANSWER |
|
510 | + . "'/></a>"; |
|
511 | 511 | $adminLinks .= ' '; |
512 | 512 | } |
513 | 513 |
@@ -243,7 +243,7 @@ discard block |
||
243 | 243 | } |
244 | 244 | |
245 | 245 | /** |
246 | - * @return mixed |
|
246 | + * @return integer |
|
247 | 247 | */ |
248 | 248 | public function uid() |
249 | 249 | { |
@@ -754,7 +754,7 @@ discard block |
||
754 | 754 | /** |
755 | 755 | * insert a new faq in the database |
756 | 756 | * |
757 | - * @param XoopsObject $faq reference to the {@link sfFaq} object |
|
757 | + * @param sfFaq $faq reference to the {@link sfFaq} object |
|
758 | 758 | * @param bool $force |
759 | 759 | * @return bool FALSE if failed, TRUE if already present and unchanged or successful |
760 | 760 | */ |
@@ -1143,7 +1143,7 @@ discard block |
||
1143 | 1143 | * @param string $order |
1144 | 1144 | * @param string $notNullFields |
1145 | 1145 | * @param bool $asobject |
1146 | - * @param null $otherCriteria |
|
1146 | + * @param null|CriteriaCompo $otherCriteria |
|
1147 | 1147 | * @return array |
1148 | 1148 | */ |
1149 | 1149 | public function getFaqs( |
@@ -647,16 +647,16 @@ discard block |
||
647 | 647 | } |
648 | 648 | |
649 | 649 | return $text |
650 | - . $xoopsConfig['sitename'] |
|
651 | - . ' : <a href=' |
|
652 | - . XOOPS_URL |
|
653 | - . '/modules/smartfaq/faq.php?faqid=' |
|
654 | - . $this->faqid() |
|
655 | - . '>' |
|
656 | - . XOOPS_URL |
|
657 | - . '/modules/smartfaq/faq.php?faqid=' |
|
658 | - . $this->faqid() |
|
659 | - . '</a>'; |
|
650 | + . $xoopsConfig['sitename'] |
|
651 | + . ' : <a href=' |
|
652 | + . XOOPS_URL |
|
653 | + . '/modules/smartfaq/faq.php?faqid=' |
|
654 | + . $this->faqid() |
|
655 | + . '>' |
|
656 | + . XOOPS_URL |
|
657 | + . '/modules/smartfaq/faq.php?faqid=' |
|
658 | + . $this->faqid() |
|
659 | + . '</a>'; |
|
660 | 660 | } |
661 | 661 | |
662 | 662 | /** |
@@ -778,14 +778,14 @@ discard block |
||
778 | 778 | |
779 | 779 | if ($faq->isNew()) { |
780 | 780 | $sql = sprintf('INSERT INTO %s (faqid, categoryid, question, howdoi, diduno, uid, datesub, `status`, counter, weight, html, smiley, xcodes, cancomment, comments, notifypub, modulelink, contextpage, exacturl, partialview) VALUES (NULL, %u, %s, %s, %s, %u, %u, %u, %u, %u, %u, %u, %u, %u, %u, %u, %s, %s, %u, %u)', |
781 | - $this->db->prefix('smartfaq_faq'), $categoryid, $this->db->quoteString($question), $this->db->quoteString($howdoi), $this->db->quoteString($diduno), $uid, time(), $status, |
|
782 | - $counter, $weight, $html, $smiley, $xcodes, $cancomment, $comments, $notifypub, $this->db->quoteString($modulelink), $this->db->quoteString($contextpage), $exacturl, |
|
783 | - $partialview); |
|
781 | + $this->db->prefix('smartfaq_faq'), $categoryid, $this->db->quoteString($question), $this->db->quoteString($howdoi), $this->db->quoteString($diduno), $uid, time(), $status, |
|
782 | + $counter, $weight, $html, $smiley, $xcodes, $cancomment, $comments, $notifypub, $this->db->quoteString($modulelink), $this->db->quoteString($contextpage), $exacturl, |
|
783 | + $partialview); |
|
784 | 784 | } else { |
785 | 785 | $sql = sprintf('UPDATE %s SET categoryid = %u, question = %s, howdoi = %s, diduno = %s, uid = %u, datesub = %u, `status` = %u, counter = %u, weight = %u, html = %u, smiley = %u, xcodes = %u, cancomment = %u, comments = %u, notifypub = %u, modulelink = %s, contextpage = %s, exacturl = %u, partialview = %u WHERE faqid = %u', |
786 | - $this->db->prefix('smartfaq_faq'), $categoryid, $this->db->quoteString($question), $this->db->quoteString($howdoi), $this->db->quoteString($diduno), $uid, $datesub, $status, |
|
787 | - $counter, $weight, $html, $smiley, $xcodes, $cancomment, $comments, $notifypub, $this->db->quoteString($modulelink), $this->db->quoteString($contextpage), $exacturl, |
|
788 | - $partialview, $faqid); |
|
786 | + $this->db->prefix('smartfaq_faq'), $categoryid, $this->db->quoteString($question), $this->db->quoteString($howdoi), $this->db->quoteString($diduno), $uid, $datesub, $status, |
|
787 | + $counter, $weight, $html, $smiley, $xcodes, $cancomment, $comments, $notifypub, $this->db->quoteString($modulelink), $this->db->quoteString($contextpage), $exacturl, |
|
788 | + $partialview, $faqid); |
|
789 | 789 | } |
790 | 790 | if (false != $force) { |
791 | 791 | $result = $this->db->queryF($sql); |
@@ -1618,10 +1618,10 @@ discard block |
||
1618 | 1618 | $criteria->setOrder('DESC'); |
1619 | 1619 | |
1620 | 1620 | $sql = 'SELECT faq.faqid, faq.question, faq.datesub, faq.uid FROM ' |
1621 | - . $this->db->prefix('smartfaq_faq') |
|
1622 | - . ' AS faq INNER JOIN ' |
|
1623 | - . $this->db->prefix('smartfaq_answers') |
|
1624 | - . ' AS answer ON faq.faqid = answer.faqid'; |
|
1621 | + . $this->db->prefix('smartfaq_faq') |
|
1622 | + . ' AS faq INNER JOIN ' |
|
1623 | + . $this->db->prefix('smartfaq_answers') |
|
1624 | + . ' AS answer ON faq.faqid = answer.faqid'; |
|
1625 | 1625 | |
1626 | 1626 | if (isset($criteria) && is_subclass_of($criteria, 'criteriaelement')) { |
1627 | 1627 | $whereClause = $criteria->renderWhere(); |