diff --git a/inc/poche/Poche.class.php b/inc/poche/Poche.class.php index 4fe938fba..5030c9aac 100644 --- a/inc/poche/Poche.class.php +++ b/inc/poche/Poche.class.php @@ -182,7 +182,7 @@ class Poche } if (!$import) { - Tools::redirect(); + Tools::redirect('?view=home'); } break; case 'delete': @@ -558,9 +558,4 @@ class Poche } return $version; } - - function convertURLToBase64($plainurl){ - $convertedURL = base64_encode($plainurl); - $this->action('add', new Url($convertedURL)); - } } \ No newline at end of file diff --git a/index.php b/index.php index e81a92474..7b775c416 100644 --- a/index.php +++ b/index.php @@ -43,9 +43,10 @@ elseif (isset($_GET['import'])) { elseif (isset($_GET['export'])) { $poche->export(); } - -if (isset($_GET['plainurl'])){ - $poche->convertURLToBase64($_GET['plainurl']);} +elseif (isset($_GET['plainurl']) && !empty($_GET['plainurl'])) { + $plain_url = new Url(base64_encode($_GET['plainurl'])); + $poche->action('add', $plain_url); +} # vars to send to templates $tpl_vars = array( diff --git a/tpl/_menu.twig b/tpl/_menu.twig index b39ce35fe..523d63cc6 100644 --- a/tpl/_menu.twig +++ b/tpl/_menu.twig @@ -3,13 +3,5 @@
  • {% trans "favorites" %}
  • {% trans "archive" %}
  • {% trans "config" %}
  • -
  • {% trans "addlink" %}
  • -
  • {% trans "logout" %}
  • - -
    -
    -
    - - -
    -
    \ No newline at end of file +
  • {% trans "logout" %}
  • + \ No newline at end of file diff --git a/tpl/config.twig b/tpl/config.twig index c838c319b..e24e58d41 100644 --- a/tpl/config.twig +++ b/tpl/config.twig @@ -2,13 +2,7 @@ {% block title %}{% trans "config" %}{% endblock %} {% block menu %} - +{% include '_menu.twig' %} {% endblock %} {% block content %}

    {% trans "Poching a link" %}

    @@ -17,6 +11,13 @@
  • firefox: download the extension
  • chrome: download the extension
  • android: download the application
  • +
  • +
    + + + +
    +
  • bookmarklet: drag & drop this link to your bookmarks bar {% trans "poche it!" %}
  • diff --git a/tpl/css/style.css b/tpl/css/style.css index 7d2c143fc..d644814d1 100644 --- a/tpl/css/style.css +++ b/tpl/css/style.css @@ -258,13 +258,14 @@ footer { font-size: 0.8em; } -#inputform{ +#inputform { display: none; text-align:center; max-width:300px; margin-left:auto; margin-right:auto; margin-top:5px; + padding-bottom: 5px; background-color: rgba(0, 0, 0, 0.9); opacity:0.8; color:white; diff --git a/tpl/layout.twig b/tpl/layout.twig index b2484019f..07ca231c0 100644 --- a/tpl/layout.twig +++ b/tpl/layout.twig @@ -12,7 +12,6 @@ {% block title %}{% endblock %} - poche {% include '_head.twig' %} - {% include '_bookmarklet.twig' %}