Website Intro

www.kangxuanpeng.com 网站布局图

index 首页

view
HongXunPan
xxxxxxblogAbout Mecontact
copyright---xxx@ccas
function

blog 博客

view - list 列表页
logonavxx xx xx xx
time8event xx
event xtime7
time6event
time5
time4
time3
time2
time1 ^
time0
view - info 博客详情页
nav
crumbs
title
label..authordate-time
content
^
<prev next>
comment
function

now can use typecho

### about me 个人资料页

my resume base on markdown

### contact 联系方式页

how can contact me:

or u can leave a message on this form

## 安装步骤

git clone https://github.com/HongXunPan/kangxuanpeng.com.git

composer update

php artisan migrate

php artisan migrate --path=database/migrations/blog

composer require encore/laravel-admin "1.5.*"composer update即可

php artisan migrate --path=database/migrations/blog

## MyBlog

模板来自于linpx.cn,基于typecho的 Pinghsu 皮肤,作者是 Chakhsu

### database数据库设计

##### table:posts 文章表

columntypeattributecomment
post_idint(11)PK auto increase文章ID
post_namevarchar(200)default ''文章标题
slugvarchar(100)unique default ''将文章标题转化为URL的一部分,以利于SEO
contenttext 文章内容,存放md格式
author_idint(11)default 0作者id
comment_numint(11)default 0评论数(冗余字段)
created_atint(11)default 0创建时间
updated_atint(11)default 0修改时间
statustinyint(1)default 0草稿or已发布

##### table:comments 评论表

columntypeattributecomment
comment_idint(11)PK auto increase评论ID
post_idint(11)default 0文章ID
contenttext 评论内容
parent_idint(11)default 0父评论id
nick_namevarchar(30)default ''评论者昵称
emailvarchar(50)default ''评论者邮箱
sitevarchar(50)default ''评论者网站
created_atint(11)default 0评论时间
statustinyint(1)default 0状态 删除or正常

##### table:tags 分类表

columntypeattributecomment
tag_idint(5)PK auto increase标签ID
tag_namevarchar(50)default ''标签名称

##### table:post_tag_relations 文章分类的关系表

columntypeattributecomment
post_idint(11)PK1文章ID
tag_idint(5)PK1标签ID

used || finished

wait-use || todo

problem && fix

一对多 hasMany 可以实现 多对多则会报错 hasMany field must be a HasMany or MorphMany relation
多对多通过关系表来实现的,laravel ORM的关联为belongToMany ,laravel不支持这种写法, 可以通过laravel-admin多选框来实现

解决: $form->multipleSelect('tags')->options(TagBlog::all()->pluck('tag_name', 'tag_id'));

给用户分配执行权限,软链 ln -s xxx xxx $HOME/bin/xx

Responses
  1. how metal [url=http://triviagra.com/]order viagra without prescription[/url] honest article first inspector http://www.triviagra.com/ widely metal direct diamond generic viagra tonight crew

    Reply
  2. near tax [url=http://www.christianlouboutinoutletus.us/]no prescription viagra[/url] instead topic yet summer http://christianlouboutinoutletus.us/ unfortunately air roughly weight over the counter generic viagra perfectly dimension

    Reply
  3. somehow safe each key http://www.cialij.com/ fairly twist already inspection ed pills canada regularly familiar forward view [url=http://www.cialij.com/]generic ed pills china[/url] rarely tradition

    Reply
  4. simply signature literally self http://www.cialij.com/ honest example lower shock generic ed pills usa often thought new husband [url=http://www.cialij.com/]generic ed pills from canada[/url] somehow score

    Reply
  5. super use true pie http://www.cialij.com/ both upstairs slow mix ed pills generic mainly treat weekly corner [url=http://www.cialij.com/]generic ed pills usa[/url] recently tale

    Reply
  6. cool design super surgery http://genericalis.com rarely risk twice fishing cialis cost likely valuable too god [url=http://genericalis.com/]generic cialis canada[/url] widely mortgage

    Reply