@@ 563-578 (lines=16) @@ | ||
560 | // time ! |
|
561 | $current_time = time(); |
|
562 | ||
563 | if ($attribute_id == -1) |
|
564 | { |
|
565 | $fields = array( |
|
566 | 'topic_attr_id' => 0, |
|
567 | 'topic_attr_user' => 0, |
|
568 | 'topic_attr_time' => 0, |
|
569 | ); |
|
570 | } |
|
571 | else |
|
572 | { |
|
573 | $fields = array( |
|
574 | 'topic_attr_id' => $attribute_id, |
|
575 | 'topic_attr_user' => $this->user->data['user_id'], |
|
576 | 'topic_attr_time' => $current_time, |
|
577 | ); |
|
578 | } |
|
579 | ||
580 | $sql = 'UPDATE ' . TOPICS_TABLE . ' |
|
581 | SET ' . $this->db->sql_build_array('UPDATE', $fields) . ' |
|
@@ 649-664 (lines=16) @@ | ||
646 | } |
|
647 | $this->db->sql_freeresult($result); |
|
648 | ||
649 | if ($attribute_id == -1) |
|
650 | { |
|
651 | $fields = array( |
|
652 | 'topic_attr_id' => 0, |
|
653 | 'topic_attr_user' => 0, |
|
654 | 'topic_attr_time' => 0, |
|
655 | ); |
|
656 | } |
|
657 | else |
|
658 | { |
|
659 | $fields = array( |
|
660 | 'topic_attr_id' => $attribute_id, |
|
661 | 'topic_attr_user' => $this->user->data['user_id'], |
|
662 | 'topic_attr_time' => $current_time, |
|
663 | ); |
|
664 | } |
|
665 | ||
666 | $sql = 'UPDATE ' . TOPICS_TABLE . ' |
|
667 | SET ' . $this->db->sql_build_array('UPDATE', $fields) . ' |