yii-blog A huge improvement of the old and boring demo blog that comes with yii framework.

  1. Overview
  2. Demo
  3. Features
  4. Requirements
  5. Usage
  6. Donations

Overview

A huge improvement of the old and boring demo blog that comes with yii framework.

This extension is a module that you can use in any existing Yii application.

Demo

Click here for the demo (To log in: admin / 123456)

Features

  • Can reply to comments
  • Can create categories and subcategories
  • Multilingual (The blog currently has 2 language packs available: English and Spanish)
  • Additional widgets: Search, Categories, Archives and Most commented posts
  • Share buttons
  • User management: Registration form, Subscription system, Password recovery, Internal messaging and Can ban annoying users
  • Integration with tinyMCE editor
  • Integration with captcha extended extension
  • Integration with PHP Mailer extension
  • Role based access control (RBAC): Guests, Readers, Authors, Editors, Publishers and Admins
  • Fully responsive
  • And much more!

Requirements

Yii 1.1.14 or above

Usage

  • Download the files and put them in protected/modules/blog
  • You must add this in *protected/config/main.php**:
'modules'=>array(
        'blog'=>array(
        //PHP Mailer details
			'emailHost' => 'youremailhost',
			'emailPort' => 'youremailport', 
			'emailUsername' => 'youremailusername',
			'emailPassword' => 'youremailpassword',		
			'emailAltMessage' => 'To view the message, please use an HTML compatible email viewer.',
        ),
),
  • You must add these rules in the urlManager array:
'urlManager'=>array(
   'urlFormat'=>'path',
   'showScriptName'=>false,
   'rules'=>array(
      '<lang:\w+>/blog/<category:\d+>/<post:\d+>/<title:.*?>'=>'blog/post/view',
      '<lang:\w+>/blog/tag/<tag:.*?>'=>'blog/post/index',
      '<lang:\w+>/blog/<category:\d+>'=> 'blog/post/index',
      '<lang:\w+>/blog'=> 'blog/post/index',
      '<lang:\w+>/blog/register'=> 'blog/user/register',
      '<lang:\w+>/blog/passwordrecovery'=> 'blog/user/passwordrecovery',
      '<lang:\w+>/blog/user/<user:\d+>'=> 'blog/user/view',
      '<lang:\w+>/blog/<controller:\w+>/<action:\w+>'=>'blog/<controller>/<action>',
   )
)
  • It uses a SQLite database, so you don't have to create tables.
  • The following folders must be writable: protected/modules/blog/data, protected/modules/blog/assets/images/flags and protected/modules/blog/assets/images/avatars
  • You can log in using: admin / 123456
  • If you want to customize the introductory text of the blog entries you will have to insert a page break using the tinyMCE editor
  • You should add the following code in your layout to print the language flags:
<?php
	if(isset($this->module->id) && $this->module->id == 'blog')
		$this->printBlogFlags();
?> 
  • You should add the following code in your head section:
<head>
<!-- Other tags here -->

<?php if(isset($this->metaDescription)) : ?>
     <meta name="description" content="<?= $this->metaDescription ?>" />
<?php endif; ?>
<?php if(isset($this->metaKeywords)) : ?>
     <meta name="keywords" content="<?= $this->metaKeywords ?>" />
<?php endif; ?>
<?php if(isset($this->metaRobots)) : ?>
     <meta name="robots" content="<?= $this->metaRobots ?>" />
<?php endif; ?>
<?php if(isset($this->canonical)) : ?>
     <link rel="canonical" href="<?= $this->canonical ?>" />
<?php endif; ?> 
</head>

Donations

Donations are welcome. Thanks for your support!!!

Paypal

2 0
4 followers
1 432 downloads
Yii Version: 1.1.*
License: BSD-2-Clause
Category: User Interface
Developed by: oligalma
Created on: Jan 23, 2015
Last updated: 5 years ago

Downloads

show all

Related Extensions