CustomPages by HeadHodge

Unmaintained CustomPages by HeadHodge 1.0

No permission to download
Q. When I run FileTool my page says 'Not Authorized'. Why?
.
If you downloaded an early version and get a 'Not Authorized' error when running the add-on, edit the following file to disable the security check (I forgot to do this when I uploaded the zip file)

Edit this file:
/root/library/CustomPages/FileTool/Controller.php

In the function isAuthorized(), add 'return true;' to the first line in the function (see code).

Code:
<?php
/********************************************************
*                  File Tool - 1.0                     *
*          by HeadHodge Copyright (c) 2015             *
*                                                      *
*  Liscensed under the MIT License (MIT-LICENSE.txt)   *
*  http://www.opensource.org/licenses/mit-license.php  *
********************************************************/

class CustomPages_FileTool_Controller
{
/******************
** isAuthorized **
******************/
protected static function isAuthorized()
{
//**Add the following line to disable authorization**//
return true; //Remove this line to enable security check

     //Add any security check you like here
    $visitor = XenForo_Visitor::getInstance();
    if($visitor->username != 'HeadHodge') return false;
    return true;
}
Top