定制 bbit/blog-bundle 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

bbit/blog-bundle

Composer 安装命令:

composer require bbit/blog-bundle

包简介

symfony BBITBlogBundle

README 文档

README

A very simple blogbundle for symfony2. STILL A WORK IN PROGRESS

Can be seen live at http://branchbit.be/blog & http://statushka.com/blog

Step 1: Download BBITBlogBundle using composer

Add BBITBlogBundle in your composer.json:

{
    "require": {
        "knplabs/knp-markdown-bundle": "~1.3",
        "eko/feedbundle":  "dev-master",
        "bbit/blog-bundle": "dev-master"
    }
}

Now tell composer to download the bundles by running the command:

$ php composer.phar install

Composer will install the bbit/blog-bundle bundle to your project's vendor/BBIT directory.

Step 2: Enable the bundles

Enable the bundle in the kernel:

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new Knp\Bundle\MarkdownBundle\KnpMarkdownBundle(),
        new Eko\FeedBundle\EkoFeedBundle(),
        new BBIT\BlogBundle\BBITBlogBundle(),
    );
}

Step 3: Config

bbit_blog:
    extend_template: 'AcmeWebsiteBundle:Default:layout.html.twig' #should contain a block called 'blogContent'
    disqus_shortname: 'AcmeBlog'
    addthis_pubid: 'ra-55cxxxxxxxxx648'
    btn_class: 'btn-buy hover-effect'
    eko_feed:
        feeds:
            post:
                title:       'Acme Blog Feed'
                description: 'Acme blog Feed Description'
                link:
                    route_name: bbit_blog_rss_view
                encoding:    'utf-8'

Step 4:

Update your database.

Add BBITBlogBundle to the assetic.bundle config

Add routing file:

bbit_blog:
    resource: "@BBITBlogBundle/Resources/config/routing.yml"
    prefix:   /blog/

Step 5: Add content

A very simple limited admin-CRUD is located at /blog/admin/post.

Posts are rendered in markdown.

Step 6: View content

Blog is located at /blog.

Rss feed is located at /blog/rss.

Supports "Engage by Disqus" for comments.

Supports "AddThis" for sharing.

统计信息

  • 总下载量: 37
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 1
  • 开发语言: CSS

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-08-11