本文整理汇总了PHP中e107::isInstalled方法的典型用法代码示例。如果您正苦于以下问题:PHP e107::isInstalled方法的具体用法?PHP e107::isInstalled怎么用?PHP e107::isInstalled使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类e107
的用法示例。
在下文中一共展示了e107::isInstalled方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* Constructor.
*/
function __construct()
{
if (e107::isInstalled('nodejs_comment')) {
// Get plugin preferences.
$this->plugPrefs = e107::getPlugConfig('nodejs_comment')->getPref();
$this->renderMenu();
}
}
示例2: __construct
function __construct()
{
$pref = e107::pref('faqs');
if (!empty($pref['display_social']) && e107::isInstalled('social') == true) {
$this->share = true;
}
if (!empty($pref['display_datestamp'])) {
$this->datestamp = true;
}
}
示例3: __construct
function __construct()
{
$mes = e107::getMessage();
$frm = e107::getForm();
$tp = e107::getParser();
// $this->simulation();
$mailoutPlugins = e107::getConfig()->get('e_mailout_list');
if (empty($_GET['id'])) {
return;
}
$tmp = base64_decode($_GET['id']);
parse_str($tmp, $data);
$data['plugin'] = $tp->filter($data['plugin'], 'str');
$data['email'] = $tp->filter($data['email'], 'email');
e107::getMessage()->addDebug(print_a($data, true));
$plugin = vartrue($data['plugin'], false);
if (empty($data) || !e107::isInstalled($plugin) || !in_array($plugin, $mailoutPlugins)) {
$this->invalidURL();
return;
}
$ml = e107::getAddon($plugin, 'e_mailout');
if (!empty($data['userclass'])) {
$data['userclass'] = intval($data['userclass']);
$listName = e107::getUserClass()->getName($data['userclass']);
} else {
$listName = $ml->mailerName;
}
if (vartrue($_POST['remove']) && !empty($data)) {
if ($ml->unsubscribe('process', $data) != false) {
$text = "<p><b>" . $data['email'] . "</b> has been removed from " . $listName . ".</p>";
$mes->addSuccess($text);
} else {
$text = "<p>There was a problem when attempting to remove <b>" . $data['email'] . "</b> from " . $listName . ".</p>";
$mes->addError($text);
}
echo "<div class='container'>" . $mes->render() . "</div>";
return;
}
if ($ml->unsubscribe('check', $data) != false) {
$text = "<p>We are very sorry for the inconvenience. <br />Please click the button below to remove <b>" . $data['email'] . "</b> from <i>" . $listName . "</i>.</p>";
$text .= $frm->open('unsub', 'post', e_REQUEST_URI);
$text .= $frm->button('remove', 'Remove ', 'submit');
$text .= $frm->close();
$mes->setTitle('Unsubscribe', E_MESSAGE_INFO)->addInfo($text);
echo "<div class='container'>" . $mes->render() . "</div>";
return;
} else {
$this->invalidURL();
return;
}
}
示例4: sc_xurl_icons
/**
* {XURL_ICONS: size=2x}
*/
function sc_xurl_icons($parm = '')
{
$social = array('rss' => array('href' => e107::isInstalled('rss_menu') ? e107::url('rss_menu', 'index', array('rss_url' => 'news')) : '', 'title' => 'RSS/Atom Feed'), 'facebook' => array('href' => deftrue('XURL_FACEBOOK'), 'title' => 'Facebook'), 'twitter' => array('href' => deftrue('XURL_TWITTER'), 'title' => 'Twitter'), 'google-plus' => array('href' => deftrue('XURL_GOOGLE'), 'title' => 'Google Plus'), 'linkedin' => array('href' => deftrue('XURL_LINKEDIN'), 'title' => 'LinkedIn'), 'github' => array('href' => deftrue('XURL_GITHUB'), 'title' => 'Github'), 'pinterest' => array('href' => deftrue('XURL_PINTEREST'), 'title' => 'Pinterest'), 'flickr' => array('href' => deftrue('XURL_FLICKR'), 'title' => 'Flickr'), 'instagram' => array('href' => deftrue('XURL_INSTAGRAM'), 'title' => 'Instagram'), 'youtube' => array('href' => deftrue('XURL_YOUTUBE'), 'title' => 'YouTube'), 'vimeo' => array('href' => deftrue('XURL_VIMEO'), 'title' => 'Vimeo'));
$class = vartrue($parm['size']) ? 'fa-' . $parm['size'] : '';
$text = '';
foreach ($social as $id => $data) {
if ($data['href'] != '') {
$text .= '<a rel="external" href="' . $data['href'] . '" class="e-tip social-icon social-' . $id . '" title="' . $data['title'] . '">
<span class="fa fa-' . $id . ' ' . $class . '"></span>
</a>';
$text .= "\n";
}
}
if ($text != '') {
return '<p class="xurl-social-icons hidden-print">' . $text . '</p>';
}
}
示例5: profile
function profile($udata)
{
$pref = e107::getPref();
if (!$pref['cb_user_addon']) {
return array();
}
if (!($chatposts = e107::getRegistry('total_chatposts'))) {
$chatposts = 0;
// In case plugin not installed
if (e107::isInstalled("chatbox_menu")) {
$chatposts = e107::getDb()->count("chatbox");
}
e107::setRegistry('total_chatposts', $chatposts);
}
$perc = $chatposts > 0 ? round($udata['user_chats'] / $chatposts * 100, 2) : 0;
$var = array(0 => array('label' => LAN_PLUGIN_CHATBOX_MENU_POSTS, 'text' => $udata['user_chats'] . " ( " . $perc . "% )"));
return $var;
}
示例6: error_reporting
* e107 Chatbox plugin
*
* @package e107_plugins
* @subpackage chatbox
*/
error_reporting(E_ALL);
if (isset($_POST['chatbox_ajax'])) {
define('e_MINIMAL', true);
if (!defined('e107_INIT')) {
require_once '../../class2.php';
}
}
global $e107cache, $e_event, $e107;
$tp = e107::getParser();
$pref = e107::getPref();
if (!e107::isInstalled('chatbox_menu')) {
return '';
}
e107::lan('chatbox_menu', e_LANGUAGE);
// FIXME - start - LAN is not loaded
/*
if(($pref['cb_layer']==2) || isset($_POST['chatbox_ajax']))
{
if(isset($_POST['chat_submit']))
{
//Normally the menu.sc file will auto-load the language file, this is needed in case
//ajax is turned on and the menu is not loaded from the menu.sc
inclXXXude_lan(e_PLUGIN.'chatbox_menu/languages/'.e_LANGUAGE.'/'.e_LANGUAGE.'.php');
}
示例7: update_706_to_800
//.........这里部分代码省略.........
// echo $db_parser->make_table_list($actual_defs);
$actual_fields = $db_parser->parse_field_defs($actual_defs[0][2]);
if ($debugLevel)
{
$log->logMessage("Actual table structure: <br />".$db_parser->make_field_list($actual_fields), E_MESSAGE_DEBUG);
}
$diffs = $db_parser->compare_field_lists($req_fields,$actual_fields);
if (count($diffs[0]))
{ // Changes needed
if ($just_check) return update_needed("Field changes rqd; table: ".$ct);
// Do the changes here
if ($debugLevel)
{
$log->logMessage("List of changes found:<br />".$db_parser->make_changes_list($diffs), E_MESSAGE_DEBUG);
}
$qry = 'ALTER TABLE '.MPREFIX.$ct.' '.implode(', ',$diffs[1]);
if ($debugLevel)
{
$log->logMessage("Update Query used: ".$qry, E_MESSAGE_DEBUG);
}
$status = $sql->gen($qry) ? E_MESSAGE_SUCCESS : E_MESSAGE_ERROR;
$log->logMessage(LAN_UPDATE_21.$ct, $status);
catch_error($sql);
}
}
}
// Plugin tables whose definition needs changing significantly
foreach ($pluginChangedTables as $plugName => $plugList)
{
if (e107::isInstalled($plugName))
{
$ttc = explode(',',$plugList);
foreach ($ttc as $ct)
{
$sqlDefs = e_PLUGIN.$plugName.'/'.str_replace('_menu','',$plugName).'_sql.php'; // Filename containing definitions
// echo "Looking at file: {$sqlDefs}, table {$ct}<br />";
$req_defs = $db_parser->get_table_def($ct,$sqlDefs);
if (!is_array($req_defs))
{
echo "Couldn't get definitions from file {$sqlDefs}<br />";
continue;
}
$req_fields = $db_parser->parse_field_defs($req_defs[0][2]); // Required definitions
if (E107_DBG_SQLDETAILS)
{
$message = "Required plugin table structure: <br />".$db_parser->make_field_list($req_fields);
$log->logMessage($message, E_MESSAGE_DEBUG);
}
if ((($actual_defs = $db_parser->get_current_table($ct)) === FALSE) || !is_array($actual_defs)) // Adds current default prefix
{
// echo "Couldn't get table structure: {$ct}<br />";
}
else
{
// echo $db_parser->make_table_list($actual_defs);
$actual_fields = $db_parser->parse_field_defs($actual_defs[0][2]);
if (E107_DBG_SQLDETAILS)
{
$message= "Actual table structure: <br />".$db_parser->make_field_list($actual_fields);
$log->logMessage($message, E_MESSAGE_DEBUG);
示例8: Copyright
| Copyright (C) 2008-2010 e107 Inc (e107.org)
|
|
| Released under the terms and conditions of the
| GNU General Public License (http://gnu.org).
|
| $URL: https://e107.svn.sourceforge.net/svnroot/e107/trunk/e107_0.7/e107_plugins/links_page/links.php $
| $Revision: 11678 $
| $Id: links.php 11678 2010-08-22 00:43:45Z e107coders $
| $Author: e107coders $
+----------------------------------------------------------------------------+
*/
if (!defined('e107_INIT')) {
require_once '../../class2.php';
}
if (!e107::isInstalled('links_page')) {
e107::redirect();
exit;
}
$link_shortcodes = e107::getScBatch('links_page', TRUE);
require_once e_PLUGIN . 'links_page/link_defines.php';
require_once e_HANDLER . "userclass_class.php";
$eArrayStorage = e107::getArrayStorage();
$db = e107::getDb();
$mes = e107::getMessage();
require_once e_HANDLER . "form_handler.php";
$rs = new form();
require_once e_HANDLER . "file_class.php";
$fl = new e_file();
$cobj = e107::getComment();
require_once e_PLUGIN . 'links_page/link_class.php';
示例9: triggerHook
function triggerHook($data = '')
{
$text = '';
$e_event_list = e107::getPref('e_event_list');
if (is_array($e_event_list)) {
foreach ($e_event_list as $hook) {
if (e107::isInstalled($hook)) {
if (is_readable(e_PLUGIN . $hook . "/e_event.php")) {
require_once e_PLUGIN . $hook . "/e_event.php";
$name = "e_event_{$hook}";
if (class_exists($name)) {
$class = new $name();
switch ($data['method']) {
//returns array('caption'=>'', 'text'=>'');
case 'form':
if (method_exists($class, "event_{$data['method']}")) {
$text[] = $class->event_form($data);
}
break;
//returns string message
//returns string message
case 'create':
case 'update':
case 'delete':
if (method_exists($class, "event_{$data['method']}")) {
$text .= call_user_func(array($class, "event_{$data['method']}"), $data);
}
break;
}
}
}
}
}
}
return $text;
}
示例10: show_prefs
function show_prefs()
{
global $fPref;
$ns = e107::getRender();
$sql = e107::getDb();
//$e107 = e107::getInstance();
$frm = e107::getForm();
$mes = e107::getMessage();
$poll_installed = e107::isInstalled('poll');
if (!$poll_installed) {
if ($fPref->get('poll') == 1) {
$fPref['forum_poll'] = e_UC_NOBODY;
$fPref->save(false, true);
}
}
$text = "\n\t\t<form method='post' action='" . e_SELF . "?" . e_QUERY . "'>\n\n\t\t<table class='table adminform'>\n \t<colgroup span='2'>\n \t\t<col class='col-label' />\n \t\t<col class='col-control' />\n \t</colgroup>\n\t\t<tr>\n\t\t\t<td>" . FORLAN_44 . ":</td>\n\t\t\t<td>" . ($fPref->get('enclose') ? "<input type='checkbox' name='forum_enclose' value='1' checked='checked' />" : "<input type='checkbox' name='forum_enclose' value='1' />") . "<span class='field-help'>" . FORLAN_45 . "</div></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_65 . ":</td>\n\t\t\t<td><input class='tbox' type='text' name='forum_title' size='15' value='" . $fPref->get('title') . "' maxlength='100' /></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_47 . ":</td>\n\t\t\t<td>" . ($fPref->get('notify') ? "<input type='checkbox' name='email_notify' value='1' checked='checked' />" : "<input type='checkbox' name='email_notify' value='1' />") . "<span class='field-help'>" . FORLAN_48 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_177 . ":</td>\n\t\t\t<td>" . ($fPref->get('notify_on') ? "<input type='checkbox' name='email_notify_on' value='1' checked='checked' />" : "<input type='checkbox' name='email_notify_on' value='1' />") . "<span class='field-help'>" . FORLAN_178 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_49 . ":</td>";
if ($poll_installed) {
//<td>".e107::getUserClass()->uc_dropdown("mods[{$f['forum_id']}]", $f['forum_moderators'], 'admin,classes')."</td>
$text .= "<td>" . e107::getUserClass()->uc_dropdown('forum_poll', $fPref->get('poll'), 'nobody,public,member,admin,main,classes') . '<span class="field-help">' . FORLAN_50 . '</span></td>';
} else {
$text .= "<td>" . FORLAN_66 . "</td>";
}
$text .= "\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_70 . ":";
if (!$pref['image_post']) {
$text .= "<br /><b>" . FORLAN_139 . "</b>";
// TODO LAN
}
if (!is_writable(e_PLUGIN . 'forum/attachments')) {
$text .= "<br /><b>Attachment dir (" . e_PLUGIN_ABS . 'forum/attachments' . ") is not writable!</b>";
// TODO LAN
}
$text .= "</td>\n\t\t\t<td>" . ($fPref->get('attach') ? "<input type='checkbox' name='forum_attach' value='1' checked='checked' />" : "<input type='checkbox' name='forum_attach' value='1' />") . "<span class='field-help'>" . FORLAN_71 . " <a href='" . e_ADMIN . "upload.php'>" . FORLAN_130 . "</a> " . FORLAN_131 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_134 . ":</td>\n\t\t\t<td><input class='tbox' type='text' size='3' maxlength='5' name='forum_maxwidth' value='" . $fPref->get('maxwidth') . "' /><span class='field-help'>" . FORLAN_135 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_136 . ":</td>\n\t\t\t<td>" . ($fPref->get('linkimg') ? "<input type='checkbox' name='forum_linkimg' value='1' checked='checked' />" : "<input type='checkbox' name='forum_linkimg' value='1' />") . "<span class='field-help'>" . FORLAN_137 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_51 . ":</td>\n\t\t\t<td>" . ($fPref->get('track') ? "<input type='checkbox' name='forum_track' value='1' checked='checked' />" : "<input type='checkbox' name='forum_track' value='1' />") . "<span class='field-help'>" . FORLAN_52 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_112 . ":</td>\n\t\t\t<td>" . ($fPref->get('redirect') ? "<input type='checkbox' name='forum_redirect' value='1' checked='checked' />" : "<input type='checkbox' name='forum_redirect' value='1' />") . "<span class='field-help'>" . FORLAN_113 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_116 . ":</td>\n\t\t\t<td>" . ($fPref->get('reported_post_email') ? "<input type='checkbox' name='reported_post_email' value='1' checked='checked' />" : "<input type='checkbox' name='reported_post_email' value='1' />") . "<span class='field-help'>" . FORLAN_122 . "</span></td>\n\t\t</tr>\n\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_126 . ":</td>\n\t\t\t<td>" . ($fPref->get('forum_tooltip') ? "<input type='checkbox' name='forum_tooltip' value='1' checked='checked' />" : "<input type='checkbox' name='forum_tooltip' value='1' />") . "<span class='field-help'>" . FORLAN_127 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_128 . ":</td>\n\t\t\t<td><input class='tbox' type='text' name='forum_tiplength' size='15' value='" . $fPref->get('tiplength') . "' maxlength='20' /><span class='field-help'>" . FORLAN_129 . "</span></td>\n\t\t</tr>\n\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_53 . ":</td>\n\t\t\t<td><input class='tbox' type='text' name='forum_eprefix' size='15' value='" . $fPref->get('eprefix') . "' maxlength='20' /><span class='field-help'>" . FORLAN_54 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_55 . ":</td>\n\t\t\t<td><input class='tbox' type='text' name='forum_popular' size='3' value='" . $fPref->get('popular') . "' maxlength='3' /><span class='field-help'>" . FORLAN_56 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_57 . ":</td>\n\t\t\t<td><input class='tbox' type='text' name='forum_postspage' size='3' value='" . $fPref->get('postspage') . "' maxlength='3' /><span class='field-help'>" . FORLAN_58 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_186 . ":</td>\n\t\t\t<td><input class='tbox' type='text' name='forum_threadspage' size='3' value='" . $fPref->get('threadspage') . "' maxlength='3' /><span class='field-help'>" . FORLAN_187 . "</span></td>\n\t\t</tr>\n\n\t\t<tr>\n\t\t\t<td>" . FORLAN_132 . ":</td>\n\t\t\t<td>" . ($fPref->get('hilightsticky') ? "<input type='checkbox' name='forum_hilightsticky' value='1' checked='checked' />" : "<input type='checkbox' name='forum_hilightsticky' value='1' />") . "<span class='field-help'>" . FORLAN_133 . "</span></td>\n\t\t</tr>\n\t\t</table>\n\t\n\t\t<div class='buttons-bar center'>\n\t\t\t" . $frm->admin_button('updateoptions', LAN_UPDATE, 'update') . "\n\t\t</div>\n\t\t</form>\n";
$ns->tablerender(FORLAN_7, $mes->render() . $text);
}
示例11: header
* 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)
*
* Plugin - PDF Generator
*
* $Source: /cvs_backup/e107_0.8/e107_plugins/pdf/pdf.php,v $
* $Revision$
* $Date$
* $Author$
*
*/
require_once '../../class2.php';
if (!e107::isInstalled('pdf') || !e_QUERY) {
header('Location: ' . e_BASE . 'index.php');
}
$qs = explode('.', e_QUERY, 2);
$source = $qs[0];
$parms = varset($qs[1], '');
//include_lan(e_PLUGIN.'pdf/languages/'.e_LANGUAGE.'_admin_pdf.php');
//require_once(e_PLUGIN.'pdf/tcpdf.php'); //require the ufpdf class
require_once e_PLUGIN . 'pdf/e107pdf.php';
//require the e107pdf class
$pdf = new e107PDF();
if (strpos($source, 'plugin:') !== FALSE) {
$plugin = substr($source, 7);
if (file_exists(e_PLUGIN . $plugin . '/e_emailprint.php')) {
include_once e_PLUGIN . $plugin . '/e_emailprint.php';
if (function_exists('print_item_pdf')) {
示例12: downloadCategory
/*
* 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)
*
*
*
* $Source: /cvs_backup/e107_0.8/e107_plugins/download/handlers/category_class.php,v $
* $Revision$
* $Date$
* $Author$
*/
if (!e107::isInstalled('download')) {
exit;
}
class downloadCategory
{
var $cat_tree;
// Initialised with all categories in a tree structure
var $cat_count;
// Count visible subcats and subsubcats
var $down_count;
// Counts total downloads
function downloadCategory($nest_level = 1, $load_class = USERCLASS_LIST, $main_cat_load = '', $accum = FALSE)
{
// Constructor - make a copy of the tree for re-use
// $nest_level = 0 merges subsubcats with subcats. >0 creates full tree.
// If load-class non-null, assumed to be a 'class set' such as USERCLASS_LIST
示例13: show_mailform
/**
* Generate the HTML to show the mailout form. Used for both sending and editing
*
* @param $mailSource - array of mail information
* @return text for display
*/
function show_mailform(&$mailSource)
{
global $pref, $HANDLERS_DIRECTORY;
global $mailAdmin;
$sql = e107::getDb();
$ns = e107::getRender();
$tp = e107::getParser();
$frm = e107::getForm();
$mes = e107::getMessage();
if (!is_array($mailSource)) {
$mes = e107::getMessage();
$mes->add('Coding error - mail not array (521)', E_MESSAGE_ERROR);
//$ns->tablerender('ERROR!!', );
//exit;
}
$email_subject = varset($mailSource['mail_subject'], '');
$email_body = $tp->toForm(varset($mailSource['mail_body'], ''));
$email_id = varset($mailSource['mail_source_id'], '');
$text = '';
if (strpos($_SERVER['SERVER_SOFTWARE'], 'mod_gzip') && !is_readable(e_HANDLER . 'phpmailer/.htaccess')) {
$warning = LAN_MAILOUT_40 . ' ' . $HANDLERS_DIRECTORY . 'phpmailer/ ' . LAN_MAILOUT_41;
$ns->tablerender(LAN_MAILOUT_42, $warning);
}
$debug = e_MENU == "debug" ? "?[debug]" : "";
$text .= "<div>\n\t\t\t<form method='post' action='" . e_SELF . "?mode=makemail' id='mailout_form'>\n\t\t\t" . $this->emailSelector('all', varset($mailSource['mail_selectors'], FALSE)) . "\n\t\t\t<table class='table adminform'>\n\t\t\t<colgroup>\n\t\t\t\t<col class='col-label' />\n\t\t\t\t<col class='col-control' />\n\t\t\t</colgroup>\n\t\t\t<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_111 . ": </td>\n\t\t\t\t<td>" . $frm->text('email_title', varset($mailSource['mail_title'], '')) . "</td>\n\t\t\t</tr>\n\n\t\t\t<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_01 . ": </td>\n\t\t\t\t<td>" . $frm->text('email_from_name', varset($mailSource['mail_from_name'], USERNAME)) . "</td>\n\t\t\t</tr>\n\n\t\t\t<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_02 . ": </td>\n\t\t\t\t<td >" . $frm->text('email_from_email', varset($mailSource['mail_from_email'], USEREMAIL)) . "</td>\n\t\t\t</tr>";
// Add in the core and any plugin selectors here
/*$text .= "
<tr>
<td>".LAN_MAILOUT_03.": </td>
<td>".$this->emailSelector('all', varset($mailSource['mail_selectors'], FALSE))."</td>
</tr>";*/
$text .= "\n\t\t\t<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_04 . ": </td>\n\t\t\t\t<td>" . $frm->text('email_cc', varset($mailSource['mail_cc'], '')) . "</td>\n\t\t\t</tr>\n\n\t\t\t<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_05 . ": </td>\n\t\t\t\t<td>" . $frm->text('email_bcc', varset($mailSource['mail_bcc'], '')) . "</td>\n\t\t\t</tr>\n\n\t\t\t<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_51 . ": </td>\n\t\t\t\t<td>" . $frm->text('email_subject', varset($email_subject, '')) . "</td>\n\t\t\t</tr>";
// Attachment.
if (e107::isInstalled('download')) {
// TODO - use download plugin API
if ($sql->db_Select("download", "download_url,download_name", "download_id !='' ORDER BY download_name")) {
$text .= "<tr>\n\t\t\t\t<td>" . LAN_MAILOUT_07 . ": </td>\n\t\t\t\t<td >";
$text .= "<select class='tbox' name='email_attachment' >\n\t\t\t\t<option value=''> </option>\n";
while ($row = $this->e107->sql->db_Fetch()) {
$selected = $mailSource['mail_attach'] == $row['download_url'] ? "selected='selected'" : '';
// $text .= "<option value='".urlencode($row['download_url'])."' {$selected}>".htmlspecialchars($row['download_name'])."</option>\n";
$text .= "<option value='" . $row['download_url'] . "' {$selected}>" . htmlspecialchars($row['download_name']) . "</option>\n";
}
$text .= " </select>";
$text .= "</td>\n\t\t\t\t</tr>";
}
}
// TODO File-Picker from Media-Manager.
$text .= "\n\t\t\t<tr>\n\t\t\t<td>" . LAN_MAILOUT_09 . ": </td>\n\t\t\t<td >\n";
global $eplug_bb;
$eplug_bb[] = array('name' => 'shortcode', 'onclick' => 'expandit', 'onclick_var' => 'sc_selector', 'icon' => e_IMAGE . 'generic/bbcode/shortcode.png', 'helptext' => LAN_MAILOUT_11, 'function' => array($this, 'sc_Select'), 'function_var' => 'sc_selector');
$text .= $this->sendStyleSelect(varset($mailSource['mail_send_style'], ''));
$checked = isset($mailSource['mail_include_images']) && $mailSource['mail_include_images'] ? " checked='checked'" : '';
$text .= " <input type='checkbox' name='mail_include_images' value='1' {$checked} />" . LAN_MAILOUT_225;
$text .= "\n\t\t</td></tr>\n\n\t\t\t<tr>\n\t\t\t\n\t\t\t<td colspan='2'>" . $frm->bbarea('email_body', $email_body, 'mailout', 'helpb') . "</td>\n\t\t\t</tr>";
$text .= "\n\t\t\t<tr>\n\t\t\t<td colspan='2'>\n\t\t\t<div>";
// $text .= display_help('helpb','mailout');
if (e_WYSIWYG) {
$text .= "<span style='vertical-align: super;margin-left:5%;margin-bottom:auto;margin-top:auto'><input type='button' class='btn button' name='usrname' value=\"" . LAN_MAILOUT_16 . "\" onclick=\"tinyMCE.selectedInstance.execCommand('mceInsertContent',0,'|USERNAME|')\" />\n\t\t\t<input type='button' class='btn button' name='usrlink' value=\"" . LAN_MAILOUT_14 . "\" onclick=\"tinyMCE.selectedInstance.execCommand('mceInsertContent',0,'|DISPLAYNAME|')\" />\n\t\t\t<input type='button' class='btn button' name='usrlink' value=\"" . LAN_MAILOUT_17 . "\" onclick=\"tinyMCE.selectedInstance.execCommand('mceInsertContent',0,'|SIGNUP_LINK|')\" />\n\t\t\t<input type='button' class='btn button' name='usrid' value=\"" . LAN_MAILOUT_18 . "\" onclick=\"tinyMCE.selectedInstance.execCommand('mceInsertContent',0,'|USERID|')\" /></span>";
}
$text .= "\n\t\t\t</div></td>\n\t\t\t</tr>\n\t\t\t</table> ";
$text .= "<div class='buttons-bar center'>";
if ($email_id) {
$text .= $frm->hidden('mail_source_id', $email_id);
$text .= $frm->admin_button('update_email', LAN_UPDATE);
//$text .= "<input type='hidden' name='mail_source_id' value='".$email_id."' />";
//$text .= "<input class='button' type='submit' name='update_email' value=\"".LAN_UPDATE."\" />";
} else {
$text .= $frm->admin_button('save_email', LAN_SAVE, 'other');
}
$text .= $frm->admin_button('send_email', LAN_MAILOUT_08);
//
$text .= "</div>\n\n\t\t</form>\n\t\t</div>";
$ns->tablerender(LAN_MAILOUT_15, $mes->render() . $text);
// Render the complete form
}
示例14: pingit
* 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)
*
* Plugin configuration module - gsitemap
*
* $Source: /cvs_backup/e107_0.8/e107_plugins/gsitemap/e_module.php,v $
* $Revision$
* $Date$
* $Author$
*
*/
if (!defined('e107_INIT')) {
exit;
}
if (!e107::isInstalled('gsitemap')) {
return '';
}
global $e_event, $e107cache, $ns;
// $e_event->register("newspost", "pingit");
// $e_event->register("newsupd", "pingit"); // Disable these for now, until admin functions written
function pingit($vals)
{
global $admin_log;
require e_PLUGIN . "gsitemap/weblog_pinger.php";
$pinger = new Weblog_Pinger();
// $pinger->ping_ping_o_matic("Ekzemplo", "http://www.ekzemplo.com/");
$xml_rpc_server = "blogsearch.google.com";
$xml_rpc_port = 80;
$xml_rpc_path = "/ping/RPC2";
$xml_rpc_method = "weblogUpdates.extendedPing";
示例15: header
*
* 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)
*
* Plugin administration - newsfeeds
*
* $Source: /cvs_backup/e107_0.8/e107_plugins/trackback/modtrackback.php,v $
* $Revision$
* $Date$
* $Author$
*
*/
$eplug_admin = true;
require_once "../../class2.php";
if (!getperms("P") || !e107::isInstalled('trackback') || !$pref['trackbackEnabled']) {
header("location:" . e_BASE . "index.php");
exit;
}
require_once e_ADMIN . "auth.php";
if (isset($_POST['moderate'])) {
$temp = array();
if (is_array($_POST['trackback_delete'])) {
while (list($key, $cid) = each($_POST['trackback_delete'])) {
$cid = intval($cid);
if ($cid > 0) {
$sql->db_Delete("trackback", "trackback_id=" . $cid);
$temp[] = $cid;
}
}
if (count($temp)) {