Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Removed smarty from all end-user facing pages

  • Loading branch information...
commit e179937c2f0802c10e812958448ceb76c0e8983b 1 parent 05ad753
@soonick authored
Showing with 669 additions and 494 deletions.
  1. +48 −35 activate.php
  2. +4 −5 confirm.php
  3. +46 −40 login.php
  4. +9 −10 mailings.php
  5. +5 −5 pending.php
  6. +34 −31 process.php
  7. +1 −0  subscribe.php
  8. +14 −0 themes/default/inc/user.footer.php
  9. +0 −14 themes/default/inc/user.footer.tpl
  10. +23 −0 themes/default/inc/user.header.php
  11. +0 −26 themes/default/inc/user.header.tpl
  12. +1 −1  themes/default/subscribe/form.subscribe.php
  13. +109 −0 themes/default/subscribe/form.update.php
  14. +0 −66 themes/default/subscribe/form.update.tpl
  15. +32 −0 themes/default/user/activate.php
  16. +0 −17 themes/default/user/activate.tpl
  17. +23 −0 themes/default/user/confirm.php
  18. +0 −10 themes/default/user/confirm.tpl
  19. +29 −17 themes/default/user/login.php
  20. +0 −28 themes/default/user/login.tpl
  21. +94 −0 themes/default/user/mailings.php
  22. +0 −69 themes/default/user/mailings.tpl
  23. +42 −0 themes/default/user/pending.php
  24. +0 −27 themes/default/user/pending.tpl
  25. +48 −0 themes/default/user/process.php
  26. +0 −19 themes/default/user/process.tpl
  27. +80 −0 themes/default/user/update.php
  28. +0 −51 themes/default/user/update.tpl
  29. +27 −23 update.php
