iredadmin-ose / controllers /

# Author: Zhang Huangbin <>

import web

class redirect:
    """Make url ending with or without '/' going to the same class."""
    def GET(self, path):
        raise web.seeother('/' + str(path))

class img:
    def GET(self, encoded_img):
        web.header('Content-Type', 'image/jpeg')
        return encoded_img.decode('base64')

class Expired:
    def GET(self):
        web.header('Content-Type', 'text/html')
        return '''<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "">
<html xmlns="">

        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
        <title>License expired</title>

        <p>Your license of iRedAdmin-Pro trial edition expired, please <a href="" target="_blank">purchase a license</a> to continue using iRedAdmin-Pro.</p>