[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] CVS: phpbrain/inc class.bokb.inc.php,1.8,1.9 class.so
From: |
Dave Hall <address@hidden> |
Subject: |
[Phpgroupware-cvs] CVS: phpbrain/inc class.bokb.inc.php,1.8,1.9 class.sokb.inc.php,1.7,1.8 class.uikb.inc.php,1.8,1.9 |
Date: |
Wed, 16 Apr 2003 08:02:09 -0400 |
Update of /cvsroot/phpgroupware/phpbrain/inc
In directory subversions:/tmp/cvs-serv22693/inc
Modified Files:
class.bokb.inc.php class.sokb.inc.php class.uikb.inc.php
Log Message:
added related url and dos2unixed tpls
Index: class.bokb.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpbrain/inc/class.bokb.inc.php,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** class.bokb.inc.php 14 Apr 2003 06:47:09 -0000 1.8
--- class.bokb.inc.php 16 Apr 2003 12:02:07 -0000 1.9
***************
*** 192,198 ****
if(!$GLOBALS['phpgw_info']['apps']['phpkb']['config']['alow_tags'])
{
! $faq['title'] = strip_tags($faq['title']);
! $faq['keywords'] = strip_tags($faq['keywords']);
! $faq['text'] = strip_tags($faq['text']);
}
$faq['user_id'] =
$GLOBALS['phpgw_info']['user']['account_id'];
--- 192,198 ----
if(!$GLOBALS['phpgw_info']['apps']['phpkb']['config']['alow_tags'])
{
! $faq['title'] = strip_tags($faq['title']);
! $faq['keywords'] = strip_tags($faq['keywords']);
! $faq['text'] = strip_tags($faq['text']);
}
$faq['user_id'] =
$GLOBALS['phpgw_info']['user']['account_id'];
Index: class.sokb.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpbrain/inc/class.sokb.inc.php,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** class.sokb.inc.php 14 Apr 2003 06:47:09 -0000 1.7
--- class.sokb.inc.php 16 Apr 2003 12:02:07 -0000 1.8
***************
*** 226,229 ****
--- 226,230 ----
$sql .= ' published = ' . ($admin ? 1 :
0) . ', ';
$sql .= ' is_faq = ' . $faq['is_faq'];
+ $sql .= ' url = "' .
$this->db->db_addslashes(urldecode($faq['ur'])) .'"';
$sql .= " WHERE faq_id = $faq_id";
$this->db->query($sql);
***************
*** 243,249 ****
$sql .= "'" .
$this->db->db_addslashes($faq['text']) . "', ";
$sql .= $faq['cat_id'] . ", ";
! $sql .= "1, '" .
$this->db->db_addslashes($faq['keywords']) . "',";
$sql .= $faq['user_id'] . ', ';
! $sql .= '0, ' . time() . ', ' .
$faq['is_faq'] . ", '')";//url is empty for now
$this->db->query($sql);
return
$this->db->get_last_insert_id('phpgw_kb_faq', 'faq_id');
--- 244,254 ----
$sql .= "'" .
$this->db->db_addslashes($faq['text']) . "', ";
$sql .= $faq['cat_id'] . ", ";
! $sql .= ($admin ? 1 : 0) . ', ';//admin
is auto publish
! $sql .=
$this->db->db_addslashes($faq['keywords']) . "',";
$sql .= $faq['user_id'] . ', ';
! $sql .= '0, '; //views must be 0 for
new entries
! $sql .= time() . ', ';
! $sql .= $faq['is_faq'] . ', ';
! $sql .= '"' .
$this->db->db_addslashes(urldecode($faq['url'])) .'")';//url is decoded to make
sure it is not encoded already
$this->db->query($sql);
return
$this->db->get_last_insert_id('phpgw_kb_faq', 'faq_id');
Index: class.uikb.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpbrain/inc/class.uikb.inc.php,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** class.uikb.inc.php 16 Apr 2003 08:58:38 -0000 1.8
--- class.uikb.inc.php 16 Apr 2003 12:02:07 -0000 1.9
***************
*** 316,326 ****
'lang_check_before_submit' =>
lang('check_before_submit'),
'lang_not_submit_qs_warn' =>
lang('not_submit_qs_warn'),
! 'lang_inspire_by_suggestions'=>
lang('inspire_by_suggestions'),
! 'lang_title'
=> lang('title'),
! 'lang_keywords'
=> lang('keywords'),
! 'lang_category'
=> lang('category'),
! 'lang_text'
=> lang('text'),
! 'lang_save'
=> lang('save'),
! 'lang_reset'
=> lang('reset')
);
$this->t->set_var($lang);
--- 316,327 ----
'lang_check_before_submit' =>
lang('check_before_submit'),
'lang_not_submit_qs_warn' =>
lang('not_submit_qs_warn'),
! 'lang_inspire_by_suggestions' =>
lang('inspire_by_suggestions'),
! 'lang_title' =>
lang('title'),
! 'lang_keywords' =>
lang('keywords'),
! 'lang_category' =>
lang('category'),
! 'lang_related_url' =>
lang('related_url'),
! 'lang_text' =>
lang('text'),
! 'lang_save' =>
lang('save'),
! 'lang_reset' =>
lang('reset')
);
$this->t->set_var($lang);
***************
*** 487,490 ****
--- 488,492 ----
$faq['text'] = (isset($_POST['text']) ?
trim($_POST['text']) : '');
$faq['is_faq'] = (int) (isset($_POST['is_faq']) ?
trim($_POST['is_faq']) : 0);
+ $faq['url'] = (isset($_POST['url']) ?
trim($_POST['url']) : '');
$faq_id = $this->bo->save($faq_id, $faq, $question_id);
if($faq_id)
***************
*** 737,740 ****
--- 739,743 ----
'lang_rating' =>
lang('rating'),
'lang_title' =>
lang('title'),
+ 'lang_related_url' =>
lang('related_url'),
'lang_text' => lang('text'),
'lang_poor' => lang('poor'),
***************
*** 780,783 ****
--- 783,795 ----
$lang['return_msg'] =
lang('return_to_cats %1', $this->cats->id2name($item['cat_id']));
}//end if search
+
+ if($item['url'])
+ {
+ $item['rel_link'] = '<a href="' .
urlencode($item['url']) .'" target="_blank">' . $item['url'] . '</a>';
+ }
+ else
+ {
+ $item['rel_link'] = lang('none');
+ }
$this->t->set_block('showitem', 'cmnt',
'cmnts');
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] CVS: phpbrain/inc class.bokb.inc.php,1.8,1.9 class.sokb.inc.php,1.7,1.8 class.uikb.inc.php,1.8,1.9,
Dave Hall <address@hidden> <=
- Prev by Date:
[Phpgroupware-cvs] CVS: phpbrain/templates/default admin_maint.tpl,1.3,1.4 browse.tpl,1.1.1.1,1.2 cat_list.tpl,1.1.1.1,1.2 config.tpl,1.1.1.1,1.2 edit_faq.tpl,1.2,1.3 faq_sum.tpl,1.1.1.1,1.2 showitem.tpl,1.1.1.1,1.2unanswered.tpl,1.1.1.1,1.2
- Next by Date:
[Phpgroupware-cvs] CVS: setup lang.php,1.46.2.3,1.46.2.4
- Previous by thread:
[Phpgroupware-cvs] CVS: phpbrain/templates/default admin_maint.tpl,1.3,1.4 browse.tpl,1.1.1.1,1.2 cat_list.tpl,1.1.1.1,1.2 config.tpl,1.1.1.1,1.2 edit_faq.tpl,1.2,1.3 faq_sum.tpl,1.1.1.1,1.2 showitem.tpl,1.1.1.1,1.2unanswered.tpl,1.1.1.1,1.2
- Next by thread:
[Phpgroupware-cvs] CVS: setup lang.php,1.46.2.3,1.46.2.4
- Index(es):