Skip to content
14 changes: 10 additions & 4 deletions e107_core/shortcodes/batch/user_shortcodes.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function __construct()
parent::__construct();

$pref = e107::getPref();

$tp = e107::getParser();
$this->commentsDisabled = vartrue($pref['comments_disabled']);

if(!empty($pref['comments_engine']))
Expand Down Expand Up @@ -462,11 +462,17 @@ function sc_user_forum_link($parm=null)

function sc_user_sendpm($parm=null)
{
$pref = e107::getPref();
$tp = e107::getParser();
// $pref = e107::getPref();
// why is this orphan $pref here?
// $tp = e107::getParser();
if(e107::isInstalled("pm") && ($this->var['user_id'] > 0))
{
return $tp->parseTemplate("{SENDPM={$this->var['user_id']}}");
$parm['user']=$this->var['user_id'];

return $this->tp->parseTemplate("{SENDPM:".http_build_query($parm).'}');
// return $tp->parseTemplate("{SENDPM:".$parms_str.'}');

// return $tp->parseTemplate("{SENDPM={$this->var['user_id']}}");
}
}

Expand Down
Loading