Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add meta and OG #60

Merged
merged 1 commit into from Jul 11, 2015
Merged

Add meta and OG #60

merged 1 commit into from Jul 11, 2015

Conversation

mattstauffer
Copy link
Member

Fixes #47

Output::

            <!-- Schema.org markup for Google+ -->
        <meta itemprop="name" content="Introducing Gistlog landing pages">
        <meta itemprop="description" content="It&#039;s great that Gistlog makes it easy to write Gist-powered, Markdown-formatted, blog posts. But what if you want to use it as your entire blogging platform? We&#039;re working on it, and here&#039;s a first step:">

        <!-- Open Graph data -->
        <meta property="og:title" content="Introducing Gistlog landing pages">
        <meta property="og:type" content="article">
        <meta property="og:url" content="http://localhost:8095/mattstauffer/a82db51468a02f53442d">
        <meta property="og:description" content="It&#039;s great that Gistlog makes it easy to write Gist-powered, Markdown-formatted, blog posts. But what if you want to use it as your entire blogging platform? We&#039;re working on it, and here&#039;s a first step:">
        <meta property="og:site_name" content="Gistlog">

public function getPreview()
{
$body = strip_tags($this->renderHtml());
return substr(strip_tags($body), 0, strpos($body, ' ', 200));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Double strip tags?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

whoops!

@adamwathan
Copy link
Contributor

👍

mattstauffer added a commit that referenced this pull request Jul 11, 2015
@mattstauffer mattstauffer merged commit ec17311 into master Jul 11, 2015
@mattstauffer mattstauffer deleted the feature/meta-and-og-preview branch July 11, 2015 13:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants