<%pre> #include "setup.h" using namespace vdrlive; using namespace std; <%args> int lastchannel = 0; bool useauth = 0; string login; string pass; <%session scope="global"> bool logged_in(false); <%include>page_init.eh <{ if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html"); }> <%cpp> if ( request.getMethod() == "POST") { LiveSetup().SetLastChannel(lastchannel); LiveSetup().SetUseAuth(useauth); if (useauth) { LiveSetup().SetAdminLogin(login); if (pass != "") LiveSetup().SetAdminPassword(pass); } LiveSetup().SaveSetup(); } pageTitle = tr("Setup"); lastchannel = LiveSetup().GetLastChannel(); login = LiveSetup().GetAdminLogin(); useauth = LiveSetup().UseAuth(); <& pageelems.doc_type &> VDR-Live - <$ pageTitle $> <& tooltip.javascript var=("domTT_styleClass") value=("domTTepg") &> <& pageelems.ajax_js &> <& pageelems.logo &> <& menu active=("setup") &>
<$ tr("Setup") $>
<$ tr("Last channel to display") $>:
<$ tr("Use authentication") $>: onclick="changeduseauth(this)"/>
<%include>page_exit.eh