mirror of
https://github.com/e107inc/e107.git
synced 2025-08-23 06:33:22 +02:00
Page support for single page with anchor navigation.
This commit is contained in:
@@ -51,7 +51,7 @@ else
|
||||
$highlighted_text = highlight_string($code_text, TRUE);
|
||||
$highlighted_text = str_replace(array("<code>","</code>"),"",$highlighted_text);
|
||||
$divClass = ($parm) ? $parm : 'code_highlight';
|
||||
$ret = "<code class='".$tp -> toAttribute($divClass)." code-box {$class}' style='unicode-bidi: embed; direction: ltr'>{$highlighted_text}</code>";
|
||||
$ret = "<pre class='prettyprint linenums ".$tp -> toAttribute($divClass)." code-box {$class}' style='unicode-bidi: embed; direction: ltr'>{$highlighted_text}</pre>";
|
||||
}
|
||||
$ret = str_replace("[", "[", $ret);
|
||||
return $ret;
|
@@ -20,7 +20,7 @@ class cpage_shortcodes extends e_shortcode
|
||||
// var $var; // parsed DB values
|
||||
|
||||
function sc_cpagetitle($parm='')
|
||||
{
|
||||
{
|
||||
return e107::getParser()->toHTML($this->getParserVars()->title, true, 'TITLE');
|
||||
}
|
||||
|
||||
@@ -81,6 +81,12 @@ class cpage_shortcodes extends e_shortcode
|
||||
return $this->page['page_id'];
|
||||
}
|
||||
|
||||
function sc_cpageanchor()
|
||||
{
|
||||
$frm = e107::getForm();
|
||||
return $frm->name2id($this->page['page_title']);
|
||||
}
|
||||
|
||||
// Not a shortcode really, as it shouldn't be cached at all :/
|
||||
function cpagecomments()
|
||||
{
|
||||
|
@@ -573,10 +573,17 @@ echo "</head>\n";
|
||||
|
||||
|
||||
|
||||
|
||||
echo "<body".$body_onload.">\n";
|
||||
if(!deftrue('BODYTAG')) //TODO Discuss a better way?
|
||||
{
|
||||
echo "<body".$body_onload.">\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
echo BODYTAG."\n";
|
||||
}
|
||||
|
||||
// Bootstrap Modal Window - too important to template.
|
||||
/*
|
||||
echo '<div id="uiModal" style="display:none" class="modal hide fade" tabindex="-1" role="dialog" aria-hidden="true">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
@@ -590,7 +597,7 @@ echo '<div id="uiModal" style="display:none" class="modal hide fade" tabindex="-
|
||||
</div>
|
||||
</div>
|
||||
';
|
||||
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user