summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlester@linux2.lsces.co.uk <lester@linux2.lsces.co.uk>2012-10-10 12:53:50 +0100
committerlester@linux2.lsces.co.uk <lester@linux2.lsces.co.uk>2012-10-10 12:53:50 +0100
commitbb950ce9c4abdf7c1378a5e429d65f60d275f332 (patch)
treedc68b97ded626605dddc19f677009adba06dc35a
parent24b8b021b4c19ea8149305f0f1d7f464d4cf35cc (diff)
downloadnewsletters-bb950ce9c4abdf7c1378a5e429d65f60d275f332.tar.gz
newsletters-bb950ce9c4abdf7c1378a5e429d65f60d275f332.tar.bz2
newsletters-bb950ce9c4abdf7c1378a5e429d65f60d275f332.zip
e_strict corrections to parameters to match base classPRE_BOOTSTRAP
-rw-r--r--BitNewsletter.php10
-rw-r--r--BitNewsletterEdition.php12
2 files changed, 11 insertions, 11 deletions
diff --git a/BitNewsletter.php b/BitNewsletter.php
index 316704f..75cbda1 100644
--- a/BitNewsletter.php
+++ b/BitNewsletter.php
@@ -51,7 +51,7 @@ class BitNewsletter extends LibertyContent {
$this->mAdminContentPerm = 'p_newsletters_admin';
}
- function load( $pUserId = NULL ) {
+ function load( $pContentId = NULL, $pPluginParams = NULL ) {
if( $this->verifyId( $this->mNewsletterId ) || $this->verifyId( $this->mContentId ) ) {
global $gBitSystem;
@@ -62,12 +62,12 @@ class BitNewsletter extends LibertyContent {
$this->getServicesSql( 'content_load_function', $selectSql, $joinSql, $whereSql, $bindVars );
- if( $pUserId ) {
+/* if( $pUserId ) {
error_log( 'BitNewsleters: user id loading not implemented yet' );
$whereSql = "";
$joinSql = "";
}
-
+*/
$query = "SELECT * $selectSql
FROM `".BIT_DB_PREFIX."newsletters` n
INNER JOIN `".BIT_DB_PREFIX."liberty_content` lc ON( n.`content_id`=lc.`content_id` )
@@ -273,7 +273,7 @@ class BitNewsletter extends LibertyContent {
}
*/
- function getList( &$pListHash ) {
+ public static function getList( &$pListHash ) {
global $gBitDb;
if ( empty( $pParamHash["sort_mode"] ) ) {
$pListHash['sort_mode'] = 'created_desc';
@@ -379,7 +379,7 @@ class BitNewsletter extends LibertyContent {
* @param object $pNewsletterId of the item to use
* @return object Url String
*/
- public static function getDisplayUrlFromHash( $pParamHash ) {
+ public static function getDisplayUrlFromHash( &$pParamHash ) {
global $gBitSystem;
$ret = NULL;
if( BitBase::verifyId( $pParamHash['nl_id'] ) ) {
diff --git a/BitNewsletterEdition.php b/BitNewsletterEdition.php
index b16c25a..ab57393 100644
--- a/BitNewsletterEdition.php
+++ b/BitNewsletterEdition.php
@@ -64,7 +64,7 @@ class BitNewsletterEdition extends LibertyMime {
return( count( $this->mErrors ) == 0 );
}
- function store( $pParamHash ) {
+ function store( &$pParamHash ) {
if( $this->verify( $pParamHash ) ) {
$this->mDb->StartTrans();
if( parent::store( $pParamHash ) ) {
@@ -83,7 +83,7 @@ class BitNewsletterEdition extends LibertyMime {
return( count( $this->mErrors ) == 0 );
}
- function load() {
+ function load( $pContentId = NULL, $pPluginParams = NULL ) {
if( $this->verifyId( $this->mEditionId ) || $this->verifyId( $this->mContentId ) ) {
global $gBitSystem;
@@ -123,14 +123,14 @@ class BitNewsletterEdition extends LibertyMime {
* @param object PostId of the item to use
* @return object Url String
*/
- public static function getDisplayUrlFromHash( $pHash ) {
+ public static function getDisplayUrlFromHash( &$pParamHash ) {
$ret = NULL;
global $gBitSystem;
- if( BitBase::verifyId( $pHash['edition_id'] ) ) {
+ if( BitBase::verifyId( $pParamHash['edition_id'] ) ) {
if( $gBitSystem->isFeatureActive( 'pretty_urls' ) ) {
- $ret = NEWSLETTERS_PKG_URL.'edition/'.$pHash['edition_id'];
+ $ret = NEWSLETTERS_PKG_URL.'edition/'.$pParamHash['edition_id'];
} else {
- $ret = NEWSLETTERS_PKG_URL.'edition.php?edition_id='.$pHash['edition_id'];
+ $ret = NEWSLETTERS_PKG_URL.'edition.php?edition_id='.$pParamHash['edition_id'];
}
} else {
$ret = NEWSLETTERS_PKG_URL.'edition.php';