diff options
| -rw-r--r-- | BitMailer.php | 20 | ||||
| -rw-r--r-- | admin/admin_newsletters_inc.php | 10 | ||||
| -rw-r--r-- | templates/admin_newsletters.tpl | 4 | ||||
| -rw-r--r-- | templates/edit_edition.tpl | 2 | ||||
| -rw-r--r-- | templates/unsubscribe_inc.tpl | 2 | ||||
| -rw-r--r-- | templates/user_subscriptions.tpl | 2 | ||||
| -rw-r--r-- | track.php | 4 |
7 files changed, 22 insertions, 22 deletions
diff --git a/BitMailer.php b/BitMailer.php index e732322..1a45b5c 100644 --- a/BitMailer.php +++ b/BitMailer.php @@ -1,12 +1,12 @@ <?php /** - * $Header: /cvsroot/bitweaver/_bit_newsletters/Attic/BitMailer.php,v 1.17 2006/02/01 18:42:23 squareing Exp $ + * $Header: /cvsroot/bitweaver/_bit_newsletters/Attic/BitMailer.php,v 1.18 2006/03/01 20:16:17 spiderr Exp $ * * Copyright (c) 2004 bitweaver.org * All Rights Reserved. See copyright.txt for details and a complete list of authors. * Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details * - * $Id: BitMailer.php,v 1.17 2006/02/01 18:42:23 squareing Exp $ + * $Id: BitMailer.php,v 1.18 2006/03/01 20:16:17 spiderr Exp $ * * Class that handles editions of newsletters * @package newsletters @@ -15,7 +15,7 @@ * * @author spiderr <spider@steelsun.com> * - * @version $Revision: 1.17 $ $Date: 2006/02/01 18:42:23 $ $Author: squareing $ + * @version $Revision: 1.18 $ $Date: 2006/03/01 20:16:17 $ $Author: spiderr $ */ /** @@ -34,11 +34,11 @@ class BitMailer extends phpmailer { function BitMailer () { global $gBitDb, $gBitSystem, $gBitLanguage; $this->mDb = $gBitDb; - $this->From = $gBitSystem->getPreference( 'bitmailer_sender_email', $gBitSystem->getPreference( 'sender_email', $_SERVER['SERVER_ADMIN'] ) ); - $this->FromName = $gBitSystem->getPreference( 'bitmailer_from', $gBitSystem->getPreference( 'siteTitle' ) ); - $this->Host = $gBitSystem->getPreference( 'bitmailer_servers', $gBitSystem->getPreference( 'feature_server_name', '127.0.0.1' ) ); - $this->Mailer = $gBitSystem->getPreference( 'bitmailer_protocol', 'smtp' ); // Alternative to IsSMTP() - $this->WordWrap = $gBitSystem->getPreference( 'bitmailer_word_wrap', 75 ); + $this->From = $gBitSystem->getConfig( 'bitmailer_sender_email', $gBitSystem->getConfig( 'sender_email', $_SERVER['SERVER_ADMIN'] ) ); + $this->FromName = $gBitSystem->getConfig( 'bitmailer_from', $gBitSystem->getConfig( 'siteTitle' ) ); + $this->Host = $gBitSystem->getConfig( 'bitmailer_servers', $gBitSystem->getConfig( 'feature_server_name', '127.0.0.1' ) ); + $this->Mailer = $gBitSystem->getConfig( 'bitmailer_protocol', 'smtp' ); // Alternative to IsSMTP() + $this->WordWrap = $gBitSystem->getConfig( 'bitmailer_word_wrap', 75 ); if( !$this->SetLanguage( $gBitLanguage->getLanguage(), UTIL_PKG_PATH.'phpmailer/language/' ) ) { $this->SetLanguage( 'en' ); } @@ -94,7 +94,7 @@ class BitMailer extends phpmailer { if( $content->load() ) { $body[$pick['content_id']]['body'] = $content->render(); $body[$pick['content_id']]['subject'] = $content->getTitle(); - $body[$pick['content_id']]['reply_to'] = $content->getField( 'reply_to', $gBitSystem->getPreference( 'sender_email', $_SERVER['SERVER_ADMIN'] ) ); + $body[$pick['content_id']]['reply_to'] = $content->getField( 'reply_to', $gBitSystem->getConfig( 'sender_email', $_SERVER['SERVER_ADMIN'] ) ); $body[$pick['content_id']]['object'] = $content; } // $content[$pick['content_id']] = LibertyBase::getLibertyObject(); @@ -109,7 +109,7 @@ class BitMailer extends phpmailer { } $htmlBody = $unsub . $body[$pick['content_id']]['body'] . $unsub . '<img src="'.NEWSLETTERS_PKG_URI.'track.php?sub='.$pick['url_code'].'" alt="" />'; - $this->AddReplyTo( $body[$pick['content_id']]['reply_to'], $gBitSystem->getPreference( 'bitmailer_from' ) ); + $this->AddReplyTo( $body[$pick['content_id']]['reply_to'], $gBitSystem->getConfig( 'bitmailer_from' ) ); print "TO: $pick[email]\t"; if( $this->sendMail( $pick, $body[$pick['content_id']]['subject'], $htmlBody ) ) { print "SENT\n"; diff --git a/admin/admin_newsletters_inc.php b/admin/admin_newsletters_inc.php index 34f9008..3fff590 100644 --- a/admin/admin_newsletters_inc.php +++ b/admin/admin_newsletters_inc.php @@ -1,21 +1,21 @@ <?php -// $Header: /cvsroot/bitweaver/_bit_newsletters/admin/admin_newsletters_inc.php,v 1.2 2005/12/29 22:18:33 spiderr Exp $ +// $Header: /cvsroot/bitweaver/_bit_newsletters/admin/admin_newsletters_inc.php,v 1.3 2006/03/01 20:16:18 spiderr Exp $ $formNewsletterFeatures = array( "bitmailer_sender_email" => array( 'label' => 'From Email', 'note' => 'If empty, it will default to the site Sender Email', - 'default' => $gBitSystem->getPreference( 'sender_email', $_SERVER['SERVER_ADMIN'] ), + 'default' => $gBitSystem->getConfig( 'sender_email', $_SERVER['SERVER_ADMIN'] ), ), "bitmailer_from" => array( 'label' => 'From Name', 'note' => '', - 'default' => $gBitSystem->getPreference( 'siteTitle' ), + 'default' => $gBitSystem->getConfig( 'siteTitle' ), ), "bitmailer_servers" => array( 'label' => 'Mail Servers', 'note' => '', - 'default' => $gBitSystem->getPreference( 'feature_server_name', '127.0.0.1' ), + 'default' => $gBitSystem->getConfig( 'feature_server_name', '127.0.0.1' ), ), "bitmailer_protocol" => array( 'label' => 'Protocol', @@ -36,7 +36,7 @@ if( $processForm ) { foreach( array_keys( $formNewsletterFeatures ) as $key ) { if( empty( $_REQUEST[$key] ) || $_REQUEST[$key] != $formNewsletterFeatures[$key]['default'] ) { - $gBitSystem->storePreference( $key, isset( $_REQUEST[$key] ) ? $_REQUEST[$key] : NULL ); + $gBitSystem->storeConfig( $key, isset( $_REQUEST[$key] ) ? $_REQUEST[$key] : NULL ); } } } diff --git a/templates/admin_newsletters.tpl b/templates/admin_newsletters.tpl index 077d843..85ed020 100644 --- a/templates/admin_newsletters.tpl +++ b/templates/admin_newsletters.tpl @@ -2,7 +2,7 @@ {form legend="Newsletter Features"} <input type="hidden" name="page" value="{$page}" /> - {if !$gBitSystem->getPreference( 'feature_server_name' )} + {if !$gBitSystem->getConfig( 'feature_server_name' )} {formfeedback error="Server name is not defined!"} {tr}You must <a href="{$smarty.const.KERNEL_PKG_URL}admin/index.php?page=server">define the server name</a> for proper background operation of the mail script.{/tr} {/if} @@ -11,7 +11,7 @@ <div class="row"> {formlabel label=`$output.label` for=$item} {forminput} - <input type="text" name="{$item}" value="{$gBitSystem->getPreference($item,$output.default)}" id="{$item}" /> + <input type="text" name="{$item}" value="{$gBitSystem->getConfig($item,$output.default)}" id="{$item}" /> {formhelp note=`$output.note` page=`$output.page`} {/forminput} </div> diff --git a/templates/edit_edition.tpl b/templates/edit_edition.tpl index d6ecbb9..b314112 100644 --- a/templates/edit_edition.tpl +++ b/templates/edit_edition.tpl @@ -70,7 +70,7 @@ <div class="row"> {formlabel label="Reply-To" for="replyto"} {forminput} - <input type="text" maxlength="250" size="40" name="reply_to" id="replyto" value="{$pageInfo.reply_to|default:$gBitSystem->getPreference('sender_email',$smarty.server.SERVER_ADMIN)|escape:html}" /> + <input type="text" maxlength="250" size="40" name="reply_to" id="replyto" value="{$pageInfo.reply_to|default:$gBitSystem->getConfig('sender_email',$smarty.server.SERVER_ADMIN)|escape:html}" /> {formhelp note="This is the email address to which any replies will be sent."} {/forminput} </div> diff --git a/templates/unsubscribe_inc.tpl b/templates/unsubscribe_inc.tpl index 4a91bff..2900d44 100644 --- a/templates/unsubscribe_inc.tpl +++ b/templates/unsubscribe_inc.tpl @@ -1,2 +1,2 @@ -{tr}You have received this message because you are registered at{/tr} <a href="{$smarty.const.BIT_ROOT_URL}">{$gBitSystem->getPreference('siteTitle', $smarty.server.HTTP_HOST)}</a>. {tr}You can always cancel your subscription using:{/tr}<br/> +{tr}You have received this message because you are registered at{/tr} <a href="{$smarty.const.BIT_ROOT_URL}">{$gBitSystem->getConfig('siteTitle', $smarty.server.HTTP_HOST)}</a>. {tr}You can always cancel your subscription using:{/tr}<br/> <a href="{$smarty.const.NEWSLETTERS_PKG_URI}?unsubscribe={$code}">{$smarty.const.NEWSLETTERS_PKG_URI}?sub={$url_code}</a> diff --git a/templates/user_subscriptions.tpl b/templates/user_subscriptions.tpl index 0533fa9..fd034d3 100644 --- a/templates/user_subscriptions.tpl +++ b/templates/user_subscriptions.tpl @@ -40,7 +40,7 @@ <div class="row"> {formlabel label="Permanent Unsubscribe"} {forminput} - <input type="checkbox" name="unsubscribe_all" value="y" {if $subInfo.unsubscribe_all}checked="checked"{/if} /> {tr}Remove myself from all lists, and receive no further mailings from{/tr} {$gBitSystem->getPreference('siteTitle','this site')}.</br> + <input type="checkbox" name="unsubscribe_all" value="y" {if $subInfo.unsubscribe_all}checked="checked"{/if} /> {tr}Remove myself from all lists, and receive no further mailings from{/tr} {$gBitSystem->getConfig('siteTitle','this site')}.</br> {/forminput} </div> <div class="row submit"> @@ -1,5 +1,5 @@ <?php -// $Header: /cvsroot/bitweaver/_bit_newsletters/track.php,v 1.1 2005/12/29 17:22:47 spiderr Exp $ +// $Header: /cvsroot/bitweaver/_bit_newsletters/track.php,v 1.2 2006/03/01 20:16:17 spiderr Exp $ // Copyright (c) 2006 - bitweaver.org - Christian Fowler, Max Kremmel, et. al // All Rights Reserved. See copyright.txt for details and a complete list of authors. @@ -15,7 +15,7 @@ if( isset( $_REQUEST["sub"] ) || $gBitUser->isRegistered() ) { } // open the file in a binary mode -$trackImage = $gBitSystem->getPreference( 'newsletter_tracking_image', NEWSLETTERS_PKG_PATH.'images/track.gif' ); +$trackImage = $gBitSystem->getConfig( 'newsletter_tracking_image', NEWSLETTERS_PKG_PATH.'images/track.gif' ); if( $fp = fopen( $trackImage, 'rb') ) { // send the right headers |
