Code Monkey home page Code Monkey logo

shortlink's Introduction

#ShortLink Plugin Installation

Requirements

  1. ilias 5.0 or higher
  2. unibe /Customizing/global
  3. CtrlMainMenu Plugin

CtrlMainMenu Plugin Installation

Clone the CtrlMinMenu plugin into Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/CtrlMainMenu

git clone https://github.com/iLUB/CtrlMainMenu.git

Go to Administration -> Plugins, apply the updates and activate the CtrlMainMenu plugin and checkout the required version you need.

Configure the plugin, remove the unwanted entries like 'search', 'status' and 'settings'.

Installation of the ShortLink Plugin

Clone the ShortLink repository to Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ and checkout the required version you need.

git clone https://github.com/iLUB/ShortLink.git

Go to Administration -> Plugins, apply the updates and activate the ShortLink plugin.

Setup the link to the ShortLink GUI

Got to Administration -> Plugins -> CtrlMainMenu -> Configure

  1. Add Entry
  2. Select Type 'ilCtrl'
  3. Click "Select Type"
  4. Fill in the fields required
  5. Add into filed GUI Classes (WITHOUT WHITESPACES): "ilUIPluginRouterGUI,ilShortLinkGUI"
  6. Click "Save and close"

There is a new ShortLink entry visible at the top menu of ILIAS.

VHost Configuration

It is important that the rewrite_mod is enabled (should be already the case).

Add the rewrite to the end of the rewrite rules in the current VHost.conf

RewriteRule ^/shortlink/([a-zA-Z0-9-]+)?$ https://ilias.yourDomain/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/redirect.php?shortlink=$1 [L]

If you work on localhost add:

RewriteRule ^/shortlink/([a-zA-Z0-9-]+)?$ http://localhost:80/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/redirect.php?shortlink=$1 [L]

shortlink's People

Contributors

okaufman avatar amstutz avatar

Watchers

James Cloos avatar  avatar Tomasz avatar  avatar

shortlink's Issues

Bearbeiten und Löschen eines Shortlinks führt zu Error

Describe the bug
Klicke ich auf "Aktionen > Bearbeiten" eines bestehenden Shortlinks erhalte ich folgende Fehlermeldung:

TypeError thrown with message "ilObjShortLink::readSingleEntry(): Argument #1 ($id) must be of type int, string given, called in /var/www/ilias-next/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/classes/class.ilShortLinkGUI.php on line 202"

Stacktrace:
#12 TypeError in /var/www/ilias-next/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/classes/class.ilObjShortLink.php:93
#11 ilObjShortLink:readSingleEntry in /var/www/ilias-next/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/classes/class.ilShortLinkGUI.php:202
#10 ilShortLinkGUI:edit in /var/www/ilias-next/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/classes/class.ilShortLinkGUI.php:71
#9 ilShortLinkGUI:executeCommand in /var/www/ilias-next/Services/UICore/classes/class.ilCtrl.php:199
#8 ilCtrl:forwardCommand in /var/www/ilias-next/Customizing/global/plugins/Services/UIComponent/UserInterfaceHook/ShortLink/classes/class.ilShortLinkConfigGUI.php:49
#7 ilShortLinkConfigGUI:executeCommand in /var/www/ilias-next/Services/UICore/classes/class.ilCtrl.php:199
#6 ilCtrl:forwardCommand in /var/www/ilias-next/Services/Component/classes/Settings/class.ilObjComponentSettingsGUI.php:162
#5 ilObjComponentSettingsGUI:forwardConfigGUI in /var/www/ilias-next/Services/Component/classes/Settings/class.ilObjComponentSettingsGUI.php:119
#4 ilObjComponentSettingsGUI:executeCommand in /var/www/ilias-next/Services/UICore/classes/class.ilCtrl.php:199
#3 ilCtrl:forwardCommand in /var/www/ilias-next/Services/Administration/classes/class.ilAdministrationGUI.php:237
#2 ilAdministrationGUI:executeCommand in /var/www/ilias-next/Services/UICore/classes/class.ilCtrl.php:199
#1 ilCtrl:forwardCommand in /var/www/ilias-next/Services/UICore/classes/class.ilCtrl.php:174
#0 ilCtrl:callBaseClass in /var/www/ilias-next/ilias.php:24

Gleiche Fehlermeldung erscheint, wenn ich bei einem Shortlink auf "Aktionen > Löschen" klicke.

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'Administration > ILIAS erweitern > Shortlink > Aktionen > Konfigurieren > Bestehender Shortlink > Aktionen > Bearbeiten' oder "Aktionen > Löschen2

Expected behavior
Formular zum Bearbeiten der Shortlink-Felder

Screenshots
Bildschirmfoto 2023-11-30 um 09 54 21

Sprachvariablen nicht sichtbar

Describe the bug
Es fehlen die richtigen Sprachvariablen. Leider führt die Aktion "Sprache neu laden" zu keiner Veränderung. Es werden nach wie vor die Sprachschnippsel (z.B. -ui_uihk_ilubmod_title-) angezeigt.

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'Administration > ILIAS erweitern > Shortlink > Aktionen > Konfigurieren'

Expected behavior
Lesbare Sprachvariablen :)

Screenshots
Bildschirmfoto 2023-11-30 um 08 33 40

Löschen Shortlink: Irritierende Success-Meldung

Problem
Wird ein Shortlink gelöscht, wird als Erfolgsmeldung danach folgendes angezeigt:
"Nachdem der ShortLink gespeichert wurde, kann über www.yourILIASserver.ch/link/"yourShortLink" darauf zugegriffen werden."

Das Löschen hat also keine eigene Erfolgsmeldung, sondern zeigt dieselbe an wie nach dem "Aktualisieren".

Procedure

  1. Öffne Shortlink plugin > Konfigurieren
  2. Klicke neben einem bestehenden Shortlink auf "Aktionen" > "Löschen".
  3. Bestätige mit "Löschen".

Expected Results
Ich würde eine Meldung erwarten wie sonst in ILIAS à la "Shortlink gelöscht".

prio
niedrig

Bildschirmfoto 2024-03-20 um 16 34 46

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.