lucianmarin / pressdown

Blogging with PHP, Markdown and Jekyll type posts

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Post body error

laurensiusadi opened this issue · comments

Previous commit solved and now I can see the homepage, but with errors:

image

It says the error comes from

$post[trim($d[0])] = trim(trim($d[1]), '"');

Adding isset there did dismiss the error, but when opening post page, the post body isn't there.
Turns out the error comes from:

if ($line === "---\n") {

If I changed the line to

if (trim($line) === "---") {

It works okay now.

Fixed this too on develop branch. Your text editor ended the line with something else that \n.