diff --git a/admin.php b/admin.php index ec6bc91a5..d98be0011 100644 --- a/admin.php +++ b/admin.php @@ -39,23 +39,11 @@ if (isset($_GET['fckb_tags'])) { $query = ' SELECT - id, - name + id AS tag_id, + name AS tag_name FROM '.TAGS_TABLE.' ;'; - $result = pwg_query($query); - $taglist = array(); - while ($row = pwg_db_fetch_assoc($result)) - { - array_push( - $taglist, - array( - 'caption' => $row['name'], - 'value' => '~~'.$row['id'].'~~', - ) - ); - } - echo json_encode($taglist); + echo json_encode(get_fckb_taglist($query)); exit(); } diff --git a/admin/themes/default/template/element_set_unit.tpl b/admin/themes/default/template/element_set_unit.tpl index d31b5a95c..11693a994 100644 --- a/admin/themes/default/template/element_set_unit.tpl +++ b/admin/themes/default/template/element_set_unit.tpl @@ -3,10 +3,19 @@ {include file='include/datepicker.inc.tpl'} {known_script id="jquery.fcbkcomplete" src=$ROOT_URL|@cat:"themes/default/js/plugins/jquery.fcbkcomplete.js"} -{literal}