Skip to content

Commit

Permalink
Utilize new summary.delimiter setting rather than constant
Browse files Browse the repository at this point in the history
  • Loading branch information
rhukster committed Feb 3, 2015
1 parent dc65475 commit eb4eafd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions system/src/Grav/Common/Page/Page.php
Original file line number Diff line number Diff line change
Expand Up @@ -407,10 +407,11 @@ public function content($var = null)
}

// Handle summary divider
$divider_pos = strpos($this->content, '<p>'.SUMMARY_DELIMITER.'</p>');
$delimiter = self::$grav['config']->get('site.summary.delimiter', '===');
$divider_pos = strpos($this->content, "<p>{$delimiter}</p>");
if ($divider_pos !== false) {
$this->summary_size = $divider_pos;
$this->content = str_replace('<p>'.SUMMARY_DELIMITER.'</p>', '', $this->content);
$this->content = str_replace("<p>{$delimiter}</p>", '', $this->content);
}

}
Expand Down

0 comments on commit eb4eafd

Please sign in to comment.