mirror of
https://github.com/e107inc/e107.git
synced 2025-04-20 20:51:53 +02:00
Merge pull request #2551 from rica-carv/rica-carv-pm_update
PM Plugin templates to V2.x locations
This commit is contained in:
commit
48aa19b92a
@ -176,15 +176,22 @@ class pm_extended extends private_message
|
||||
{
|
||||
return str_replace('{PERCENT}', $pm_outbox['outbox']['filled'], LAN_PM_13);
|
||||
}
|
||||
$tpl_file = THEME.'pm_template.php';
|
||||
include_once(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
// $tpl_file = THEME.'pm_template.php';
|
||||
// include_once(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
if(THEME_LEGACY){
|
||||
include_once(THEME.'pm_template.php');
|
||||
$PM_SEND_PM = $this->updateTemplate($PM_SEND_PM);
|
||||
}
|
||||
if (!$PM_SEND_PM){$PM_SEND_PM = e107::getTemplate('pm', 'pm', 'send');}
|
||||
|
||||
$enc = (check_class($this->pmPrefs['attach_class']) ? "enctype='multipart/form-data'" : '');
|
||||
// setScVar('pm_handler_shortcodes','pmInfo', $pm_info);
|
||||
|
||||
$sc = e107::getScBatch('pm',true, 'pm');
|
||||
$sc->setVars($pm_info);
|
||||
$sc->wrapper('pm');
|
||||
|
||||
$PM_SEND_PM = $this->updateTemplate($PM_SEND_PM);
|
||||
// $PM_SEND_PM = $this->updateTemplate($PM_SEND_PM);
|
||||
|
||||
$text = "<form {$enc} method='post' action='".e_SELF."' id='dataform'>
|
||||
<div><input type='hidden' name='numsent' value='{$pm_outbox['outbox']['total']}' />".
|
||||
@ -205,8 +212,18 @@ class pm_extended extends private_message
|
||||
{
|
||||
$tp = e107::getParser();
|
||||
|
||||
$tpl_file = THEME.'pm_template.php';
|
||||
include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
// $tpl_file = THEME.'pm_template.php';
|
||||
// include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
if(THEME_LEGACY){
|
||||
include_once(THEME.'pm_template.php');
|
||||
|
||||
// Is updateTemplate really necessary for v2.x templates?
|
||||
$PM_INBOX['start'] = $this->updateTemplate($PM_INBOX_HEADER);
|
||||
$PM_INBOX['item'] = $this->updateTemplate($PM_INBOX_TABLE);
|
||||
$PM_INBOX['empty'] = $this->updateTemplate($PM_INBOX_EMPTY);
|
||||
$PM_INBOX['end'] = $this->updateTemplate($PM_INBOX_FOOTER);
|
||||
}
|
||||
if (!$PM_INBOX){$PM_INBOX = e107::getTemplate('pm', 'pm', 'inbox');}
|
||||
|
||||
$pm_blocks = $this->block_get();
|
||||
$pmlist = $this->pm_get_inbox(USERID, $start, $this->pmPrefs['perpage']);
|
||||
@ -215,15 +232,17 @@ class pm_extended extends private_message
|
||||
|
||||
$sc = e107::getScBatch('pm',true, 'pm');
|
||||
$sc->pmNextPrev = array('start' => $start, 'total' => $pmlist['total_messages']);
|
||||
$sc->wrapper('pm');
|
||||
|
||||
|
||||
$PM_INBOX_HEADER = $this->updateTemplate($PM_INBOX_HEADER);
|
||||
$PM_INBOX_TABLE = $this->updateTemplate($PM_INBOX_TABLE);
|
||||
$PM_INBOX_EMPTY = $this->updateTemplate($PM_INBOX_EMPTY);
|
||||
$PM_INBOX_FOOTER = $this->updateTemplate($PM_INBOX_FOOTER);
|
||||
|
||||
// Is updateTemplate really necessary for v2.x templates?
|
||||
/*
|
||||
$PM_INBOX_HEADER = $this->updateTemplate($PM_INBOX['start']);
|
||||
$PM_INBOX_TABLE = $this->updateTemplate($PM_INBOX['item']);
|
||||
$PM_INBOX_EMPTY = $this->updateTemplate($PM_INBOX['empty']);
|
||||
$PM_INBOX_FOOTER = $this->updateTemplate($PM_INBOX['end']);
|
||||
*/
|
||||
$txt = "<form method='post' action='".e_REQUEST_SELF."?".e_QUERY."'>";
|
||||
$txt .= $tp->parseTemplate($PM_INBOX_HEADER, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_INBOX['start'], true, $sc);
|
||||
|
||||
if($pmlist['total_messages'])
|
||||
{
|
||||
@ -231,15 +250,15 @@ class pm_extended extends private_message
|
||||
{
|
||||
if(trim($rec['pm_subject']) == '') { $rec['pm_subject'] = '['.LAN_PM_61.']'; }
|
||||
$sc->setVars($rec);
|
||||
$txt .= $tp->parseTemplate($PM_INBOX_TABLE, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_INBOX['item'], true, $sc);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$txt .= $tp->parseTemplate($PM_INBOX_EMPTY, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_INBOX['empty'], true, $sc);
|
||||
}
|
||||
|
||||
$txt .= $tp->parseTemplate($PM_INBOX_FOOTER, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_INBOX['end'], true, $sc);
|
||||
$txt .= "</form>";
|
||||
|
||||
|
||||
@ -257,22 +276,35 @@ class pm_extended extends private_message
|
||||
{
|
||||
$tp = e107::getParser();
|
||||
|
||||
$tpl_file = THEME.'pm_template.php';
|
||||
include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
// $tpl_file = THEME.'pm_template.php';
|
||||
// include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
if(THEME_LEGACY){
|
||||
include_once(THEME.'pm_template.php');
|
||||
|
||||
// Is updateTemplate really necessary for v2.x templates?
|
||||
$PM_OUTBOX['start'] = $this->updateTemplate($PM_OUTBOX_HEADER);
|
||||
$PM_OUTBOX['item'] = $this->updateTemplate($PM_OUTBOX_TABLE);
|
||||
$PM_OUTBOX['empty'] = $this->updateTemplate($PM_OUTBOX_EMPTY);
|
||||
$PM_OUTBOX['end'] = $this->updateTemplate($PM_OUTBOX_FOOTER);
|
||||
}
|
||||
if (!$PM_OUTBOX){$PM_OUTBOX = e107::getTemplate('pm', 'pm', 'outbox');}
|
||||
|
||||
$pmlist = $this->pm_get_outbox(USERID, $start, $this->pmPrefs['perpage']);
|
||||
// setScVar('pm_handler_shortcodes', 'pmNextPrev', array('start' => $start, 'total' => $pmlist['total_messages']));
|
||||
|
||||
$sc = e107::getScBatch('pm', true, 'pm');
|
||||
$sc->pmNextPrev = array('start' => $start, 'total' => $pmlist['total_messages']);
|
||||
$sc->wrapper('pm');
|
||||
|
||||
$PM_OUTBOX_HEADER = $this->updateTemplate($PM_OUTBOX_HEADER);
|
||||
$PM_OUTBOX_TABLE = $this->updateTemplate($PM_OUTBOX_TABLE);
|
||||
$PM_OUTBOX_EMPTY = $this->updateTemplate($PM_OUTBOX_EMPTY);
|
||||
$PM_OUTBOX_FOOTER = $this->updateTemplate($PM_OUTBOX_FOOTER);
|
||||
|
||||
|
||||
// Is updateTemplate really necessary for v2.x templates?
|
||||
/*
|
||||
$PM_OUTBOX_HEADER = $this->updateTemplate($PM_OUTBOX['start']);
|
||||
$PM_OUTBOX_TABLE = $this->updateTemplate($PM_OUTBOX['item']);
|
||||
$PM_OUTBOX_EMPTY = $this->updateTemplate($PM_OUTBOX['empty']);
|
||||
$PM_OUTBOX_FOOTER = $this->updateTemplate($PM_OUTBOX['end']);
|
||||
*/
|
||||
$txt = "<form method='post' action='".e_SELF."?".e_QUERY."'>";
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX_HEADER, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX['start'], true, $sc);
|
||||
if($pmlist['total_messages'])
|
||||
{
|
||||
foreach($pmlist['messages'] as $rec)
|
||||
@ -280,14 +312,14 @@ class pm_extended extends private_message
|
||||
if(trim($rec['pm_subject']) == '') { $rec['pm_subject'] = '['.LAN_PM_61.']'; }
|
||||
// setScVar('pm_handler_shortcodes','pmInfo', $rec);
|
||||
$sc->setVars($rec);
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX_TABLE, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX['item'], true, $sc);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX_EMPTY, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX['empty'], true, $sc);
|
||||
}
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX_FOOTER, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_OUTBOX['end'], true, $sc);
|
||||
$txt .= '</form>';
|
||||
return $txt;
|
||||
}
|
||||
@ -304,12 +336,19 @@ class pm_extended extends private_message
|
||||
{
|
||||
$ns = e107::getRender();
|
||||
|
||||
$tpl_file = THEME.'pm_template.php';
|
||||
include_once(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
// $tpl_file = THEME.'pm_template.php';
|
||||
// include_once(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
if(THEME_LEGACY){
|
||||
include_once(THEME.'pm_template.php');
|
||||
$PM_SHOW = $this->updateTemplate($PM_SHOW);
|
||||
}
|
||||
if (!$PM_SHOW){$PM_SHOW = e107::getTemplate('pm', 'pm', 'show');}
|
||||
|
||||
$pm_info = $this->pm_get($pmid);
|
||||
|
||||
$sc = e107::getScBatch('pm',true, 'pm');
|
||||
$sc->setVars($pm_info);
|
||||
$sc->wrapper('pm');
|
||||
|
||||
if($pm_info['pm_to'] != USERID && $pm_info['pm_from'] != USERID)
|
||||
{
|
||||
@ -327,7 +366,7 @@ class pm_extended extends private_message
|
||||
|
||||
$sc->pmMode = $comeFrom;
|
||||
|
||||
$PM_SHOW = $this->updateTemplate($PM_SHOW);
|
||||
// $PM_SHOW = $this->updateTemplate($PM_SHOW);
|
||||
|
||||
$txt = e107::getParser()->parseTemplate($PM_SHOW, true, $sc);
|
||||
|
||||
@ -373,35 +412,49 @@ class pm_extended extends private_message
|
||||
public function showBlocked($start = 0)
|
||||
{
|
||||
$tp = e107::getParser();
|
||||
$tpl_file = THEME.'pm_template.php';
|
||||
include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
// $tpl_file = THEME.'pm_template.php';
|
||||
// include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
if(THEME_LEGACY){
|
||||
include_once(THEME.'pm_template.php');
|
||||
|
||||
// Is updateTemplate really necessary for v2.x templates?
|
||||
$PM_BLOCKED['start'] = $this->updateTemplate($PM_BLOCKED_HEADER);
|
||||
$PM_BLOCKED['item'] = $this->updateTemplate($PM_BLOCKED_TABLE);
|
||||
$PM_BLOCKED['empty'] = $this->updateTemplate($PM_BLOCKED_EMPTY);
|
||||
$PM_BLOCKED['end'] = $this->updateTemplate($PM_BLOCKED_FOOTER);
|
||||
}
|
||||
if (!$PM_BLOCKED){$PM_BLOCKED = e107::getTemplate('pm', 'pm', 'blocked');}
|
||||
|
||||
$pmBlocks = $this->block_get_user(); // TODO - handle pagination, maybe (is it likely to be necessary?)
|
||||
|
||||
$sc = e107::getScBatch('pm',TRUE, 'pm');
|
||||
$sc->pmBlocks = $pmBlocks;
|
||||
$sc->wrapper('pm');
|
||||
|
||||
$PM_BLOCKED_HEADER = $this->updateTemplate($PM_BLOCKED_HEADER);
|
||||
$PM_BLOCKED_TABLE = $this->updateTemplate($PM_BLOCKED_TABLE);
|
||||
$PM_BLOCKED_EMPTY = $this->updateTemplate($PM_BLOCKED_EMPTY);
|
||||
$PM_BLOCKED_FOOTER = $this->updateTemplate($PM_BLOCKED_FOOTER);
|
||||
|
||||
// Is updateTemplate really necessary for v2.x templates?
|
||||
/*
|
||||
$PM_BLOCKED_HEADER = $this->updateTemplate($PM_BLOCKED['start']);
|
||||
$PM_BLOCKED_TABLE = $this->updateTemplate($PM_BLOCKED['item']);
|
||||
$PM_BLOCKED_EMPTY = $this->updateTemplate($PM_BLOCKED['empty']);
|
||||
$PM_BLOCKED_FOOTER = $this->updateTemplate($PM_BLOCKED['end']);
|
||||
*/
|
||||
|
||||
$txt = "<form method='post' action='".e_SELF."?".e_QUERY."'>";
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED_HEADER, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED['start'], true, $sc);
|
||||
if($pmTotalBlocked = count($pmBlocks))
|
||||
{
|
||||
foreach($pmBlocks as $pmBlocked)
|
||||
{
|
||||
$sc->pmBlocked = $pmBlocked;
|
||||
// setScVar('pm_handler_shortcodes','pmBlocked', $pmBlocked);
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED_TABLE, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED['item'], true, $sc);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED_EMPTY, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED['empty'], true, $sc);
|
||||
}
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED_FOOTER, true, $sc);
|
||||
$txt .= $tp->parseTemplate($PM_BLOCKED['end'], true, $sc);
|
||||
$txt .= '</form>';
|
||||
return $txt;
|
||||
}
|
||||
|
@ -377,7 +377,7 @@ class private_message
|
||||
function pm_send_notify($uid, $pmInfo, $pmid, $attach_count = 0)
|
||||
{
|
||||
// require_once(e_HANDLER.'mail.php');
|
||||
|
||||
/*
|
||||
$tpl_file = THEME.'pm_template.php';
|
||||
|
||||
$PM_NOTIFY = null; // loaded in template below.
|
||||
@ -385,11 +385,14 @@ class private_message
|
||||
include(is_readable($tpl_file) ? $tpl_file : e_PLUGIN.'pm/pm_template.php');
|
||||
|
||||
$template = $PM_NOTIFY;
|
||||
*/
|
||||
if(THEME_LEGACY){include_once(THEME.'pm_template.php');}
|
||||
if (!$PM_NOTIFY){$PM_NOTIFY = e107::getTemplate('pm', 'pm', 'notify');}
|
||||
|
||||
if(empty($template)) // BC Fallback.
|
||||
if(empty($PM_NOTIFY)) // BC Fallback.
|
||||
{
|
||||
|
||||
$template =
|
||||
$PM_NOTIFY =
|
||||
"<div>
|
||||
<h4>".LAN_PM_101."{SITENAME}</h4>
|
||||
<table class='table table-striped'>
|
||||
@ -416,7 +419,7 @@ class private_message
|
||||
$data['PM_URL'] = $url;// e107::url('pm','index', null, array('mode'=>'full')).'?show.'.$pmid;
|
||||
$data['PM_BUTTON'] = "<a class='btn btn-primary' href='".$url."'>".LAN_PM_113."</a>";// e107::url('pm','index', null, array('mode'=>'full')).'?show.'.$pmid;
|
||||
|
||||
$text = e107::getParser()->simpleParse($template, $data);
|
||||
$text = e107::getParser()->simpleParse($PM_NOTIFY, $data);
|
||||
|
||||
$eml = array();
|
||||
$eml['email_subject'] = LAN_PM_100.USERNAME;
|
||||
@ -921,4 +924,4 @@ class private_message
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
43
e107_plugins/pm/private_msg_menu.php → e107_plugins/pm/pm_menu.php
Executable file → Normal file
43
e107_plugins/pm/private_msg_menu.php → e107_plugins/pm/pm_menu.php
Executable file → Normal file
@ -22,7 +22,9 @@
|
||||
* @subpackage pm
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
$pm_prefs = e107::getPlugPref('pm');
|
||||
if(check_class($pm_prefs['pm_class']))
|
||||
{
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
if (!e107::isInstalled('pm')) { return ''; }
|
||||
|
||||
@ -75,7 +77,7 @@ if(!function_exists('pm_show_popup'))
|
||||
}
|
||||
|
||||
|
||||
$pm_prefs = e107::getPlugPref('pm');
|
||||
//$pm_prefs = e107::getPlugPref('pm');
|
||||
//global $sysprefs, $pm_prefs;
|
||||
|
||||
|
||||
@ -97,29 +99,10 @@ $pmManager = new pmbox_manager($pm_prefs);
|
||||
|
||||
//setScVar('pm_handler_shortcodes','pmManager', $pmManager);
|
||||
|
||||
define('PM_INBOX_ICON', "<img src='".e_PLUGIN_ABS."pm/images/mail_get.png' class='icon S16' alt='".LAN_PLUGIN_PM_INBOX."' title='".LAN_PLUGIN_PM_INBOX."' />");
|
||||
define('PM_OUTBOX_ICON', "<img src='".e_PLUGIN_ABS."pm/images/mail_send.png' class='icon S16' alt='".LAN_PLUGIN_PM_OUTBOX."' title='".LAN_PLUGIN_PM_OUTBOX."' />");
|
||||
define('PM_SEND_LINK', LAN_PLUGIN_PM_NEW);
|
||||
define('NEWPM_ANIMATION', "<img src='".e_PLUGIN_ABS."pm/images/newpm.gif' alt='' />");
|
||||
$template = e107::getTemplate('pm', 'pm_menu');
|
||||
|
||||
|
||||
$sc_style['PM_SEND_PM_LINK']['pre'] = "<br /><br />";
|
||||
$sc_style['PM_SEND_PM_LINK']['post'] = "";
|
||||
|
||||
$sc_style['PM_INBOX_FILLED']['pre'] = "[";
|
||||
$sc_style['PM_INBOX_FILLED']['post'] = "%]";
|
||||
|
||||
$sc_style['PM_OUTBOX_FILLED']['pre'] = "[";
|
||||
$sc_style['PM_OUTBOX_FILLED']['post'] = "%]";
|
||||
|
||||
$sc_style['PM_NEWPM_ANIMATE']['pre'] = "<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>";
|
||||
$sc_style['PM_NEWPM_ANIMATE']['post'] = "</a>";
|
||||
|
||||
$sc_style['PM_BLOCKED_SENDERS_MANAGE']['pre'] = "<br />[ <a href='".e_PLUGIN_ABS."pm/pm.php?blocked'>";
|
||||
$sc_style['PM_BLOCKED_SENDERS_MANAGE']['post'] = '</a> ]';
|
||||
|
||||
|
||||
if(!isset($pm_menu_template))
|
||||
//if(!isset($pm_menu_template))
|
||||
if(!isset($PM_MENU_TEMPLATE))
|
||||
{
|
||||
//FIXME URL Breaks
|
||||
/*
|
||||
@ -138,7 +121,8 @@ if(!isset($pm_menu_template))
|
||||
";
|
||||
*/
|
||||
|
||||
$pm_menu_template = "
|
||||
// $pm_menu_template = "
|
||||
$PM_MENU_TEMPLATE = "
|
||||
<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>".PM_INBOX_ICON."</a>
|
||||
<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>".LAN_PLUGIN_PM_INBOX."</a>
|
||||
{PM_NEWPM_ANIMATE}
|
||||
@ -153,15 +137,16 @@ if(!isset($pm_menu_template))
|
||||
";
|
||||
}
|
||||
|
||||
|
||||
if(check_class($pm_prefs['pm_class']))
|
||||
{
|
||||
//if(check_class($pm_prefs['pm_class']))
|
||||
//{
|
||||
$tp = e107::getParser();
|
||||
$sc = e107::getScBatch('pm',TRUE, 'pm');
|
||||
|
||||
$pm_inbox = $pmManager->pm_getInfo('inbox');
|
||||
$sc->wrapper('pm_menu');
|
||||
|
||||
$txt = "\n".$tp->parseTemplate($pm_menu_template, TRUE, $sc);
|
||||
// $txt = "\n".$tp->parseTemplate($pm_menu_template, TRUE, $sc);
|
||||
$txt = "\n".$tp->parseTemplate($PM_MENU_TEMPLATE, TRUE, $sc);
|
||||
|
||||
if($pm_inbox['inbox']['new'] > 0 && $pm_prefs['popup'] && strpos(e_SELF, 'pm.php') === FALSE && $_COOKIE['pm-alert'] != 'ON')
|
||||
{
|
68
e107_plugins/pm/templates/pm_menu_template.php
Normal file
68
e107_plugins/pm/templates/pm_menu_template.php
Normal file
@ -0,0 +1,68 @@
|
||||
<?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)
|
||||
*
|
||||
* PM plugin - template file
|
||||
*
|
||||
* $Source: /cvs_backup/e107_0.8/e107_plugins/pm/pm_template.php,v $
|
||||
* $Revision$
|
||||
* $Date$
|
||||
* $Author$
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* e107 Private messenger plugin
|
||||
*
|
||||
* @package e107_plugins
|
||||
* @subpackage pm
|
||||
* @version $Id$;
|
||||
*/
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
|
||||
define('PM_INBOX_ICON', "<img src='".e_PLUGIN_ABS."pm/images/mail_get.png' class='icon S16' alt='".LAN_PLUGIN_PM_INBOX."' title='".LAN_PLUGIN_PM_INBOX."' />");
|
||||
define('PM_OUTBOX_ICON', "<img src='".e_PLUGIN_ABS."pm/images/mail_send.png' class='icon S16' alt='".LAN_PLUGIN_PM_OUTBOX."' title='".LAN_PLUGIN_PM_OUTBOX."' />");
|
||||
define('PM_SEND_LINK', LAN_PLUGIN_PM_NEW);
|
||||
define('NEWPM_ANIMATION', "<img src='".e_PLUGIN_ABS."pm/images/newpm.gif' alt='' />");
|
||||
/*
|
||||
$sc_style['PM_SEND_PM_LINK']['pre'] = "<br /><br />";
|
||||
$sc_style['PM_SEND_PM_LINK']['post'] = "";
|
||||
|
||||
$sc_style['PM_INBOX_FILLED']['pre'] = "[";
|
||||
$sc_style['PM_INBOX_FILLED']['post'] = "%]";
|
||||
|
||||
$sc_style['PM_OUTBOX_FILLED']['pre'] = "[";
|
||||
$sc_style['PM_OUTBOX_FILLED']['post'] = "%]";
|
||||
|
||||
$sc_style['PM_NEWPM_ANIMATE']['pre'] = "<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>";
|
||||
$sc_style['PM_NEWPM_ANIMATE']['post'] = "</a>";
|
||||
|
||||
$sc_style['PM_BLOCKED_SENDERS_MANAGE']['pre'] = "<br />[ <a href='".e_PLUGIN_ABS."pm/pm.php?blocked'>";
|
||||
$sc_style['PM_BLOCKED_SENDERS_MANAGE']['post'] = '</a> ]';
|
||||
*/
|
||||
$PM_MENU_WRAPPER['PM_SEND_PM_LINK']= "<br /><br />{---}";
|
||||
$PM_MENU_WRAPPER['PM_INBOX_FILLED']=$PM_MENU_WRAPPER['PM_OUTBOX_FILLED']= "[{---}%]";
|
||||
$PM_MENU_WRAPPER['PM_NEWPM_ANIMATE']= "<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>{---}</a>";
|
||||
$PM_MENU_WRAPPER['PM_BLOCKED_SENDERS_MANAGE']= "<br />[ <a href='".e_PLUGIN_ABS."pm/pm.php?blocked'>{---}</a> ]";
|
||||
|
||||
// $pm_menu_template = "
|
||||
$PM_MENU_TEMPLATE = "
|
||||
<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>".PM_INBOX_ICON."</a>
|
||||
<a href='".e_PLUGIN_ABS."pm/pm.php?inbox'>".LAN_PLUGIN_PM_INBOX."</a>
|
||||
{PM_NEWPM_ANIMATE}
|
||||
<br />
|
||||
{PM_INBOX_TOTAL} ".LAN_PM_36.", {PM_INBOX_UNREAD} ".LAN_PM_37." {PM_INBOX_FILLED}
|
||||
<br />
|
||||
<a href='".e_PLUGIN_ABS."pm/pm.php?outbox'>".PM_OUTBOX_ICON."</a>
|
||||
<a href='".e_PLUGIN_ABS."pm/pm.php?outbox'>".LAN_PLUGIN_PM_OUTBOX."</a><br />
|
||||
{PM_OUTBOX_TOTAL} ".LAN_PM_36.", {PM_OUTBOX_UNREAD} ".LAN_PM_37." {PM_OUTBOX_FILLED}
|
||||
{PM_SEND_PM_LINK}
|
||||
{PM_BLOCKED_SENDERS_MANAGE}
|
||||
";
|
||||
|
||||
|
57
e107_plugins/pm/pm_template.php → e107_plugins/pm/templates/pm_template.php
Executable file → Normal file
57
e107_plugins/pm/pm_template.php → e107_plugins/pm/templates/pm_template.php
Executable file → Normal file
@ -25,7 +25,7 @@
|
||||
|
||||
if (!defined('e107_INIT')) { exit; }
|
||||
|
||||
global $sc_style; // Needed for the PM_REPLY shortcode!
|
||||
//global $sc_style; // Needed for the PM_REPLY shortcode!
|
||||
|
||||
if(deftrue('BOOTSTRAP') && deftrue('FONTAWESOME'))
|
||||
{
|
||||
@ -37,7 +37,7 @@ else
|
||||
if (!defined('PM_READ_ICON')) define('PM_READ_ICON', "<img src='".e_PLUGIN_ABS."pm/images/read.png' class='icon S16' alt='".LAN_PM_111."' />");
|
||||
if (!defined('PM_UNREAD_ICON')) define('PM_UNREAD_ICON', "<img src='".e_PLUGIN_ABS."pm/images/unread.png' class='icon S16' alt='".LAN_PM_27."' />");
|
||||
}
|
||||
|
||||
/*
|
||||
$sc_style['PM_ATTACHMENT_ICON']['pre'] = " ";
|
||||
$sc_style['PM_ATTACHMENTS']['pre'] = "<div class='alert alert-block alert-info'>";
|
||||
$sc_style['PM_ATTACHMENTS']['post'] = "</div>";
|
||||
@ -73,8 +73,21 @@ $sc_style['PM_REPLY']['pre'] = "<tr>
|
||||
$sc_style['PM_REPLY']['post'] = "</td>
|
||||
</tr>
|
||||
";
|
||||
*/
|
||||
|
||||
$PM_SEND_PM = "<div id='pm-send-pm'>
|
||||
$PM_WRAPPER['PM_ATTACHMENT_ICON']= " {---}";
|
||||
$PM_WRAPPER['PM_ATTACHMENTS']= "<div class='alert alert-block alert-info'>{---}</div>";
|
||||
|
||||
//$sc_style['PM_NEXTPREV']['pre'] = "<tr><td class='forumheader' colspan='6' style='text-align:left'> ".LAN_PM_59;
|
||||
//$sc_style['PM_NEXTPREV']['post'] = "</td></tr>";
|
||||
|
||||
$PM_WRAPPER['PM_EMOTES']= "<tr><td class='forumheader3'>".LAN_PM_7.": </td><td class='forumheader3'>{---}</td></tr>";
|
||||
$PM_WRAPPER['PM_ATTACHMENT']= "<tr><td class='forumheader3'>".LAN_PM_8.": </td><td class='forumheader3'>{---}</td></tr>";
|
||||
$PM_WRAPPER['PM_RECEIPT']= "<tr><td class='forumheader3'>".LAN_PM_9.": </td><td class='forumheader3'>{---}</td></tr>";
|
||||
$PM_WRAPPER['PM_REPLY']= "<tr><td class='forumheader' style='text-align:center' colspan='2'>{---}</td></tr>";
|
||||
|
||||
//$PM_SEND_PM = "<div id='pm-send-pm'>
|
||||
$PM_TEMPLATE['send'] = "<div id='pm-send-pm'>
|
||||
<table class='table fborder'>
|
||||
<thead>
|
||||
<tr>
|
||||
@ -103,7 +116,8 @@ $PM_SEND_PM = "<div id='pm-send-pm'>
|
||||
</div>
|
||||
";
|
||||
|
||||
$PM_INBOX_HEADER = "
|
||||
//$PM_INBOX_HEADER = "
|
||||
$PM_TEMPLATE['inbox']['start'] = "
|
||||
<table class='table table-striped fborder'>
|
||||
<thead>
|
||||
<tr>
|
||||
@ -118,7 +132,8 @@ $PM_INBOX_HEADER = "
|
||||
<tbody>
|
||||
";
|
||||
|
||||
$PM_INBOX_TABLE = "{SETIMAGE: w=30&h=30&crop=1}
|
||||
//$PM_INBOX_TABLE = "{SETIMAGE: w=30&h=30&crop=1}
|
||||
$PM_TEMPLATE['inbox']['item'] = "{SETIMAGE: w=30&h=30&crop=1}
|
||||
<tr class='{PM_STATUS_CLASS}'>
|
||||
<td class='forumheader3'>{PM_SELECT}</td>
|
||||
<td class='forumheader3'>{PM_ATTACHMENT_ICON}</td>
|
||||
@ -130,13 +145,15 @@ $PM_INBOX_TABLE = "{SETIMAGE: w=30&h=30&crop=1}
|
||||
</tr>
|
||||
";
|
||||
|
||||
$PM_INBOX_EMPTY = "
|
||||
//$PM_INBOX_EMPTY = "
|
||||
$PM_TEMPLATE['inbox']['empty'] = "
|
||||
<tr>
|
||||
<td colspan='6' class='forumheader'>".LAN_PM_34."</td>
|
||||
</tr>
|
||||
";
|
||||
|
||||
$PM_INBOX_FOOTER = "
|
||||
//$PM_INBOX_FOOTER = "
|
||||
$PM_TEMPLATE['inbox']['end'] = "
|
||||
<tr>
|
||||
<td class='forumheader' colspan='3'>
|
||||
<input type='hidden' name='pm_come_from' value='inbox' />
|
||||
@ -150,7 +167,8 @@ $PM_INBOX_FOOTER = "
|
||||
</table>
|
||||
";
|
||||
|
||||
$PM_OUTBOX_HEADER = "
|
||||
//$PM_OUTBOX_HEADER = "
|
||||
$PM_TEMPLATE['outbox']['start'] = "
|
||||
<table class='table table-striped fborder'>
|
||||
<thead>
|
||||
<tr>
|
||||
@ -165,7 +183,8 @@ $PM_OUTBOX_HEADER = "
|
||||
<tbody>
|
||||
";
|
||||
|
||||
$PM_OUTBOX_TABLE = "
|
||||
//$PM_OUTBOX_TABLE = "
|
||||
$PM_TEMPLATE['outbox']['item'] = "
|
||||
<tr>
|
||||
<td class='forumheader3'>{PM_SELECT}</td>
|
||||
<td class='forumheader3'>{PM_ATTACHMENT_ICON}</td>
|
||||
@ -176,7 +195,8 @@ $PM_OUTBOX_TABLE = "
|
||||
</tr>
|
||||
";
|
||||
|
||||
$PM_OUTBOX_EMPTY = "
|
||||
//$PM_OUTBOX_EMPTY = "
|
||||
$PM_TEMPLATE['outbox']['empty'] = "
|
||||
<tr>
|
||||
<td colspan='6' class='forumheader'>".LAN_PM_34."</td>
|
||||
</tr>
|
||||
@ -194,7 +214,8 @@ $PM_OUTBOX_FOOTER = "
|
||||
</table>
|
||||
";*/
|
||||
|
||||
$PM_OUTBOX_FOOTER = "
|
||||
//$PM_OUTBOX_FOOTER = "
|
||||
$PM_TEMPLATE['outbox']['end'] = "
|
||||
<tr>
|
||||
<td class='forumheader' colspan='3'>
|
||||
<input type='hidden' name='pm_come_from' value='inbox' />
|
||||
@ -210,7 +231,7 @@ $PM_OUTBOX_FOOTER = "
|
||||
|
||||
|
||||
|
||||
$PM_BLOCKED_HEADER = "
|
||||
$PM_TEMPLATE['blocked']['start'] = "
|
||||
<table class='table table-striped fborder'>
|
||||
<tr>
|
||||
<td class='fcaption' style='width:5%'> </td>
|
||||
@ -220,7 +241,7 @@ $PM_BLOCKED_HEADER = "
|
||||
</tr>
|
||||
";
|
||||
|
||||
$PM_BLOCKED_TABLE = "
|
||||
$PM_TEMPLATE['blocked']['item'] = "
|
||||
<tr>
|
||||
<td class='forumheader3'>{PM_BLOCKED_SELECT}</td>
|
||||
<td class='forumheader3'>{PM_BLOCKED_USER=link}</td>
|
||||
@ -229,13 +250,13 @@ $PM_BLOCKED_TABLE = "
|
||||
</tr>
|
||||
";
|
||||
|
||||
$PM_BLOCKED_EMPTY = "
|
||||
$PM_TEMPLATE['blocked']['empty'] = "
|
||||
<tr>
|
||||
<td colspan='4' class='forumheader'>".LAN_PM_67."</td>
|
||||
</tr>
|
||||
";
|
||||
|
||||
$PM_BLOCKED_FOOTER = "
|
||||
$PM_TEMPLATE['blocked']['end'] = "
|
||||
<tr>
|
||||
<td class='forumheader' colspan='4' style='text-align:center'>
|
||||
{PM_DELETE_BLOCKED_SELECTED}
|
||||
@ -246,7 +267,8 @@ $PM_BLOCKED_FOOTER = "
|
||||
|
||||
|
||||
|
||||
$PM_SHOW =
|
||||
//$PM_SHOW =
|
||||
$PM_TEMPLATE['show'] =
|
||||
"<div class='pm-show' style='text-align: center'>
|
||||
<table class='table table-bordered table-striped fborder'>
|
||||
<tr>
|
||||
@ -268,7 +290,8 @@ $PM_SHOW =
|
||||
";
|
||||
|
||||
|
||||
$PM_NOTIFY =
|
||||
//$PM_NOTIFY =
|
||||
$PM_TEMPLATE['notify'] =
|
||||
"<div>
|
||||
<h4>".LAN_PM_101."{SITENAME}</h4>
|
||||
<table class='table table-striped'>
|
Loading…
x
Reference in New Issue
Block a user