X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=plugins%2Faddlink_toolbar%2Faddlink_toolbar.php;h=bf8a198a4ed41a44c86320c71117a525f085df7e;hb=ba0fd80732acbff0fcda57a0b31e4edfaa337001;hp=826a0922fd3227308990f16406449aff812190fc;hpb=1b2b44f4bd4457a3dc7b559d3e86cd38644ffe6f;p=github%2Fshaarli%2FShaarli.git diff --git a/plugins/addlink_toolbar/addlink_toolbar.php b/plugins/addlink_toolbar/addlink_toolbar.php old mode 100755 new mode 100644 index 826a0922..bf8a198a --- a/plugins/addlink_toolbar/addlink_toolbar.php +++ b/plugins/addlink_toolbar/addlink_toolbar.php @@ -1,14 +1,41 @@ array( + 'method' => 'GET', + 'action' => '', + 'name' => 'addform', + 'class' => 'addform', + ), + 'inputs' => array( + array( + 'type' => 'text', + 'name' => 'post', + 'placeholder' => 'URI', + ), + array( + 'type' => 'submit', + 'value' => 'Add link', + 'class' => 'bigbutton', + ), + ), + ); + $data['fields_toolbar'][] = $form; } return $data; @@ -18,12 +45,14 @@ function hook_addlink_toolbar_render_header($data) { * When link list is displayed, include markdown CSS. * * @param array $data - includes data. + * * @return mixed - includes data with markdown CSS file added. */ -function hook_addlink_toolbar_render_includes($data) { +function hook_addlink_toolbar_render_includes($data) +{ if ($data['_PAGE_'] == Router::$PAGE_LINKLIST && $data['_LOGGEDIN_'] === true) { $data['css_files'][] = PluginManager::$PLUGINS_PATH . '/addlink_toolbar/addlink_toolbar.css'; } return $data; -} \ No newline at end of file +}