Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

changed title, markdown rendering, and hidden values

  • Loading branch information...
commit 5a58b06872e4e8c12602b018dc5d270fa963b098 1 parent 639a384
@daylerees authored
Showing with 11 additions and 7 deletions.
  1. +10 −6 classes/scribe.php
  2. +1 −1  views/layouts/main.blade.php
View
16 classes/scribe.php
@@ -6,15 +6,19 @@ class Scribe
{
public static function content($name)
{
- $content = Scribe_Content::where_name($name)->first();
- if (! $content) return 'No content.';
- return $content->content;
+ $content = Scribe_Content::where_name($name)
+ ->where_hidden(false)
+ ->first();
+ if (! $content) return null;
+ return Markdown($content->content);
}
public static function content_id($id)
{
- $content = Scribe_Content::find($id);
- if (! $content) return 'No content.';
- return new Markdown($content->content);
+ $content = Scribe_Content::where_id($id)
+ ->where_hidden(false)
+ ->first();
+ if (! $content) return null;
+ return Markdown($content->content);
}
}
View
2  views/layouts/main.blade.php
@@ -2,7 +2,7 @@
<html>
<head>
<meta charset="UTF-8">
- <title>Admin</title>
+ <title>Scribe</title>
{{ HTML::style('bundles/scribe/css/style.css') }}
</head>
<body>
Please sign in to comment.
Something went wrong with that request. Please try again.