mirror of
https://github.com/e107inc/e107.git
synced 2025-08-05 14:17:49 +02:00
Sort a few documentation comments
This commit is contained in:
@@ -21,8 +21,6 @@
|
||||
* @package e107
|
||||
* @subpackage e107_handlers
|
||||
* @version $Id: mailout_class.php 11315 2010-02-10 18:18:01Z secretr $;
|
||||
*
|
||||
* @todo last visit date needs XHTML calendar on display, and needs to accept varying input formats
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
|
@@ -11,6 +11,16 @@
|
||||
* $URL$
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/**
|
||||
* e107 Newsletter plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage newsletter
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
|
||||
require_once('../../class2.php');
|
||||
if (!getperms('P'))
|
||||
{
|
||||
|
@@ -1,232 +1,232 @@
|
||||
<?php
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2010 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Newsletter plugin - mailout function
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/newsletter/e_mailout.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* e107 Newsletter plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage event_calendar
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
|
||||
|
||||
include_lan(e_PLUGIN.'/newsletter/languages/English_admin_newsletter.php');
|
||||
|
||||
/*
|
||||
Class for newsletter mailout function
|
||||
|
||||
Allows admins to send mail to those subscribed to one or more newsletters
|
||||
*/
|
||||
// These variables determine the circumstances under which this class is loaded (only used during loading, and may be overwritten later)
|
||||
$mailerIncludeWithDefault = TRUE; // Mandatory - if false, show only when mailout for this specific plugin is enabled
|
||||
$mailerExcludeDefault = FALSE; // Mandatory - if TRUE, when this plugin's mailout is active, the default (core) isn't loaded
|
||||
|
||||
class newsletter_mailout
|
||||
{
|
||||
protected $mailCount = 0;
|
||||
protected $mailRead = 0;
|
||||
//public $mailerSource = 'newsletter'; // Plugin name (core mailer is special case) Must be directory for this file
|
||||
public $mailerName = NLLAN_48; // Text to identify the source of selector (displayed on left of admin page)
|
||||
public $mailerEnabled = TRUE; // Mandatory - set to FALSE to disable this plugin (e.g. due to permissions restrictions)
|
||||
private $selectorActive = FALSE; // Set TRUE if we've got a valid selector to start returning entries
|
||||
private $targets = array(); // Used to store potential recipients
|
||||
private $ourDB;
|
||||
|
||||
|
||||
// Constructor
|
||||
public function __construct()
|
||||
{
|
||||
// BAD FOR PERFORMANCE
|
||||
//$this->e107 = e107::getInstance();
|
||||
//$this->adminHandler = e107::getRegistry('_mailout_admin'); // Get the mailer admin object - we want to use some of its functions
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Return data representing the user's selection criteria as entered in the $_POST array.
|
||||
*
|
||||
* This is stored in the DB with a saved email. (Just return an empty string or array if this is undesirable)
|
||||
* The returned value is passed back to selectInit() and showSelect when needed.
|
||||
*
|
||||
* @return string Selection data - comma-separated list of category IDs
|
||||
*/
|
||||
public function returnSelectors()
|
||||
{
|
||||
$res = array();
|
||||
if (is_array($_POST['nl_category_sel']))
|
||||
{
|
||||
foreach ($_POST['nl_category_sel'] as $k => $v)
|
||||
{
|
||||
$res[] = intval($v);
|
||||
}
|
||||
}
|
||||
return implode(',',$res);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Called to initialise data selection routine.
|
||||
* Needs to save any queries or other information into internal variables, do initial DB queries as appropriate.
|
||||
* Could in principle read all addresses and buffer them for later routines, if this is more convenient
|
||||
*
|
||||
* @param string $selectVals - array of selection criteria as returned by returnSelectors()
|
||||
*
|
||||
* @return integer Return number of records available (or 1 if unknown) on success, FALSE on failure
|
||||
*/
|
||||
public function selectInit($selectVals = FALSE)
|
||||
{
|
||||
$sql = e107::getDb();
|
||||
|
||||
|
||||
if (($selectVals === FALSE) || ($selectVals == ''))
|
||||
{
|
||||
return 0; // No valid selector - so no valid records
|
||||
}
|
||||
|
||||
$qry = "SELECT newsletter_id,newsletter_subscribers FROM `#newsletter` WHERE (`newsletter_parent`=0) AND (`newsletter_id` IN ({$selectVals}))";
|
||||
// echo "Selector {$selectVals} query: ".$qry.'<br />';
|
||||
if (!($sql->db_Select_gen($qry))) return FALSE;
|
||||
$this->selectorActive = TRUE;
|
||||
$this->mail_count = 1; // We have no idea of how many subscribers without reading all relevant DB records
|
||||
$this->mail_read = 0;
|
||||
$this->ourDB = new db(); // We'll need our own database object
|
||||
return $this->mail_count;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Return an email address to add to the recipients list. Return FALSE if no more addresses to add
|
||||
*
|
||||
* @return array|boolean FALSE if no more addresses available; else an array:
|
||||
* 'mail_recipient_id' - non-zero if a registered user, zero if a non-registered user. (Always non-zero from this class)
|
||||
* 'mail_recipient_name' - user name
|
||||
* 'mail_recipient_email' - email address to use
|
||||
* 'mail_target_info' - array of info which might be substituted into email, usually using the codes defined by the editor.
|
||||
* Array key is the code within '|...|', value is the string for substitution
|
||||
*/
|
||||
public function selectAdd()
|
||||
{
|
||||
|
||||
$sql = e107::getDb();
|
||||
|
||||
|
||||
if (!$this->selectorActive) return FALSE;
|
||||
|
||||
while ($this->selectorActive)
|
||||
{
|
||||
if (count($this->targets) == 0)
|
||||
{ // Read in and process another newletter mailing list
|
||||
if (!($row = $sql->db_Fetch(MYSQL_ASSOC)))
|
||||
{
|
||||
$this->selectorActive = FALSE;
|
||||
return FALSE; // Run out of DB records
|
||||
}
|
||||
$this->targets = explode(chr(1), $row['newsletter_subscribers']);
|
||||
unset($row);
|
||||
}
|
||||
foreach ($this->targets as $k => $v)
|
||||
{
|
||||
if ($uid = intval(trim($v)))
|
||||
{ // Got a user ID here - look them up and add their data
|
||||
if ($this->ourDB->db_Select('user', 'user_name,user_email,user_lastvisit', '`user_id`='.$uid))
|
||||
{
|
||||
$row = $this->ourDB->db_Fetch();
|
||||
$ret = array('mail_recipient_id' => $uid,
|
||||
'mail_recipient_name' => $row['user_name'], // Should this use realname?
|
||||
'mail_recipient_email' => $row['user_email'],
|
||||
'mail_target_info' => array(
|
||||
'USERID' => $uid,
|
||||
'DISPLAYNAME' => $row['user_name'],
|
||||
'SIGNUP_LINK' => $row['user_sess'],
|
||||
'USERNAME' => $row['user_loginname'],
|
||||
'USERLASTVISIT' => $row['user_lastvisit']
|
||||
)
|
||||
);
|
||||
$this->mail_read++;
|
||||
unset($this->targets[$k]);
|
||||
return $ret;
|
||||
}
|
||||
}
|
||||
unset($this->targets[$k]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Called once all email addresses read, to do any housekeeping needed
|
||||
* @return none
|
||||
*/
|
||||
public function select_close()
|
||||
{
|
||||
// Nothing to do here
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Called to show current selection criteria, and optionally allow edit
|
||||
*
|
||||
* @param boolean $allow_edit is TRUE to allow user to change the selection; FALSE to just display current settings
|
||||
* @param string $selectVals is the current selection information - in the same format as returned by returnSelectors()
|
||||
*
|
||||
* @return array Returns array which is displayed in a table cell
|
||||
*/
|
||||
public function showSelect($allow_edit = FALSE, $selectVals = FALSE)
|
||||
{
|
||||
$sql = e107::getDb();
|
||||
$frm = e107::getForm();
|
||||
$var = array();
|
||||
|
||||
$selects = array_flip(explode(',', $selectVals));
|
||||
|
||||
if ($sql->db_Select('newsletter', 'newsletter_id, newsletter_title', '`newsletter_parent`=0'))
|
||||
{
|
||||
$c=0;
|
||||
while ($row = $sql->db_Fetch(MYSQL_ASSOC))
|
||||
{
|
||||
$checked = (isset($selects[$row['newsletter_id']])) ? " checked='checked'" : '';
|
||||
|
||||
if ($allow_edit)
|
||||
{
|
||||
$var[$c]['caption'] = $row['newsletter_title'];
|
||||
$var[$c]['html'] = $frm->checkbox('nl_category_sel[]',$row['newsletter_id'] ,$checked);
|
||||
}
|
||||
elseif($checked)
|
||||
{
|
||||
$var[$c]['caption'] = $row['newsletter_title'];
|
||||
$var[$c]['html'] = NLLAN_49;
|
||||
}
|
||||
$c++;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$var[$c]['caption'] = NLLAN_50;
|
||||
$var[$c]['html'] = '';
|
||||
}
|
||||
|
||||
return $var;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
<?php
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2013 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Newsletter plugin - mailout function
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/newsletter/e_mailout.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* e107 Newsletter plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage newsletter
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
|
||||
|
||||
include_lan(e_PLUGIN.'/newsletter/languages/English_admin_newsletter.php');
|
||||
|
||||
/*
|
||||
Class for newsletter mailout function
|
||||
|
||||
Allows admins to send mail to those subscribed to one or more newsletters
|
||||
*/
|
||||
// These variables determine the circumstances under which this class is loaded (only used during loading, and may be overwritten later)
|
||||
$mailerIncludeWithDefault = TRUE; // Mandatory - if false, show only when mailout for this specific plugin is enabled
|
||||
$mailerExcludeDefault = FALSE; // Mandatory - if TRUE, when this plugin's mailout is active, the default (core) isn't loaded
|
||||
|
||||
class newsletter_mailout
|
||||
{
|
||||
protected $mailCount = 0;
|
||||
protected $mailRead = 0;
|
||||
//public $mailerSource = 'newsletter'; // Plugin name (core mailer is special case) Must be directory for this file
|
||||
public $mailerName = NLLAN_48; // Text to identify the source of selector (displayed on left of admin page)
|
||||
public $mailerEnabled = TRUE; // Mandatory - set to FALSE to disable this plugin (e.g. due to permissions restrictions)
|
||||
private $selectorActive = FALSE; // Set TRUE if we've got a valid selector to start returning entries
|
||||
private $targets = array(); // Used to store potential recipients
|
||||
private $ourDB;
|
||||
|
||||
|
||||
// Constructor
|
||||
public function __construct()
|
||||
{
|
||||
// BAD FOR PERFORMANCE
|
||||
//$this->e107 = e107::getInstance();
|
||||
//$this->adminHandler = e107::getRegistry('_mailout_admin'); // Get the mailer admin object - we want to use some of its functions
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Return data representing the user's selection criteria as entered in the $_POST array.
|
||||
*
|
||||
* This is stored in the DB with a saved email. (Just return an empty string or array if this is undesirable)
|
||||
* The returned value is passed back to selectInit() and showSelect when needed.
|
||||
*
|
||||
* @return string Selection data - comma-separated list of category IDs
|
||||
*/
|
||||
public function returnSelectors()
|
||||
{
|
||||
$res = array();
|
||||
if (is_array($_POST['nl_category_sel']))
|
||||
{
|
||||
foreach ($_POST['nl_category_sel'] as $k => $v)
|
||||
{
|
||||
$res[] = intval($v);
|
||||
}
|
||||
}
|
||||
return implode(',',$res);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Called to initialise data selection routine.
|
||||
* Needs to save any queries or other information into internal variables, do initial DB queries as appropriate.
|
||||
* Could in principle read all addresses and buffer them for later routines, if this is more convenient
|
||||
*
|
||||
* @param string $selectVals - array of selection criteria as returned by returnSelectors()
|
||||
*
|
||||
* @return integer Return number of records available (or 1 if unknown) on success, FALSE on failure
|
||||
*/
|
||||
public function selectInit($selectVals = FALSE)
|
||||
{
|
||||
$sql = e107::getDb();
|
||||
|
||||
|
||||
if (($selectVals === FALSE) || ($selectVals == ''))
|
||||
{
|
||||
return 0; // No valid selector - so no valid records
|
||||
}
|
||||
|
||||
$qry = "SELECT newsletter_id,newsletter_subscribers FROM `#newsletter` WHERE (`newsletter_parent`=0) AND (`newsletter_id` IN ({$selectVals}))";
|
||||
// echo "Selector {$selectVals} query: ".$qry.'<br />';
|
||||
if (!($sql->db_Select_gen($qry))) return FALSE;
|
||||
$this->selectorActive = TRUE;
|
||||
$this->mail_count = 1; // We have no idea of how many subscribers without reading all relevant DB records
|
||||
$this->mail_read = 0;
|
||||
$this->ourDB = new db(); // We'll need our own database object
|
||||
return $this->mail_count;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Return an email address to add to the recipients list. Return FALSE if no more addresses to add
|
||||
*
|
||||
* @return array|boolean FALSE if no more addresses available; else an array:
|
||||
* 'mail_recipient_id' - non-zero if a registered user, zero if a non-registered user. (Always non-zero from this class)
|
||||
* 'mail_recipient_name' - user name
|
||||
* 'mail_recipient_email' - email address to use
|
||||
* 'mail_target_info' - array of info which might be substituted into email, usually using the codes defined by the editor.
|
||||
* Array key is the code within '|...|', value is the string for substitution
|
||||
*/
|
||||
public function selectAdd()
|
||||
{
|
||||
|
||||
$sql = e107::getDb();
|
||||
|
||||
|
||||
if (!$this->selectorActive) return FALSE;
|
||||
|
||||
while ($this->selectorActive)
|
||||
{
|
||||
if (count($this->targets) == 0)
|
||||
{ // Read in and process another newletter mailing list
|
||||
if (!($row = $sql->db_Fetch(MYSQL_ASSOC)))
|
||||
{
|
||||
$this->selectorActive = FALSE;
|
||||
return FALSE; // Run out of DB records
|
||||
}
|
||||
$this->targets = explode(chr(1), $row['newsletter_subscribers']);
|
||||
unset($row);
|
||||
}
|
||||
foreach ($this->targets as $k => $v)
|
||||
{
|
||||
if ($uid = intval(trim($v)))
|
||||
{ // Got a user ID here - look them up and add their data
|
||||
if ($this->ourDB->db_Select('user', 'user_name,user_email,user_lastvisit', '`user_id`='.$uid))
|
||||
{
|
||||
$row = $this->ourDB->db_Fetch();
|
||||
$ret = array('mail_recipient_id' => $uid,
|
||||
'mail_recipient_name' => $row['user_name'], // Should this use realname?
|
||||
'mail_recipient_email' => $row['user_email'],
|
||||
'mail_target_info' => array(
|
||||
'USERID' => $uid,
|
||||
'DISPLAYNAME' => $row['user_name'],
|
||||
'SIGNUP_LINK' => $row['user_sess'],
|
||||
'USERNAME' => $row['user_loginname'],
|
||||
'USERLASTVISIT' => $row['user_lastvisit']
|
||||
)
|
||||
);
|
||||
$this->mail_read++;
|
||||
unset($this->targets[$k]);
|
||||
return $ret;
|
||||
}
|
||||
}
|
||||
unset($this->targets[$k]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Called once all email addresses read, to do any housekeeping needed
|
||||
* @return none
|
||||
*/
|
||||
public function select_close()
|
||||
{
|
||||
// Nothing to do here
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Called to show current selection criteria, and optionally allow edit
|
||||
*
|
||||
* @param boolean $allow_edit is TRUE to allow user to change the selection; FALSE to just display current settings
|
||||
* @param string $selectVals is the current selection information - in the same format as returned by returnSelectors()
|
||||
*
|
||||
* @return array Returns array which is displayed in a table cell
|
||||
*/
|
||||
public function showSelect($allow_edit = FALSE, $selectVals = FALSE)
|
||||
{
|
||||
$sql = e107::getDb();
|
||||
$frm = e107::getForm();
|
||||
$var = array();
|
||||
|
||||
$selects = array_flip(explode(',', $selectVals));
|
||||
|
||||
if ($sql->db_Select('newsletter', 'newsletter_id, newsletter_title', '`newsletter_parent`=0'))
|
||||
{
|
||||
$c=0;
|
||||
while ($row = $sql->db_Fetch(MYSQL_ASSOC))
|
||||
{
|
||||
$checked = (isset($selects[$row['newsletter_id']])) ? " checked='checked'" : '';
|
||||
|
||||
if ($allow_edit)
|
||||
{
|
||||
$var[$c]['caption'] = $row['newsletter_title'];
|
||||
$var[$c]['html'] = $frm->checkbox('nl_category_sel[]',$row['newsletter_id'] ,$checked);
|
||||
}
|
||||
elseif($checked)
|
||||
{
|
||||
$var[$c]['caption'] = $row['newsletter_title'];
|
||||
$var[$c]['html'] = NLLAN_49;
|
||||
}
|
||||
$c++;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$var[$c]['caption'] = NLLAN_50;
|
||||
$var[$c]['html'] = '';
|
||||
}
|
||||
|
||||
return $var;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
?>
|
@@ -1,115 +1,115 @@
|
||||
<?php
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2010 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Newsletter plugin - newsletter selection menu
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/newsletter/newsletter_menu.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* e107 Newsletter plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage newsletter
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
if (!$e107->isInstalled('newsletter'))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if(!USER || !$sql -> db_Select('newsletter', '*', "newsletter_parent='0'"))
|
||||
{ // no newsletters defined yet
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
$newsletterArray = $sql -> db_getList();
|
||||
$requery = false;
|
||||
include_lan(e_PLUGIN.'newsletter/languages/'.e_LANGUAGE.'.php');
|
||||
|
||||
foreach($_POST as $key => $value)
|
||||
{
|
||||
if(strpos($key, 'nlUnsubscribe_') === 0)
|
||||
{
|
||||
$subid = str_replace('nlUnsubscribe_', '', $key);
|
||||
$newsletterArray[$subid]['newsletter_subscribers'] = str_replace(chr(1).USERID, "", $newsletterArray[$subid]['newsletter_subscribers']);
|
||||
$sql -> db_Update('newsletter', "newsletter_subscribers='".$newsletterArray[$subid]['newsletter_subscribers']."' WHERE newsletter_id='".intval($subid)."' ");
|
||||
$requery = true;
|
||||
}
|
||||
else if(strpos($key, 'nlSubscribe_') === 0)
|
||||
{
|
||||
$subid = str_replace("nlSubscribe_", "", $key);
|
||||
$nl_subscriber_array = $newsletterArray[$subid]['newsletter_subscribers'];
|
||||
if (!array_key_exists(USERID, $nl_subscriber_array))
|
||||
{ // prevent double entry of same user id
|
||||
$newsletterArray[$subid]['newsletter_subscribers'] .= chr(1).USERID;
|
||||
$subscribers_list = array_flip(explode(chr(1), $newsletterArray[$subid]['newsletter_subscribers']));
|
||||
sort($subscribers_list);
|
||||
$new_subscriber_list = implode(chr(1), array_keys($subscribers_list));
|
||||
if (substr($new_subscriber_list, 0, 1) == '0')
|
||||
{ // remove the possible zero caused by function array_flip
|
||||
$new_subscriber_list = substr($new_subscriber_list, 1);
|
||||
}
|
||||
$sql -> db_Update('newsletter', "newsletter_subscribers='".$new_subscriber_list."' WHERE newsletter_id='".intval($subid)."' ");
|
||||
$requery = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
global $tp;
|
||||
|
||||
if($requery)
|
||||
{
|
||||
if($sql -> db_Select('newsletter', '*', "newsletter_parent='0' "))
|
||||
{
|
||||
$newsletterArray = $sql -> db_getList();
|
||||
}
|
||||
}
|
||||
|
||||
$text = '';
|
||||
foreach($newsletterArray as $nl)
|
||||
{
|
||||
$text .= "<div style='text-align: center; margin-left: auto; margin-right: auto;'>
|
||||
<form method='post' action='".e_SELF."'>
|
||||
<b>".
|
||||
$tp -> toHTML($nl['newsletter_title'], TRUE)."</b><br />
|
||||
<span class='smalltext'>".
|
||||
$tp -> toHTML($nl['newsletter_text'], TRUE)."</span><br /><br />
|
||||
";
|
||||
|
||||
if(preg_match("#".chr(1).USERID."(".chr(1)."|$)#si", $nl['newsletter_subscribers']))
|
||||
{
|
||||
$text .= NLLAN_48."<br /><br />
|
||||
<input class='button' type='submit' name='nlUnsubscribe_".$nl['newsletter_id']."' value='".NLLAN_51."' onclick=\"return jsconfirm('".$tp->toJS(NLLAN_49)."') \" />
|
||||
";
|
||||
}
|
||||
else
|
||||
{
|
||||
$text .= NLLAN_50." <b>".USEREMAIL."</b> )<br /><br />
|
||||
<input class='button' type='submit' name='nlSubscribe_".$nl['newsletter_id']."' value='".NLLAN_52."' onclick=\"return jsconfirm('".$tp->toJS(NLLAN_53)."') \" />
|
||||
";
|
||||
}
|
||||
$nl_count = $sql -> db_Count('newsletter', "(*)", "WHERE newsletter_parent='".$nl['newsletter_id']."' AND newsletter_flag='1'");
|
||||
if($nl_count > 0 && USER)
|
||||
{ // display issued newsletters
|
||||
$text .= "<br /><a href='".e_PLUGIN_ABS."newsletter/nl_archive.php?show.".$nl['newsletter_id']."' alt='".NLLAN_72."' title='".NLLAN_72."'>".NLLAN_72."</a><br/><br/>";
|
||||
}
|
||||
$text .= "</form>
|
||||
</div>
|
||||
<br />
|
||||
";
|
||||
}
|
||||
|
||||
$ns -> tablerender(NLLAN_MENU_CAPTION, $text);
|
||||
<?php
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2013 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Newsletter plugin - newsletter selection menu
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/newsletter/newsletter_menu.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* e107 Newsletter plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage newsletter
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
if (!$e107->isInstalled('newsletter'))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if(!USER || !$sql -> db_Select('newsletter', '*', "newsletter_parent='0'"))
|
||||
{ // no newsletters defined yet
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
$newsletterArray = $sql -> db_getList();
|
||||
$requery = false;
|
||||
include_lan(e_PLUGIN.'newsletter/languages/'.e_LANGUAGE.'.php');
|
||||
|
||||
foreach($_POST as $key => $value)
|
||||
{
|
||||
if(strpos($key, 'nlUnsubscribe_') === 0)
|
||||
{
|
||||
$subid = str_replace('nlUnsubscribe_', '', $key);
|
||||
$newsletterArray[$subid]['newsletter_subscribers'] = str_replace(chr(1).USERID, "", $newsletterArray[$subid]['newsletter_subscribers']);
|
||||
$sql -> db_Update('newsletter', "newsletter_subscribers='".$newsletterArray[$subid]['newsletter_subscribers']."' WHERE newsletter_id='".intval($subid)."' ");
|
||||
$requery = true;
|
||||
}
|
||||
else if(strpos($key, 'nlSubscribe_') === 0)
|
||||
{
|
||||
$subid = str_replace("nlSubscribe_", "", $key);
|
||||
$nl_subscriber_array = $newsletterArray[$subid]['newsletter_subscribers'];
|
||||
if (!array_key_exists(USERID, $nl_subscriber_array))
|
||||
{ // prevent double entry of same user id
|
||||
$newsletterArray[$subid]['newsletter_subscribers'] .= chr(1).USERID;
|
||||
$subscribers_list = array_flip(explode(chr(1), $newsletterArray[$subid]['newsletter_subscribers']));
|
||||
sort($subscribers_list);
|
||||
$new_subscriber_list = implode(chr(1), array_keys($subscribers_list));
|
||||
if (substr($new_subscriber_list, 0, 1) == '0')
|
||||
{ // remove the possible zero caused by function array_flip
|
||||
$new_subscriber_list = substr($new_subscriber_list, 1);
|
||||
}
|
||||
$sql -> db_Update('newsletter', "newsletter_subscribers='".$new_subscriber_list."' WHERE newsletter_id='".intval($subid)."' ");
|
||||
$requery = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
global $tp;
|
||||
|
||||
if($requery)
|
||||
{
|
||||
if($sql -> db_Select('newsletter', '*', "newsletter_parent='0' "))
|
||||
{
|
||||
$newsletterArray = $sql -> db_getList();
|
||||
}
|
||||
}
|
||||
|
||||
$text = '';
|
||||
foreach($newsletterArray as $nl)
|
||||
{
|
||||
$text .= "<div style='text-align: center; margin-left: auto; margin-right: auto;'>
|
||||
<form method='post' action='".e_SELF."'>
|
||||
<b>".
|
||||
$tp -> toHTML($nl['newsletter_title'], TRUE)."</b><br />
|
||||
<span class='smalltext'>".
|
||||
$tp -> toHTML($nl['newsletter_text'], TRUE)."</span><br /><br />
|
||||
";
|
||||
|
||||
if(preg_match("#".chr(1).USERID."(".chr(1)."|$)#si", $nl['newsletter_subscribers']))
|
||||
{
|
||||
$text .= NLLAN_48."<br /><br />
|
||||
<input class='button' type='submit' name='nlUnsubscribe_".$nl['newsletter_id']."' value='".NLLAN_51."' onclick=\"return jsconfirm('".$tp->toJS(NLLAN_49)."') \" />
|
||||
";
|
||||
}
|
||||
else
|
||||
{
|
||||
$text .= NLLAN_50." <b>".USEREMAIL."</b> )<br /><br />
|
||||
<input class='button' type='submit' name='nlSubscribe_".$nl['newsletter_id']."' value='".NLLAN_52."' onclick=\"return jsconfirm('".$tp->toJS(NLLAN_53)."') \" />
|
||||
";
|
||||
}
|
||||
$nl_count = $sql -> db_Count('newsletter', "(*)", "WHERE newsletter_parent='".$nl['newsletter_id']."' AND newsletter_flag='1'");
|
||||
if($nl_count > 0 && USER)
|
||||
{ // display issued newsletters
|
||||
$text .= "<br /><a href='".e_PLUGIN_ABS."newsletter/nl_archive.php?show.".$nl['newsletter_id']."' alt='".NLLAN_72."' title='".NLLAN_72."'>".NLLAN_72."</a><br/><br/>";
|
||||
}
|
||||
$text .= "</form>
|
||||
</div>
|
||||
<br />
|
||||
";
|
||||
}
|
||||
|
||||
$ns -> tablerender(NLLAN_MENU_CAPTION, $text);
|
||||
?>
|
@@ -1,139 +1,150 @@
|
||||
<?php
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2009 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Administration - Site Maintenance
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/newsletter/nl_archive.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*
|
||||
*/
|
||||
require_once('../../class2.php');
|
||||
if (!$e107->isInstalled('newsletter') || !ADMIN)
|
||||
{
|
||||
header('Location: '.e_BASE.'index.php');
|
||||
exit();
|
||||
}
|
||||
include_lan(e_PLUGIN.'newsletter/languages/'.e_LANGUAGE.'.php');
|
||||
require_once(HEADERF);
|
||||
|
||||
$action_parent_id = 0;
|
||||
$action_nl_id = 0;
|
||||
if(e_QUERY)
|
||||
{
|
||||
$tmp = explode('.', e_QUERY);
|
||||
$action = $tmp[0];
|
||||
$action_parent_id = varset(intval($tmp[1], 0));
|
||||
$action_nl_id = varset(intval($tmp[2], 0));
|
||||
unset($tmp);
|
||||
}
|
||||
|
||||
$page_size = 10; // Might become a preference setting later on
|
||||
$text .= "<div style='text-align: center; margin-left: auto; margin-right: auto; width: 100%;'>";
|
||||
|
||||
if (($action <> 'show' && $action <> 'showp') || ($action_parent_id == 0))
|
||||
{ // Action 'show' displays initial page, 'showp' displays following pages
|
||||
$text .= NLLAN_68; // Invalid parameter defined
|
||||
}
|
||||
else
|
||||
{
|
||||
if(!isset($_POST['limit_start']))
|
||||
{
|
||||
$limit_start = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
$limit_start = $_POST['limit_start'];
|
||||
}
|
||||
$nl_count = $e107->sql->db_Count('newsletter', '(*)', "WHERE newsletter_parent='".$action_parent_id."' AND newsletter_flag='1'");
|
||||
if ($nl_count > 0)
|
||||
{
|
||||
// Retrieve parent info
|
||||
$e107->sql->db_Select('newsletter', "*", "newsletter_id='".$action_parent_id."'");
|
||||
if ($row = $e107->sql->db_Fetch())
|
||||
{
|
||||
$parent_newsletter_title = $tp->toHTML($row['newsletter_title'],true);
|
||||
$parent_newsletter_text = $tp->toHTML($row['newsletter_text'],true);
|
||||
$parent_newsletter_header = $tp->toHTML($row['newsletter_header'],true);
|
||||
$parent_newsletter_footer = $tp->toHTML($row['newsletter_footer'],true);
|
||||
}
|
||||
if ($action_nl_id == '' || $action_nl_id == 0) //Show list of sent newsletters
|
||||
{
|
||||
// Display parent name
|
||||
$text .= "{$parent_newsletter_title}<br />
|
||||
<div style='text-align: left;'>{$parent_newsletter_text}</div><br /><br />
|
||||
<table>";
|
||||
|
||||
// Display list of sent newsletters titles
|
||||
if ($action == 'showp')
|
||||
{ // This should only be done when action is 'showp'
|
||||
$limit_start = $limit_start + $page_size;
|
||||
}
|
||||
$e107->sql->db_Select('newsletter', '*', "newsletter_parent='".$action_parent_id."' AND newsletter_flag='1' ORDER BY newsletter_datestamp DESC LIMIT ".$limit_start.",".$page_size);
|
||||
while ($row = $e107->sql->db_Fetch())
|
||||
{
|
||||
$ga = new convert();
|
||||
$newsletter_datestamp = $ga->convert_date($row['newsletter_datestamp'], 'long');
|
||||
$text .= "<tr>
|
||||
<td>
|
||||
".$row['newsletter_issue']."
|
||||
</td>
|
||||
<td>
|
||||
<a href='".e_PLUGIN."newsletter/nl_archive.php?show.".$action_parent_id.".".$row['newsletter_id']."'>".$tp->toHTML($row['newsletter_title'],true)."</a>
|
||||
</td>
|
||||
<td>
|
||||
".$newsletter_datestamp."
|
||||
</td>
|
||||
</tr>";
|
||||
}
|
||||
$text .= "</table>";
|
||||
if($limit_start + $page_size < $nl_count)
|
||||
{
|
||||
$text .= "<form id='nl' method='post' action='".e_PLUGIN."newsletter/nl_archive.php?showp.".$action_parent_id."'>
|
||||
<br /><input class='button' name='submit' type='submit' value='View older newsletters in archive'/>
|
||||
<input type='hidden' name='limit_start' value='".$limit_start."'/></form>";
|
||||
}
|
||||
}
|
||||
else // Show requested newsletter
|
||||
{
|
||||
$e107->sql->db_Select('newsletter', '*', "newsletter_parent='".$action_parent_id."' AND newsletter_id='".$action_nl_id."' AND newsletter_flag='1'");
|
||||
if ($row = $e107->sql->db_Fetch())
|
||||
{
|
||||
// Display parent header
|
||||
$text .= "$parent_newsletter_title<br />
|
||||
<div style='text-align: left;'>$parent_newsletter_text</div><br /><br />
|
||||
$parent_newsletter_header<br /><br />";
|
||||
// Display newsletter text
|
||||
$ga = new convert();
|
||||
$newsletter_datestamp = $ga->convert_date($row['newsletter_datestamp'], "long");
|
||||
$text .= $newsletter_datestamp."<br />".
|
||||
$tp->toHTML($row['newsletter_title'],true)."<br />
|
||||
<div style='text-align: left;'>".$tp->toHTML($row['newsletter_text'],true)."</div><br /><br />";
|
||||
// Display parent footer
|
||||
$text .= "$parent_newsletter_footer<br />";
|
||||
// Display back to newsletter overview button
|
||||
$text .= "<br /><a href='javascript:history.go(-1);'><input class='button' type='submit' value='".NLLAN_71."'</a>";
|
||||
}
|
||||
else
|
||||
{
|
||||
$text .= NLLAN_70; //Selected newsletter does not exist
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$text .= NLLAN_69; // No send newsletters available for selected parent
|
||||
}
|
||||
}
|
||||
|
||||
$text .= "</div>";
|
||||
|
||||
$ns -> tablerender(NLLAN_67, $text);
|
||||
require_once(FOOTERF);
|
||||
<?php
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2013 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Administration - Site Maintenance
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/newsletter/nl_archive.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* e107 Newsletter plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage newsletter
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
|
||||
require_once('../../class2.php');
|
||||
if (!$e107->isInstalled('newsletter') || !ADMIN)
|
||||
{
|
||||
header('Location: '.e_BASE.'index.php');
|
||||
exit();
|
||||
}
|
||||
include_lan(e_PLUGIN.'newsletter/languages/'.e_LANGUAGE.'.php');
|
||||
require_once(HEADERF);
|
||||
|
||||
$action_parent_id = 0;
|
||||
$action_nl_id = 0;
|
||||
if(e_QUERY)
|
||||
{
|
||||
$tmp = explode('.', e_QUERY);
|
||||
$action = $tmp[0];
|
||||
$action_parent_id = varset(intval($tmp[1], 0));
|
||||
$action_nl_id = varset(intval($tmp[2], 0));
|
||||
unset($tmp);
|
||||
}
|
||||
|
||||
$page_size = 10; // Might become a preference setting later on
|
||||
$text .= "<div style='text-align: center; margin-left: auto; margin-right: auto; width: 100%;'>";
|
||||
|
||||
if (($action <> 'show' && $action <> 'showp') || ($action_parent_id == 0))
|
||||
{ // Action 'show' displays initial page, 'showp' displays following pages
|
||||
$text .= NLLAN_68; // Invalid parameter defined
|
||||
}
|
||||
else
|
||||
{
|
||||
if(!isset($_POST['limit_start']))
|
||||
{
|
||||
$limit_start = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
$limit_start = $_POST['limit_start'];
|
||||
}
|
||||
$nl_count = $e107->sql->db_Count('newsletter', '(*)', "WHERE newsletter_parent='".$action_parent_id."' AND newsletter_flag='1'");
|
||||
if ($nl_count > 0)
|
||||
{
|
||||
// Retrieve parent info
|
||||
$e107->sql->db_Select('newsletter', "*", "newsletter_id='".$action_parent_id."'");
|
||||
if ($row = $e107->sql->db_Fetch())
|
||||
{
|
||||
$parent_newsletter_title = $tp->toHTML($row['newsletter_title'],true);
|
||||
$parent_newsletter_text = $tp->toHTML($row['newsletter_text'],true);
|
||||
$parent_newsletter_header = $tp->toHTML($row['newsletter_header'],true);
|
||||
$parent_newsletter_footer = $tp->toHTML($row['newsletter_footer'],true);
|
||||
}
|
||||
if ($action_nl_id == '' || $action_nl_id == 0) //Show list of sent newsletters
|
||||
{
|
||||
// Display parent name
|
||||
$text .= "{$parent_newsletter_title}<br />
|
||||
<div style='text-align: left;'>{$parent_newsletter_text}</div><br /><br />
|
||||
<table>";
|
||||
|
||||
// Display list of sent newsletters titles
|
||||
if ($action == 'showp')
|
||||
{ // This should only be done when action is 'showp'
|
||||
$limit_start = $limit_start + $page_size;
|
||||
}
|
||||
$e107->sql->db_Select('newsletter', '*', "newsletter_parent='".$action_parent_id."' AND newsletter_flag='1' ORDER BY newsletter_datestamp DESC LIMIT ".$limit_start.",".$page_size);
|
||||
while ($row = $e107->sql->db_Fetch())
|
||||
{
|
||||
$ga = new convert();
|
||||
$newsletter_datestamp = $ga->convert_date($row['newsletter_datestamp'], 'long');
|
||||
$text .= "<tr>
|
||||
<td>
|
||||
".$row['newsletter_issue']."
|
||||
</td>
|
||||
<td>
|
||||
<a href='".e_PLUGIN."newsletter/nl_archive.php?show.".$action_parent_id.".".$row['newsletter_id']."'>".$tp->toHTML($row['newsletter_title'],true)."</a>
|
||||
</td>
|
||||
<td>
|
||||
".$newsletter_datestamp."
|
||||
</td>
|
||||
</tr>";
|
||||
}
|
||||
$text .= "</table>";
|
||||
if($limit_start + $page_size < $nl_count)
|
||||
{
|
||||
$text .= "<form id='nl' method='post' action='".e_PLUGIN."newsletter/nl_archive.php?showp.".$action_parent_id."'>
|
||||
<br /><input class='button' name='submit' type='submit' value='View older newsletters in archive'/>
|
||||
<input type='hidden' name='limit_start' value='".$limit_start."'/></form>";
|
||||
}
|
||||
}
|
||||
else // Show requested newsletter
|
||||
{
|
||||
$e107->sql->db_Select('newsletter', '*', "newsletter_parent='".$action_parent_id."' AND newsletter_id='".$action_nl_id."' AND newsletter_flag='1'");
|
||||
if ($row = $e107->sql->db_Fetch())
|
||||
{
|
||||
// Display parent header
|
||||
$text .= "$parent_newsletter_title<br />
|
||||
<div style='text-align: left;'>$parent_newsletter_text</div><br /><br />
|
||||
$parent_newsletter_header<br /><br />";
|
||||
// Display newsletter text
|
||||
$ga = new convert();
|
||||
$newsletter_datestamp = $ga->convert_date($row['newsletter_datestamp'], "long");
|
||||
$text .= $newsletter_datestamp."<br />".
|
||||
$tp->toHTML($row['newsletter_title'],true)."<br />
|
||||
<div style='text-align: left;'>".$tp->toHTML($row['newsletter_text'],true)."</div><br /><br />";
|
||||
// Display parent footer
|
||||
$text .= "$parent_newsletter_footer<br />";
|
||||
// Display back to newsletter overview button
|
||||
$text .= "<br /><a href='javascript:history.go(-1);'><input class='button' type='submit' value='".NLLAN_71."'</a>";
|
||||
}
|
||||
else
|
||||
{
|
||||
$text .= NLLAN_70; //Selected newsletter does not exist
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$text .= NLLAN_69; // No send newsletters available for selected parent
|
||||
}
|
||||
}
|
||||
|
||||
$text .= "</div>";
|
||||
|
||||
$ns -> tablerender(NLLAN_67, $text);
|
||||
require_once(FOOTERF);
|
||||
?>
|
@@ -15,6 +15,15 @@
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
* e107 pdf generation plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage pdf
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
|
||||
require_once('../../class2.php');
|
||||
if (!getperms('P') || !plugInstalled('pdf'))
|
||||
{
|
||||
|
@@ -2,17 +2,25 @@
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2009 e107 Inc (e107.org)
|
||||
* Copyright (C) 2008-2013 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Plugin - PDF generator
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/pdf/e107pdf.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*/
|
||||
* $URL$
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* e107 pdf generation plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage pdf
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
|
||||
/*
|
||||
|
@@ -2,18 +2,24 @@
|
||||
/*
|
||||
* e107 website system
|
||||
*
|
||||
* Copyright (C) 2008-2009 e107 Inc (e107.org)
|
||||
* Copyright (C) 2008-2013 e107 Inc (e107.org)
|
||||
* Released under the terms and conditions of the
|
||||
* GNU General Public License (http://www.gnu.org/licenses/gpl.txt)
|
||||
*
|
||||
* Plugin - PDF Generator
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/pdf/pdf.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
* $URL$
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/**
|
||||
* e107 pdf generation plugin
|
||||
*
|
||||
*/
|
||||
* @package e107_plugins
|
||||
* @subpackage pdf
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
require_once('../../class2.php');
|
||||
if(!e107::isInstalled('pdf') || !e_QUERY)
|
||||
{
|
||||
|
@@ -1,20 +1,27 @@
|
||||
/*
|
||||
* e107 website system Copyright (C) 2008-2009 e107 Inc (e107.org)
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
if (!plugInstalled('pdf'))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (defined("ICONPRINTPDF") && file_exists(THEME."images/".ICONPRINTPDF))
|
||||
{
|
||||
$icon = THEME_ABS."images/".ICONPRINTPDF;
|
||||
}
|
||||
else
|
||||
{
|
||||
$icon = e_PLUGIN_ABS."pdf/images/pdf_16.png";
|
||||
}
|
||||
$parms = explode("^",$parm);
|
||||
return " <a href='".e_PLUGIN_ABS."pdf/pdf.php?{$parms[1]}'><img src='".$icon."' style='border:0' alt='{$parms[0]}' title='{$parms[0]}' /></a>";
|
||||
/*
|
||||
* e107 website system Copyright (C) 2008-2013 e107 Inc (e107.org)
|
||||
* $Id$
|
||||
*/
|
||||
/**
|
||||
* e107 pdf generation plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage pdf
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!plugInstalled('pdf'))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (defined("ICONPRINTPDF") && file_exists(THEME."images/".ICONPRINTPDF))
|
||||
{
|
||||
$icon = THEME_ABS."images/".ICONPRINTPDF;
|
||||
}
|
||||
else
|
||||
{
|
||||
$icon = e_PLUGIN_ABS."pdf/images/pdf_16.png";
|
||||
}
|
||||
$parms = explode("^",$parm);
|
||||
return " <a href='".e_PLUGIN_ABS."pdf/pdf.php?{$parms[1]}'><img src='".$icon."' style='border:0' alt='{$parms[0]}' title='{$parms[0]}' /></a>";
|
||||
|
Reference in New Issue
Block a user