[Owncloud] How to add JavaScript file to the guest login page
Lukas Reschke
lukas at owncloud.org
Sun Jun 23 09:56:07 UTC 2013
You can perform a check whether the user is logged in in appinfo/app.php
and if the user is not logged in add the script. - Please be aware that
this script will be added to any page that the guest accesses. (e.g. the
file share view)
App Framework:
> if (!$api->isLoggedIn()) {
> $api->addScript('public/login');
> }
ownCloud API:
> if(!\OC_User::isLoggedIn()) {
> \OCP\Util::addscript('appname', 'public/login');
> }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/owncloud/attachments/20130623/a00d1b63/attachment.html>
More information about the Owncloud
mailing list