From 0780f3b96b3525d6c8355b3276520b60b83229d8 Mon Sep 17 00:00:00 2001 From: Ben Klang Date: Thu, 30 Jun 2005 23:42:38 +0000 Subject: [PATCH] The rest of the commit git-svn-id: https://svn.alkaloid.net/gpl/shout/trunk@40 06cd67b6-e706-0410-b29e-9de616bca6e9 --- lib/Users.php | 43 +++++++++++++++++++++++++++++++++++++++++++ templates/common-header.inc | 32 ++++++++++++++++++++++++++++++++ templates/menu.inc | 5 +++++ 3 files changed, 80 insertions(+) create mode 100644 lib/Users.php create mode 100644 templates/common-header.inc create mode 100644 templates/menu.inc diff --git a/lib/Users.php b/lib/Users.php new file mode 100644 index 000000000..044a7d9e4 --- /dev/null +++ b/lib/Users.php @@ -0,0 +1,43 @@ + + * + * See the enclosed file LICENSE for license information (BSD). If you + * did not receive this file, see http://www.horde.org/licenses/bsdl.php. + * + * @author Robert E. Coyle + * @package Whups + */ +class SelectContextForm extends Horde_Form { + + var $_useFormToken = false; + + function CreateStep1Form(&$vars) + { + global $whups; + + parent::Horde_Form($vars, _("Choose a context")); + + $contexts = $shout->getContexts("customer"); + if (count($contexts)) { + $contexts = &$this->addVariable(_("Context"), 'context', 'enum', + true, false, null, array($contexts, _("Choose:"))); + if (!Auth::getAuth()) { + $this->addVariable(_("Your Email Address"), 'user_email', + 'email', true); + } else { + require_once 'Horde/Form/Action.php'; + $contexts->setAction(Horde_Form_Action::factory('submit')); + } + } else { + $this->addVariable(_("Context"), 'context', 'invalid', true, + false, null, array(_("There are no contexts which you have +permission to view."))); + } + } + +} \ No newline at end of file diff --git a/templates/common-header.inc b/templates/common-header.inc new file mode 100644 index 000000000..58a1be412 --- /dev/null +++ b/templates/common-header.inc @@ -0,0 +1,32 @@ + + + + + +' : '' ?> + + get('name'); + if (!empty($title)) $page_title .= ' :: ' . $title; + if (!empty($refresh_time) && !empty($refresh_url)) { + echo "\n"; + } + + Horde::includeScriptFiles(); + + ?> + <?php echo $page_title ?> + + + +> diff --git a/templates/menu.inc b/templates/menu.inc new file mode 100644 index 000000000..5c38df53d --- /dev/null +++ b/templates/menu.inc @@ -0,0 +1,5 @@ + +
+notify(array('listeners' => 'status')) ?> \ No newline at end of file -- 2.11.0