prevent error when autocomplete tags are not available (only on entry editor pages)
This commit is contained in:
parent
6f021ef0e6
commit
8eafff7936
|
@ -1,3 +1,7 @@
|
|||
3.54:
|
||||
----
|
||||
Fix autocomplete error message when not within entry editor page
|
||||
|
||||
3.53.1:
|
||||
-----
|
||||
Fix autocomplete of tags in 2.0
|
||||
|
|
|
@ -72,7 +72,7 @@ class serendipity_event_freetag extends serendipity_event
|
|||
'smarty' => '2.6.7',
|
||||
'php' => '4.1.0'
|
||||
));
|
||||
$propbag->add('version', '3.53.1');
|
||||
$propbag->add('version', '3.54');
|
||||
$propbag->add('event_hooks', array(
|
||||
'frontend_fetchentries' => true,
|
||||
'frontend_fetchentry' => true,
|
||||
|
@ -878,13 +878,15 @@ class serendipity_event_freetag extends serendipity_event
|
|||
if ($this->get_config('admin_ftayt')) {
|
||||
echo '
|
||||
function enableAutocomplete() {
|
||||
$("#properties_freetag_tagList").autocomplete(tags, {
|
||||
minChars: 0,
|
||||
multiple: true,
|
||||
scrollHeight: 200,
|
||||
matchContains: "word",
|
||||
autoFill: false
|
||||
})
|
||||
if (typeof(tags) != "undefined") {
|
||||
$("#properties_freetag_tagList").autocomplete(tags, {
|
||||
minChars: 0,
|
||||
multiple: true,
|
||||
scrollHeight: 200,
|
||||
matchContains: "word",
|
||||
autoFill: false
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
addLoadEvent(enableAutocomplete);
|
||||
|
|
Loading…
Reference in a new issue