View
83 activate.php
@@ -1,51 +1,61 @@
<?php
/**
- * Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * Original Code Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * released originally under GPLV2
*
- * This file is part of poMMo (http://www.pommo.org)
+ * This file is part of poMMo.
+ *
+ * poMMo is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * poMMo is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Pommo. If not, see <http://www.gnu.org/licenses/>.
*
- * poMMo is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published
- * by the Free Software Foundation; either version 2, or any later version.
- *
- * poMMo is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
- * the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with program; see the file docs/LICENSE. If not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ * This fork is from https://github.com/soonick/poMMo
+ * Please see docs/contribs for Contributors
+ *
*/
/**********************************
INITIALIZATION METHODS
*********************************/
-require ('bootstrap.php');
-require_once(Pommo::$_baseDir.'classes/Pommo_Subscribers.php');
-require_once(Pommo::$_baseDir . 'classes/Pommo_Helper_Messages.php');
+require 'bootstrap.php';
+require_once Pommo::$_baseDir.'classes/Pommo_Subscribers.php';
+require_once Pommo::$_baseDir . 'classes/Pommo_Helper_Messages.php';
Pommo::init(array('authLevel' => 0,'noSession' => true));
-$logger = & Pommo::$_logger;
-$dbo = & Pommo::$_dbo;
+$logger = Pommo::$_logger;
+$dbo = Pommo::$_dbo;
/**********************************
SETUP TEMPLATE, PAGE
*********************************/
-require_once(Pommo::$_baseDir.'classes/Pommo_Template.php');
-$smarty = new Pommo_Template();
+require_once Pommo::$_baseDir.'classes/Pommo_Template.php';
+$view = new Pommo_Template();
// make sure email/login is valid
-$subscriber = current(Pommo_Subscribers::get(array('email' => (empty($_REQUEST['email'])) ? '0' : $_REQUEST['email'], 'status' => 1)));
+$subscriber = current(Pommo_Subscribers::get(array (
+ 'email' => (empty($_REQUEST['email'])) ? '0' : $_REQUEST['email'], 'status' => 1
+)));
+
if (empty($subscriber))
+{
Pommo::redirect('login.php');
+}
-// see if an anctivation email was sent to this subscriber in the last 2 minutes;
-$query = "
- SELECT
+// see if an activation email was sent to this subscriber in the last 2 minutes;
+$query =
+ 'SELECT
*
FROM
- ".$dbo->table['scratch']."
+ '.$dbo->table['scratch']."
WHERE
`type`=1
AND `int`=%i
@@ -55,11 +65,15 @@
$test = $dbo->query($query,0);
// attempt to send activation code if once has not recently been sent
-if (empty($test)) {
+if (empty($test))
+{
$code = Pommo_Subscribers::getActCode($subscriber);
- if (Pommo_Helper_Messages::sendMessage(array('to' => $subscriber['email'], 'code' => $code, 'type' => 'activate'))) {
-
- $smarty->assign('sent', true);
+ if (Pommo_Helper_Messages::sendMessage(array (
+ 'to' => $subscriber['email'],
+ 'code' => $code,
+ 'type' => 'activate')))
+ {
+ $view->assign('sent', true);
// timestamp this activation email
$query = "
@@ -82,11 +96,10 @@
}
}
else {
- $smarty->assign('sent', false);
+ $view->assign('sent', false);
}
-$smarty->assign('email', $subscriber['email']);
-$smarty->display('user/activate.tpl');
-Pommo::kill();
-?>
+$view->assign('email', $subscriber['email']);
+$view->display('user/activate');
+
View
9 confirm.php
@@ -39,7 +39,7 @@
if (empty($_GET['code'])) {
$logger->addMsg(Pommo::_T('No code given.'));
- $smarty->display('user/confirm.tpl');
+ $smarty->display('user/confirm');
Pommo::kill();
}
@@ -48,7 +48,7 @@
if (!$pending) {
$logger->addMsg(Pommo::_T('Invalid code! Make sure you copied it correctly from the email.'));
- $smarty->display('user/confirm.tpl');
+ $smarty->display('user/confirm');
Pommo::kill();
}
@@ -98,6 +98,5 @@
break;
}
}
-$smarty->display('user/confirm.tpl');
-Pommo::kill();
-?>
+$smarty->display('user/confirm');
+
View
86 login.php
@@ -1,65 +1,69 @@
<?php
/**
- * Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * Original Code Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * released originally under GPLV2
*
- * This file is part of poMMo (http://www.pommo.org)
+ * This file is part of poMMo.
+ *
+ * poMMo is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * poMMo is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Pommo. If not, see <http://www.gnu.org/licenses/>.
*
- * poMMo is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published
- * by the Free Software Foundation; either version 2, or any later version.
- *
- * poMMo is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
- * the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with program; see the file docs/LICENSE. If not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ * This fork is from https://github.com/soonick/poMMo
+ * Please see docs/contribs for Contributors
+ *
*/
/**********************************
INITIALIZATION METHODS
*********************************/
-require('bootstrap.php');
-require_once(Pommo::$_baseDir.'classes/Pommo_Pending.php');
+require 'bootstrap.php';
+require_once Pommo::$_baseDir.'classes/Pommo_Pending.php';
Pommo::init(array('authLevel' => 0, 'noSession' => true));
-$logger = & Pommo::$_logger;
-$dbo = & Pommo::$_dbo;
+$logger = Pommo::$_logger;
+$dbo = Pommo::$_dbo;
session_start(); // required by smartyValidate. TODO -> move to prepareForForm() ??
/**********************************
SETUP TEMPLATE, PAGE
*********************************/
-require_once(Pommo::$_baseDir.'classes/Pommo_Template.php');
-$smarty = new Pommo_Template();
-$smarty->assign('title', Pommo::$_config['site_name'] . ' - ' . Pommo::_T('subscriber logon'));
+require_once Pommo::$_baseDir.'classes/Pommo_Template.php';
+$view = new Pommo_Template();
+$view->assign('title', Pommo::$_config['site_name'] . ' - ' . Pommo::_T('subscriber logon'));
-$smarty->prepareForForm();
+$view->prepareForForm();
-if (!SmartyValidate :: is_registered_form() || empty($_POST)) {
+if (empty($_POST)) {
// ___ USER HAS NOT SENT FORM ___
- SmartyValidate :: connect($smarty, true);
- SmartyValidate :: register_validator('email', 'Email', 'isEmail', false, false, 'trim');
- $formError = array ();
- $formError['email'] = Pommo::_T('Invalid email address');
- $smarty->assign('formError', $formError);
-
// Assign email to form if pre-provided
if (isset($_REQUEST['Email']))
- $smarty->assign('Email',$_REQUEST['Email']);
+ $view->assign('Email',$_REQUEST['Email']);
elseif (isset($_REQUEST['email']))
- $smarty->assign('Email',$_REQUEST['email']);
+ $view->assign('Email',$_REQUEST['email']);
} else {
// ___ USER HAS SENT FORM ___
- SmartyValidate :: connect($smarty);
- if (SmartyValidate :: is_valid($_POST)) {
- // __ FORM IS VALID __
- if (Pommo_Helper::isDupe($_POST['Email'])) {
+ require_once Pommo::$_baseDir.'classes/Pommo_Validate.php';
+ $validator = new Pommo_Validate();
+ $validator->setPost($_POST);
+ $validator->addData('Email', 'Email', false);
+
+ if ($result = $validator->checkData())
+ {
+ if (Pommo_Helper::isDupe($_POST['Email']))
+ {
if (Pommo_Pending::isEmailPending($_POST['Email'])) {
$input = urlencode(serialize(array('Email' => $_POST['Email'])));
SmartyValidate :: disconnect();
@@ -71,14 +75,16 @@
Pommo::redirect('activate.php?email='.$_POST['Email']);
}
}
- else {
+ else
+ {
// __ REPORT STATUS
$logger->addMsg(Pommo::_T('Email address not found! Please try again.'));
$logger->addMsg(sprintf(Pommo::_T('To subscribe, %sclick here%s'),'<a href="'.Pommo::$_baseUrl.'subscribe.php?Email='.$_POST['Email'].'">','</a>'));
}
}
- $smarty->assign($_POST);
+
+ $view->assign($_POST);
}
-$smarty->display('user/login.tpl');
-Pommo::kill();
-?>
+
+$view->display('user/login');
+
View
19 mailings.php
@@ -38,8 +38,8 @@
SETUP TEMPLATE, PAGE
*********************************/
require_once(Pommo::$_baseDir.'classes/Pommo_Template.php');
-$smarty = new Pommo_Template();
-$smarty->assign('title', Pommo::$_config['site_name'] . ' - ' . Pommo::_T('Mailing History'));
+$view = new Pommo_Template();
+$view->assign('title', Pommo::$_config['site_name'] . ' - ' . Pommo::_T('Mailing History'));
/** SET PAGE STATE
* limit - # of mailings per page
@@ -82,8 +82,8 @@
}
- $smarty->assign($input);
- $smarty->display('inc/mailing.tpl');
+ $view->assign($input);
+ $view->display('inc/mailing');
Pommo::kill();
}
@@ -113,10 +113,9 @@
ceil($tally/$state['limit']) :
0;
-$smarty->assign('state',$state);
-$smarty->assign('tally',$tally);
-$smarty->assign('mailings', $mailings);
+$view->assign('state',$state);
+$view->assign('tally',$tally);
+$view->assign('mailings', $mailings);
+
+$view->display('user/mailings');
-$smarty->display('user/mailings.tpl');
-Pommo::kill();
-?>
View
10 pending.php
@@ -32,7 +32,7 @@
SETUP TEMPLATE, PAGE
*********************************/
require_once(Pommo::$_baseDir.'classes/Pommo_Template.php');
-$smarty = new Pommo_Template();
+$view = new Pommo_Template();
$input = (isset($_GET['input'])) ?
unserialize($_GET['input']) : array('Email' => NULL);
@@ -40,6 +40,7 @@
$pending = (isset($input['adminID'])) ? // check to see if we're resetting admin password
Pommo_Pending::getBySubID(0) :
Pommo_Pending::getByEmail($input['Email']);
+
if (!$pending)
Pommo::redirect('login.php');
@@ -69,10 +70,9 @@
if (Pommo_Pending::cancel($pending))
$logger->addMsg(sprintf(Pommo::_T('Your %s has been cancelled.'),$msg));
}
- $smarty->assign('nodisplay',TRUE);
+ $view->assign('nodisplay',TRUE);
} else {
$logger->addMsg(sprintf(Pommo::_T('Your %s is still pending. To complete this request, please review the confirmation email sent to %s.'), $msg, $input['Email']));
}
-$smarty->display('user/pending.tpl');
-Pommo::kill();
-?>
+$view->display('user/pending');
+
View
65 process.php
@@ -1,39 +1,44 @@
<?php
/**
- * Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * Original Code Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * released originally under GPLV2
*
- * This file is part of poMMo (http://www.pommo.org)
+ * This file is part of poMMo.
+ *
+ * poMMo is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * poMMo is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Pommo. If not, see <http://www.gnu.org/licenses/>.
*
- * poMMo is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published
- * by the Free Software Foundation; either version 2, or any later version.
- *
- * poMMo is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
- * the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with program; see the file docs/LICENSE. If not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ * This fork is from https://github.com/soonick/poMMo
+ * Please see docs/contribs for Contributors
+ *
*/
/**********************************
INITIALIZATION METHODS
*********************************/
-require ('bootstrap.php');
-require_once(Pommo::$_baseDir.'classes/Pommo_Validate.php');
-require_once(Pommo::$_baseDir.'classes/Pommo_Subscribers.php');
+require 'bootstrap.php';
+require_once Pommo::$_baseDir.'classes/Pommo_Validate.php';
+require_once Pommo::$_baseDir.'classes/Pommo_Subscribers.php';
Pommo::init(array('authLevel' => 0,'noSession' => true));
-$logger = & Pommo::$_logger;
-$dbo = & Pommo::$_dbo;
+$logger = Pommo::$_logger;
+$dbo = Pommo::$_dbo;
/**********************************
SETUP TEMPLATE, PAGE
*********************************/
-require_once(Pommo::$_baseDir.'classes/Pommo_Template.php');
-$smarty = new Pommo_Template();
+require_once Pommo::$_baseDir.'classes/Pommo_Template.php';
+$view = new Pommo_Template();
// attempt to detect if referer was set
// TODO; enable HTTP_REFERER after stripping out ?input= tags. These will continually repeat
@@ -41,7 +46,7 @@
$referer = (!empty($_POST['bmReferer'])) ? $_POST['bmReferer'] : Pommo::$_http.Pommo::$_baseUrl.'subscribe.php';
// append stored input
-$smarty->assign('referer',$referer.'?input='.urlencode(serialize($_POST)));
+$view->assign('referer',$referer.'?input='.urlencode(serialize($_POST)));
/**********************************
VALIDATE INPUT
@@ -65,14 +70,14 @@
// ** check if email already exists in DB ("duplicates are bad..")
if (Pommo_Helper::isDupe($subscriber['email'])) {
$logger->addErr(Pommo::_T('Email address already exists. Duplicates are not allowed.'));
- $smarty->assign('dupe', TRUE);
+ $view->assign('dupe', TRUE);
}
// check if errors exist with data, if so print results and die.
if ($logger->isErr() || !Pommo_Validate::subscriberData($subscriber['data'], array(
'active' => FALSE))) {
- $smarty->assign('back', TRUE);
- $smarty->display('user/process.tpl');
+ $view->assign('back', TRUE);
+ $view->display('user/process');
Pommo::kill();
}
@@ -101,7 +106,7 @@
$id = Pommo_Subscribers::add($subscriber);
if (!$id) {
$logger->addErr('Error adding subscriber! Please contact the administrator.');
- $smarty->assign('back', TRUE);
+ $view->assign('back', TRUE);
}
else {
@@ -117,7 +122,7 @@
Pommo::redirect($config['site_confirm']);
}
else {
- $smarty->assign('back', TRUE);
+ $view->assign('back', TRUE);
// delete the subscriber
Pommo_Subscribers::delete($id);
}
@@ -126,7 +131,7 @@
else { // no email confirmation required
if (!Pommo_Subscribers::add($subscriber)) {
$logger->addErr('Error adding subscriber! Please contact the administrator.');
- $smarty->assign('back', TRUE);
+ $view->assign('back', TRUE);
}
else {
@@ -143,7 +148,5 @@
}
}
-$smarty->display('user/process.tpl');
-Pommo::kill();
+$view->display('user/process');
-?>
View
1  subscribe.php
@@ -41,3 +41,4 @@
$view->prepareForSubscribeForm();
$view->display('subscribe/subscribe');
+
View
14 themes/default/inc/user.footer.php
@@ -0,0 +1,14 @@
+ <br class="clear" />
+
+ </div>
+ <!-- end content -->
+
+ <div id="footer">
+
+ <p>- <?php echo _('Page fueled by poMMo mailing management software'); ?> -</p>
+
+ </div>
+ <!-- end footer -->
+
+</body>
+</html>
View
14 themes/default/inc/user.footer.tpl
@@ -1,14 +0,0 @@
-<br class="clear" />
-
-</div>
-<!-- end content -->
-
-<div id="footer">
-
-<p>- {t}Page fueled by poMMo mailing management software{/t} -</p>
-
-</div>
-<!-- end footer -->
-
-</body>
-</html>
View
23 themes/default/inc/user.header.php
@@ -0,0 +1,23 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html>
+<head>
+ <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
+ <title><?php echo $this->title; ?></title>
+ <link href="<?php echo $this->url['theme']['shared']; ?>css/default.user.css"
+ type="text/css" rel="stylesheet" />
+ <?php
+ echo $this->capturedHead;
+ ?>
+</head>
+<body>
+ <div id="header">
+ <h1>
+ <a href="<?php echo $this->config['site_url']; ?>">
+ <?php
+ echo $this->config['site_name'];
+ ?>
+ </a>
+ </h1>
+ </div>
+ <div id="content">
View
26 themes/default/inc/user.header.tpl
@@ -1,26 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
-<title>{$title}</title>
-<link type="text/css" rel="stylesheet" href="{$url.theme.shared}css/default.user.css" />
-
-{* If $head has been captured, print its contents here. Capture $head via templates
-using {capture name=head}..content..{/capture} before including this header file.
-Useful for properly including javascripts and CSS in the HTML <head> *}
-
-{$smarty.capture.head}
-
-{* Include HTML FORM styling and javascript from shared theme directory when template
-is prepared to include a form from the parent PHP script *}
-
-</head>
-<body>
-
-<div id="header">
-
-<h1><a href="{$config.site_url}">{$config.site_name}</a></h1>
-
-</div>
-
-<div id="content">
View
2  themes/default/subscribe/form.subscribe.php
@@ -40,7 +40,7 @@
{
echo '<strong class="required">';
}
- echo $field['prompt'];
+ echo $field['name'];
if ('on' == $field['required'])
{
echo '</strong>';
View
109 themes/default/subscribe/form.update.php
@@ -0,0 +1,109 @@
+<div id="subscribeForm">
+
+ <form method="post" action="">
+ <input type="hidden" name="formSubmitted" value="1" />
+ <input type="hidden" name="code" value="<?php echo $this->code; ?>" />
+
+ <fieldset>
+ <legend><?php echo _('Your Information'); ?></legend>
+ <input type="hidden" name="updateForm" value="true" />
+
+ <div class="notes">
+ <p>
+ <?php
+ echo sprintf(_('Fields marked like %s this %s are required.'),
+ '<span class="required">', '</span>');
+ ?>
+ </p>
+ </div>
+
+ <div>
+ <label class="required" for="email">
+ <strong><?php echo _('Your Email:'); ?></strong>
+ </label>
+ <input type="text" size="32" maxlength="60" name="email" id="email"
+ value="<?php echo htmlentities($this->email); ?>"
+ readonly="readonly" />
+ </div>
+
+ <div>
+ <label for="email"><?php echo _('New Email:'); ?></label>
+ <input type="text" size="32" maxlength="60" name="newemail"
+ id="newemail" value="<?php echo $this->newemail; ?>" />
+ </div>
+
+ <div>
+ <label for="email"><?php echo _('Verify New Email:'); ?></label>
+ <input type="text" size="32" maxlength="60" name="newemail2"
+ id="newemail2" value="<?php echo $this->newemail2; ?>" />
+ </div>
+
+ <?php
+ foreach ($this->fields as $key => $field)
+ {
+ ?>
+ <div>
+ <!-- DON'T DISPLAY COMMENT FIELDS ON UPDATE FORM. A COMMENT FIELD
+ IS PROVIDED @ user/update.php FOR UNSUBSCRIBE -->
+ <?php
+ if ('comment' != $field['type'])
+ {
+ ?>
+ <label
+ <?php
+ if ('on' == $field['required'])
+ {
+ echo 'class="required"';
+ }
+ ?> for="field<?php echo $key; ?>">
+ <?php echo $field['name']; ?>:
+ </label>
+ <?php
+ }
+
+ switch ($field['type'])
+ {
+ case 'checkbox':
+ echo '<input type="checkbox" name="d['.$key.']"
+ id="field'.$key.'"'.('on' == $this->d[$key] ?
+ ' checked="checked" ' : '').' />';
+ break;
+ case 'multiple':
+ echo '<select name="d['.$key.']" id="field'.$key.'">';
+ echo
+ '<option value="">'
+ ._('Choose Selection')
+ .'</option>';
+ foreach ($field['array'] as $option)
+ {
+ echo
+ '<option '.($option == $this->d[$key] ?
+ ' selected="selected" ' : '').'>'
+ .$option
+ .'</option>';
+ }
+ echo '</select>';
+ break;
+ default:
+ echo '<input type="text" '.('date' == $field['type'] ?
+ 'class="text datepicker" size="12" ' :
+ 'size="32" ').'name="d['.$key.']"
+ id="field'.$key.'" '.(isset($this->d[$key]) ?
+ ' value="'.htmlentities($this->d[$key]).'" ' :
+ '').' />';
+ break;
+ }
+ ?>
+ </div>
+ <?php
+ }
+ ?>
+ </fieldset>
+
+ <div class="buttons">
+ <input type="submit" value="<?php echo _('Update Records'); ?>"
+ name="update" />
+ </div>
+ </form>
+</div>
+
View
66 themes/default/subscribe/form.update.tpl
@@ -1,66 +0,0 @@
-<div id="subscribeForm">
-
-<form method="post" action="">
-<input type="hidden" name="formSubmitted" value="1" />
-<input type="hidden" name="code" value="{$code}" />
-
-<fieldset>
-<legend>{t}Your Information{/t}</legend>
-<input type="hidden" name="updateForm" value="true" />
-
-<div class="notes">
-<p>{t escape=no 1="<span class=\"required\">" 2="</span>"}Fields marked like %1 this %2 are required.{/t}</p>
-</div>
-
-<div>
-<label class="required" for="email"><strong>{t}Your Email:{/t}</strong></label>
-<input type="text" size="32" maxlength="60" name="email" id="email" value="{$email|escape}" readonly="readonly" />
-</div>
-
-<div>
-<label for="email">{t}New Email:{/t}</label>
-<input type="text" size="32" maxlength="60" name="newemail" id="newemail" value="{$newemail|escape}" />
-</div>
-
-<div>
-<label for="email">{t}Verify New Email:{/t}</label>
-<input type="text" size="32" maxlength="60" name="newemail2" id="newemail2" value="{$newemail2|escape}" />
-</div>
-
-{foreach name=fields from=$fields key=key item=field}
-<div>
-{* DON'T DISPLAY COMMENT FIELDS ON UPDATE FORM. A COMMENT FIELD IS PROVIDED @ user/update.tpl FOR UNSUBSCRIBE *}
-{if $field.type != 'comment'}
-<label{if $field.required == 'on'} class="required"{/if} for="field{$key}">{$field.prompt}:</label>
-{/if}
-
-
-{if $field.type == 'checkbox'}
-<input type="checkbox" name="d[{$key}]" id="field{$key}"{if $d.$key == "on"} checked="checked"{/if} />
-
-{elseif $field.type == 'multiple'}
-<select name="d[{$key}]" id="field{$key}">
-<option value="">{t}Choose Selection{/t}</option>
-{foreach from=$field.array item=option}
-<option{if $d.$key == $option} selected="selected"{/if}>{$option}</option>
-{/foreach}
-</select>
-
-{else}
-<input type="text" {if $field.type == 'date'}class="text datepicker" size=12 {else}size="32" {/if} name="d[{$key}]" id="field{$key}"{if isset($d.$key)} value="{$d.$key|escape}"{/if} />
-
-{/if}
-</div>
-
-{/foreach}
-
-</fieldset>
-
-<div class="buttons">
-
-<input type="submit" name="update" value="{t}Update Records{/t}" />
-
-</div>
-
-</form>
-</div>
View
32 themes/default/user/activate.php
@@ -0,0 +1,32 @@
+<?php
+
+include $this->template_dir.'/inc/user.header.php';
+
+?>
+
+<h2><?php echo _('Update Activation'); ?></h2>
+
+<p>
+ <?php echo _('We require that you verify your email address before
+ unsubscribing or updating your records. This extra step is necessary
+ to maintain your privacy, and to protect you against fraudulent
+ activity.'); ?>
+</p>
+<?php
+
+include $this->template_dir.'/inc/messages.php';
+
+if (!$this->sent)
+{
+?>
+ <p>
+ <?php
+ echo sprintf(_('An activation email has recently been sent to %s.
+ Please check your inbox.'), '<strong>'.$this->email.'</strong>');
+ ?>
+ </p>
+<?php
+}
+
+include $this->template_dir.'/inc/user.footer.php';
+
View
17 themes/default/user/activate.tpl
@@ -1,17 +0,0 @@
-{include file="inc/user.header.tpl"}
-
-<h2>{t}Update Activation{/t}</h2>
-
-<p>
-{t}We require that you verify your email address before unsubscribing or updating your records. This extra step is necessary to maintain your privacy, and to protect you against fraudulent activity.{/t}
-</p>
-
-{include file="inc/messages.tpl"}
-
-{if !$sent}
- <p>
- {t escape=no 1="<strong>`$email`</strong>"}An activation email has recently been sent to %1. Please check your inbox.{/t}
- </p>
-{/if}
-
-{include file="inc/user.footer.tpl"}
View
23 themes/default/user/confirm.php
@@ -0,0 +1,23 @@
+<?php
+
+include $this->template_dir.'/inc/user.header.php';
+
+?>
+
+<h2><?php echo _('Subscriber Confirmation'); ?></h2>
+
+<p>
+ <a href="<?php echo $this->config['site_url']; ?>">
+ <img src="<?php echo $this->url['theme']['shared']; ?>images/icons/back.png"
+ alt="back icon" class="navimage" />
+ <?php
+ echo sprintf(_('Return to %s'), $this->config['site_name']);
+ ?>
+ </a>
+</p>
+<?php
+
+include $this->template_dir.'/inc/messages.php';
+
+include $this->template_dir.'/inc/user.footer.php';
+
View
10 themes/default/user/confirm.tpl
@@ -1,10 +0,0 @@
-{include file="inc/user.header.tpl"}
-
-<h2>{t}Subscriber Confirmation{/t}</h2>
-
-<p><a href="{$config.site_url}"><img src="{$url.theme.shared}images/icons/back.png" alt="back icon" class="navimage" /> {t website=$config.site_name}Return to %1{/t}</a></p>
-
-{include file="inc/messages.tpl"}
-
-
-{include file="inc/user.footer.tpl"}
View
46 themes/default/user/login.php
@@ -1,28 +1,40 @@
-{include file="inc/user.header.tpl"}
+<?php
-<h2>{t}Subscriber Login{/t}</h2>
+include $this->template_dir.'/inc/user.header.php';
-<p>{t}In order to check your subscription status, update your information, or unsubscribe, you must enter your email address in the field below.{/t}</p>
+?>
-{include file="inc/messages.tpl"}
+<h2><?php echo _('Subscriber Login'); ?></h2>
-<form method="post" action="">
-<fieldset>
-<legend>{t}Login{/t}</legend>
+<p><?php echo _('In order to check your subscription status, update your
+ information, or unsubscribe, you must enter your email address in the
+ field below.'); ?></p>
-<div>
-<label for="email"><strong class="required">{t}Your Email:{/t}</strong> <span class="error">{validate id="email" message=$formError.email}</span></label>
-<input type="text"name="Email" id="email" value="{$Email|escape}" size="32" maxlength="60" />
-</div>
+<?php
-</fieldset>
+include $this->template_dir.'/inc/messages.php';
-<div class="buttons">
+?>
-<input type="submit" value="{t}Login{/t}" />
+<form method="post" action="">
+ <fieldset>
+ <legend><?php echo _('Login'); ?></legend>
+
+ <div>
+ <label for="email">
+ <strong class="required"><?php echo _('Your Email:'); ?></strong>
+ </label>
+ <input type="text" name="Email" id="email" size="32" maxlength="60"
+ value="<?php echo htmlentities($this->Email); ?>" />
+ </div>
+ </fieldset>
+
+ <div class="buttons">
+ <input type="submit" value="<?php echo _('Login'); ?>" />
+ </div>
+</form>
-</div>
+<?php
-</form>
+include $this->template_dir.'/inc/user.footer.php';
-{include file="inc/user.footer.tpl"}
View
28 themes/default/user/login.tpl
@@ -1,28 +0,0 @@
-{include file="inc/user.header.tpl"}
-
-<h2>{t}Subscriber Login{/t}</h2>
-
-<p>{t}In order to check your subscription status, update your information, or unsubscribe, you must enter your email address in the field below.{/t}</p>
-
-{include file="inc/messages.tpl"}
-
-<form method="post" action="">
-<fieldset>
-<legend>{t}Login{/t}</legend>
-
-<div>
-<label for="email"><strong class="required">{t}Your Email:{/t}</strong> <span class="error">{validate id="email" message=$formError.email}</span></label>
-<input type="text"name="Email" id="email" value="{$Email|escape}" size="32" maxlength="60" />
-</div>
-
-</fieldset>
-
-<div class="buttons">
-
-<input type="submit" value="{t}Login{/t}" />
-
-</div>
-
-</form>
-
-{include file="inc/user.footer.tpl"}
View
94 themes/default/user/mailings.php
@@ -0,0 +1,94 @@
+<?php
+
+ob_start();
+
+?>
+<script type="text/javascript" src="<?php echo $this->url['theme']['shared'];
+ ?>js/jq/jquery.js"></script>
+<script type="text/javascript" src="<?php echo $this->url['theme']['shared'];
+ ?>js/pommo.js"></script>
+<?php
+
+include $this->template_dir.'/inc/ui.grid.php';
+
+$this->capturedHead = ob_get_clean();
+
+$this->sidebar = false;
+include $this->template_dir.'/inc/user.header.php';
+?>
+
+<h2><?php echo _('Mailings History'); ?></h2>
+
+<?php
+
+include $this->template_dir.'/inc/messages.php';
+
+if ($this->tally > 0)
+{
+?>
+ <table id="grid" class="scroll" cellpadding="0" cellspacing="0"></table>
+ <div id="gridPager" class="scroll" style="text-align:center;"></div>
+
+ <ul class="inpage_menu">
+ <li>
+ <a href="ajax/mailing_preview.php" class="visit">
+ <img src="<?php echo $this->url['theme']['shared'];
+ ?>images/icons/mailing_small.png"/>
+ <?php echo _('View Mailing'); ?>
+ </a>
+ </li>
+ </ul>
+
+ <script type="text/javascript">
+ $().ready(function() {
+
+ var p = {
+ colNames: [
+ 'ID',
+ '<?php echo _('Subject'); ?>',
+ '<?php echo _('Sent'); ?>'
+ ],
+ rowNum: <?php echo $this->state['limit']; ?>,
+ rowList: [],
+ colModel: [
+ {name: 'id', index: 'id', hidden: true, width: 1},
+ {name: 'subject', width: 150},
+ {name: 'start', width: 130}
+ ],
+ url: 'ajax/mailing.list.php'
+ };
+
+ poMMo.grid = PommoGrid.init('#grid',p);
+ });
+ </script>
+
+ <script type="text/javascript">
+ $().ready(function(){
+ $('a.visit').click(function(){
+ var rows = poMMo.grid.getRowIDs();
+ if(rows) {
+ // serialize the data
+ var data = $.param({'mailings[]': rows});
+
+ // rewrite the HREF of the clicked element
+ var oldHREF = this.href;
+ this.href += (this.href.match(/\?/) ? "&" : "?") + data
+
+ window.location = this.href;
+ }
+ return false;
+ });
+ });
+
+ </script>
+<?php
+}
+else
+{
+?>
+ <strong><?php echo _('No records returned.'); ?></strong>
+<?php
+}
+
+include $this->template_dir.'/inc/user.footer.php';
+
View
69 themes/default/user/mailings.tpl
@@ -1,69 +0,0 @@
-{capture name=head}{* used to inject content into the HTML <head> *}
-<script type="text/javascript" src="{$url.theme.shared}js/jq/jquery.js"></script>
-<script type="text/javascript" src="{$url.theme.shared}js/pommo.js"></script>
-{include file="inc/ui.grid.tpl"}
-{/capture}
-{include file="inc/user.header.tpl" sidebar='off'}
-
-<h2>{t}Mailings History{/t}</h2>
-
-{include file="inc/messages.tpl"}
-
-{if $tally > 0}
-<table id="grid" class="scroll" cellpadding="0" cellspacing="0"></table>
-<div id="gridPager" class="scroll" style="text-align:center;"></div>
-
-<ul class="inpage_menu">
-<li><a href="ajax/mailing_preview.php" class="visit"><img src="{$url.theme.shared}images/icons/mailing_small.png"/>{t}View Mailing{/t}</a></li>
-</ul>
-
-<script type="text/javascript">
-$().ready(function() {ldelim}
-
- var p = {ldelim}
- colNames: [
- 'ID',
- '{t escape=js}Subject{/t}',
- '{t escape=js}Sent{/t}'
- ],
- rowNum: {$state.limit},
- rowList: [],
- {literal}
- colModel: [
- {name: 'id', index: 'id', hidden: true, width: 1},
- {name: 'subject', width: 150},
- {name: 'start', width: 130}
- ],
- url: 'ajax/mailing.list.php'
- };
-
- poMMo.grid = PommoGrid.init('#grid',p);
-});
-</script>
-
-<script type="text/javascript">
-$().ready(function(){
- $('a.visit').click(function(){
- var rows = poMMo.grid.getRowIDs();
- if(rows) {
- // serialize the data
- var data = $.param({'mailings[]': rows});
-
- // rewrite the HREF of the clicked element
- var oldHREF = this.href;
- this.href += (this.href.match(/\?/) ? "&" : "?") + data
-
- window.location = this.href;
- }
- return false;
- });
-});
-
-</script>
-{/literal}
-
-{else}
-<strong>{t}No records returned.{/t}</strong>
-{/if}
-
-{include file="inc/user.footer.tpl"}
View
42 themes/default/user/pending.php
@@ -0,0 +1,42 @@
+<?php
+
+include $this->template_dir.'/inc/user.header.php';
+
+?>
+
+<h2><?php echo _('Pending Changes'); ?></h2>
+
+<p>
+ <a href="<?php echo $this->config['site_url']; ?>">
+ <img src="<?php echo $this->url['theme']['shared']; ?>images/icons/back.png"
+ alt="back icon" class="navimage" />
+ <?php
+ echo sprintf(_('Return to %s'), $this->config['site_name']);
+ ?>
+ </a>
+</p>
+
+<?php
+
+include $this->template_dir.'/inc/messages.php';
+
+
+if (!$this->nodisplay)
+{
+?>
+ <form method="post" action="">
+ <fieldset>
+ <legend>Pending user</legend>
+ <div class="buttons">
+ <input type="submit" name="reconfirm"
+ value="<?php echo _('SEND another confirmation email'); ?>" />
+ <input type="submit" name="cancel"
+ value="<?php echo _('CANCEL your pending request'); ?>" />
+ </div>
+ </fieldset>
+ </form>
+<?php
+}
+
+include $this->template_dir.'/inc/user.footer.php';
+
View
27 themes/default/user/pending.tpl
@@ -1,27 +0,0 @@
-{include file="inc/user.header.tpl"}
-
-<h2>{t}Pending Changes{/t}</h2>
-
-<p><a href="{$config.site_url}"><img src="{$url.theme.shared}images/icons/back.png" alt="back icon" class="navimage" />{t website=$config.site_name}Return to %1{/t}</a></p>
-
-{include file="inc/messages.tpl"}
-
-{if !$nodisplay}
-<form method="post" action="">
-<fieldset>
-<legend>Pending user</legend>
-
-<div class="buttons">
-
-<input type="submit" name="reconfirm" value="{t}SEND another confirmation email{/t}" />
-
-<input type="submit" name="cancel" value="{t}CANCEL your pending request{/t}" />
-
-</div>
-
-</fieldset>
-
-</form>
-{/if}
-
-{include file="inc/user.footer.tpl"}
View
48 themes/default/user/process.php
@@ -0,0 +1,48 @@
+<?php
+
+include $this->template_dir.'/inc/user.header.php';
+
+?>
+
+<h2><?php echo _('Subscription Review'); ?></h2>
+
+<?php
+if ($this->back)
+{
+?>
+<p>
+ <a href="<?php echo $this->referer; ?>" onClick="history.back(); return false;">
+ <img src="<?php echo $this->url['theme']['shared']; ?>images/icons/back.png"
+ alt="back icon" class="navimage" />
+ <?php echo _('Back to Subscription Form'); ?>
+ </a>
+</p>
+<?php
+}
+else
+{
+?>
+<p>
+ <a href="<?php echo $this->config['site_url']; ?>">
+ <img src="<?php echo $this->url['theme']['shared']; ?>images/icons/back.png"
+ alt="back icon" class="navimage" />
+ <?php
+ echo sprintf(_('Return to %s'), $this->config['site_name']);
+ ?>
+ </a>
+</p>
+<?php
+}
+
+include $this->template_dir.'/inc/messages.php';
+
+if ($this->dupe)
+{
+ echo
+ '<p>'
+ .sprintf(_('%sUpdate your records%s'), '<a href="login.php">', '</a>')
+ .'</p>';
+}
+
+include $this->template_dir.'/inc/user.footer.php';
+
View
19 themes/default/user/process.tpl
@@ -1,19 +0,0 @@
-{include file="inc/user.header.tpl"}
-
-<h2>{t}Subscription Review{/t}</h2>
-
-{if $back}
-<p><a href="{$referer}" onClick="history.back(); return false;"><img src="{$url.theme.shared}images/icons/back.png" alt="back icon" class="navimage" /> {t}Back to Subscription Form{/t}</a></p>
-
-{else}
-<p><a href="{$config.site_url}"><img src="{$url.theme.shared}images/icons/back.png" alt="back icon" class="navimage" />{t 1=$config.site_name}Return to %1{/t}</a></p>
-
-{/if}
-
-{include file="inc/messages.tpl"}
-
-{if $dupe}
-<p>{t escape=no 1="<a href=\"login.php\">" 2='</a>'}%1Update your records%2{/t}</p>
-{/if}
-
-{include file="inc/user.footer.tpl"}
View
80 themes/default/user/update.php
@@ -0,0 +1,80 @@
+<?php
+ob_start();
+
+if ($this->datePicker)
+{
+ include $this->config['app']['path'].'themes/shared/datepicker/datepicker.php';
+}
+else
+{
+?>
+ <script src="<?php echo $this->url['theme']['shared']; ?>js/jq/jquery.js"
+ type="text/javascript"></script>
+<?php
+}
+
+$this->capturedHead = ob_get_clean();
+
+include $this->template_dir.'/inc/user.header.php';
+
+?>
+
+<h3><?php echo _('Subscriber Update'); ?></h3>
+
+<?php
+
+include $this->template_dir.'/inc/messages.php';
+
+if (!$this->unsubscribe)
+{
+ include $this->template_dir.'/subscribe/form.update.php';
+?>
+
+<form method="post" action="">
+ <input type="hidden" name="email" value="<?php echo $this->email; ?>" />
+ <input type="hidden" name="code" value="<?php echo $this->code; ?>" />
+
+ <h3><?php echo _('Unsubscribe'); ?></h3>
+
+ <label><?php echo _('Comments'); ?>:</label>
+ <textarea name="comments" rows="3" cols="33" maxlength="255"><?php
+ if (isset($this->d['key']))
+ {
+ echo $this->d['key'];
+ }
+ elseif ($this->field['normally'])
+ {
+ echo $this->field['normally'];
+ }
+ ?></textarea>
+
+ <div class="buttons">
+ <button type="submit" name="unsubscribe" value="true" class="warn">
+ <img src="<?php echo $this->url['theme']['shared'];
+ ?>images/icons/nok.png" alt="not ok icon" />
+ <?php
+ echo _('Click to unsubscribe');
+ echo $this->email;
+ ?>
+ </button>
+ </div>
+
+</form>
+<?php
+}
+
+?>
+
+<script type="text/javascript">
+$().ready(function() {
+ $('.warn').click(function() {
+ var str = this.innerHTML;
+ return confirm("<?php echo _('Really unsubscribe?'); ?>");
+ });
+});
+</script>
+
+<?php
+
+include $this->template_dir.'/inc/user.footer.php';
+
View
51 themes/default/user/update.tpl
@@ -1,51 +0,0 @@
-{capture name=head}{* used to inject content into the HTML <head> *}
-{if $datePicker}
-{include file="`$config.app.path`themes/shared/datepicker/datepicker.tpl"}
-{else}
-<script type="text/javascript" src="{$url.theme.shared}js/jq/jquery.js"></script>
-{/if}
-{/capture}
-{include file="inc/user.header.tpl"}
-
-<h3>{t}Subscriber Update{/t}</h3>
-
-{include file="inc/messages.tpl"}
-
-{if !$unsubscribe}
-
-{include file="subscribe/form.update.tpl"}
-
-<form method="post" action="">
-<input type="hidden" name="email" value="{$email}" />
-<input type="hidden" name="code" value="{$code}" />
-
-<h3>{t}Unsubscribe{/t}</h3>
-
-<label>{t}Comments{/t}:</label>
-<textarea name="comments" rows="3" cols="33" maxlength="255">{if isset($d.$key)}{$d.$key}{elseif $field.normally}{$field.normally}{/if}</textarea>
-
-<div class="buttons">
-
-<button type="submit" name="unsubscribe" value="true" class="warn">
-<img src="{$url.theme.shared}images/icons/nok.png" alt="not ok icon" /> {t}Click to unsubscribe{/t} {$Email}
-</button>
-
-</div>
-
-</form>
-
-{/if}
-
-
-{literal}
-<script type="text/javascript">
-$().ready(function() {
- $('.warn').click(function() {
- var str = this.innerHTML;
- return confirm("{/literal}{t}Really unsubscribe?{/t}{literal}");
- });
-});
-</script>
-{/literal}
-
-{include file="inc/user.footer.tpl"}
View
50 update.php
@@ -1,21 +1,26 @@
<?php
/**
- * Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * Original Code Copyright (C) 2005, 2006, 2007, 2008 Brice Burgess <bhb@iceburg.net>
+ * released originally under GPLV2
*
- * This file is part of poMMo (http://www.pommo.org)
+ * This file is part of poMMo.
+ *
+ * poMMo is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * poMMo is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Pommo. If not, see <http://www.gnu.org/licenses/>.
*
- * poMMo is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published
- * by the Free Software Foundation; either version 2, or any later version.
- *
- * poMMo is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
- * the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with program; see the file docs/LICENSE. If not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ * This fork is from https://github.com/soonick/poMMo
+ * Please see docs/contribs for Contributors
+ *
*/
/**********************************
@@ -34,10 +39,10 @@
SETUP TEMPLATE, PAGE
*********************************/
require_once(Pommo::$_baseDir.'classes/Pommo_Template.php');
-$smarty = new Pommo_Template();
+$view = new Pommo_Template();
// Prepare for subscriber form -- load in fields + POST/Saved Subscribe Form
-$smarty->prepareForSubscribeForm();
+$view->prepareForSubscribeForm();
// fetch the subscriber, validate code
$subscriber = current(Pommo_Subscribers::get(array('email' => (empty($_REQUEST['email'])) ? '0' : $_REQUEST['email'], 'status' => 1)));
@@ -57,7 +62,7 @@
$notices = unserialize($config['notices']);
if (!isset($_POST['d']))
- $smarty->assign('d', $subscriber['data']);
+ $view->assign('d', $subscriber['data']);
// check for an update + validate new subscriber info (also converts dates to ints)
if (!empty ($_POST['update']) && Pommo_Validate::subscriberData($_POST['d'])) {
@@ -121,12 +126,11 @@
if ($comments || isset($notices['unsubscribe']) && $notices['unsubscribe'] == 'on')
Pommo_Helper_Messages::notify($notices, $subscriber, 'unsubscribe',$comments);
- $smarty->assign('unsubscribe', TRUE);
+ $view->assign('unsubscribe', TRUE);
}
}
-$smarty->assign('email',$subscriber['email']);
-$smarty->assign('code',$_REQUEST['code']);
-$smarty->display('user/update.tpl');
-Pommo::kill();
-?>
+$view->assign('email',$subscriber['email']);
+$view->assign('code',$_REQUEST['code']);
+$view->display('user/update');
+
Please sign in to comment.
Something went wrong with that request. Please try again.