1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-17 03:54:09 +02:00

renamed internal shortcode variable from 'eParserVars' to 'var'. ie. use $this->var['field_name'] inside shortcode batches.

This commit is contained in:
CaMer0n
2012-04-24 11:22:07 +00:00
parent 711a2965de
commit 6c790d9ab6
3 changed files with 15 additions and 14 deletions

View File

@@ -20,8 +20,8 @@ class gallery_shortcodes extends e_shortcode
function sc_gallery_caption($parm='')
{
$tp = e107::getParser();
$text = "<a title='".$tp->toAttribute($this->eParserVars['media_caption'])."' href='".e107::getParser()->replaceConstants($this->eParserVars['media_url'],'abs')."' rel='lightbox[Gallery2]' >";
$text .= $this->eParserVars['media_caption'];
$text = "<a title='".$tp->toAttribute($this->var['media_caption'])."' href='".e107::getParser()->replaceConstants($this->var['media_url'],'abs')."' rel='lightbox[Gallery2]' >";
$text .= $this->var['media_caption'];
$text .= "</a>";
return $text;
}
@@ -30,8 +30,8 @@ class gallery_shortcodes extends e_shortcode
{
$tp = e107::getParser();
$att = ($parm) ?$parm : 'aw=190&ah=150';
$text = "<a title='".$tp->toAttribute($this->eParserVars['media_caption'])."' href='".e107::getParser()->replaceConstants($this->eParserVars['media_url'],'abs')."' rel='lightbox[Gallery]' >";
$text .= "<img src='".e107::getParser()->thumbUrl($this->eParserVars['media_url'],$att)."' alt='' />";
$text = "<a title='".$tp->toAttribute($this->var['media_caption'])."' href='".e107::getParser()->replaceConstants($this->var['media_url'],'abs')."' rel='lightbox[Gallery]' >";
$text .= "<img src='".e107::getParser()->thumbUrl($this->var['media_url'],$att)."' alt='' />";
$text .= "</a>";
return $text;
}
@@ -39,8 +39,8 @@ class gallery_shortcodes extends e_shortcode
function sc_gallery_cat_title($parm='')
{
$tp = e107::getParser();
$text = "<a href='".e_SELF."?cat=".$this->eParserVars['media_cat_category']."'>";
$text .= $tp->toHtml($this->eParserVars['media_cat_title']);
$text = "<a href='".e_SELF."?cat=".$this->var['media_cat_category']."'>";
$text .= $tp->toHtml($this->var['media_cat_title']);
$text .= "</a>";
return $text;
}
@@ -48,8 +48,8 @@ class gallery_shortcodes extends e_shortcode
function sc_gallery_cat_thumb($parm='')
{
$att = ($parm) ?$parm : 'aw=190&ah=150';
$text = "<a href='".e_SELF."?cat=".$this->eParserVars['media_cat_category']."'>";
$text .= "<img src='".e107::getParser()->thumbUrl($this->eParserVars['media_cat_image'],$att)."' alt='' />";
$text = "<a href='".e_SELF."?cat=".$this->var['media_cat_category']."'>";
$text .= "<img src='".e107::getParser()->thumbUrl($this->var['media_cat_image'],$att)."' alt='' />";
$text .= "</a>";
return $text;
}