X-Git-Url: https://projects.mako.cc/source/scuttle/blobdiff_plain/c7f63c8b9b12efd7b3c10b9f80cda06eaf32068f..HEAD:/edit.php?ds=sidebyside diff --git a/edit.php b/edit.php index cca8e47..0358a4d 100644 --- a/edit.php +++ b/edit.php @@ -1,7 +1,6 @@ getServiceInstance('BookmarkService'); +$templateservice =& $sf->getServiceInstance('TemplateService'); +$userservice =& $sf->getServiceInstance('UserService'); // Header variables $tplVars['subtitle'] = T_('Edit Bookmark'); -$tplVars['loadjs'] = true; +$tplVars['loadjs'] = TRUE; list ($url, $bookmark) = explode('/', $_SERVER['PATH_INFO']); + if (!($row = $bookmarkservice->getBookmark(intval($bookmark), true))) { - $tplVars['error'] = sprintf(T_('Bookmark with id %s not was not found'), $bookmark); + $tplVars['error'] = sprintf(T_('Bookmark with id %s was not found'), $bookmark); $templateservice->loadTemplate('error.404.tpl', $tplVars); exit(); } else { @@ -90,4 +91,3 @@ if (!($row = $bookmarkservice->getBookmark(intval($bookmark), true))) { $tplVars['referrer'] = $_SERVER['HTTP_REFERER']; $templateservice->loadTemplate('editbookmark.tpl', $tplVars); } -?>