Skip to content

Instantly share code, notes, and snippets.

Summer summerblue

Block or report user

Report or block summerblue

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:10075418
注册的时候出现下面的 error, 我一直使用的帐号, 用户名 "summer_charlie" 还有密码, 密码我就不贴出来了, 居然会报错...
The username must be between 2 - 9 characters. (9个字符??? OMG,Why?)
The password may only contain letters and numbers. (只能字母和数字?? 我的密码里面有特殊符号 "!" , 亲, 密码不是越复杂越好吗? 你去看看 Apple 的注册, 没有特殊符号都不让注册. )
The password confirmation may only contain letters and numbers.
因为你们是 beta 版本, 就冒昧提了以下反馈, 注册页面应该是很 welcome 的, 不能一下子就把用户给拒绝了呀.
View gist:47db3ce1555c1ffb63c6
<?php
use Phphub\Core\CreatorListener;
class TopicsController extends \BaseController implements CreatorListener
{
public function __construct()
{
$this->beforeFilter('auth', ['only' => 'create', 'store']);
View gist:b9865eb3f78c75c3dfaa
<?php namespace Phphub\Topic;
use Phphub\Forms\TopicCreationForm;
use Phphub\Core\CreatorListener;
use Topic, Auth;
class TopicCreator
{
protected $topicModel;
protected $form;
View gist:0cfc4607ad9083908eb5
{
"id": "1408631499.2148.1282148919",
"version": 1,
"time": 1408631498.8228,
"method": "GET",
"uri": "/",
"headers": {
"content-type": [
""
],
View gist:607a4072486f6790fac5
<h2>用例 Use Case</h2>
<ul><li>会员可以对某个主题投票;</li>
<li>会员可以对某个回复进行投票;</li>
</ul>
<p>Laravel 的 ORM Eloquent 对这一类型的业务逻辑有很好的支持, 如下面几个例子</p>
<h4>一般 CMS 通用评论功能</h4>
View gist:14604c682735dcf3a097
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<meta name="robots" content="noindex,nofollow" />
<style>
/* Copyright (c) 2010, Yahoo! Inc. All rights reserved. Code licensed under the BSD License: http://developer.yahoo.com/yui/license.html */
html{color:#000;background:#FFF;}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td{margin:0;padding:0;}table{border-collapse:collapse;border-spacing:0;}fieldset,img{border:0;}address,caption,cite,code,dfn,em,strong,th,var{font-style:normal;font-weight:normal;}li{list-style:none;}caption,th{text-align:left;}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:normal;}q:before,q:after{content:'';}abbr,acronym{border:0;font-variant:normal;}sup{vertical-align:text-top;}sub{vertical-align:text-bottom;}input,textarea,select{font-family:inherit;font-size:inherit;font-weight:inherit;}input,textarea,select{*font-size:100%;}le
View gist:3b1dbfa89f6dc87b3e2d
#########################
# .gitignore file for Xcode4 / OS X Source projects
#
# Version 2.0
# For latest version, see: http://stackoverflow.com/questions/49478/git-ignore-file-for-xcode-projects
#
# 2013 updates:
# - fixed the broken "save personal Schemes"
#
# NB: if you are storing "built" products, this WILL NOT WORK,
View nginx.conf
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
View mongodb_aggregation_lbs_search_orderby_time_limit3_offset3.js
// 找捷運台北車站附近距離2公里內的捷運站、依照建立時間做排序、找第4、5、6筆的資料
db.lbs_test.aggregate(
{
$geoNear : {
near : [25.046084,121.517542],
distanceField : "dist",
maxDistance : 2 / 111.12
}
},
{
View mongodb_aggregation_lbs_search_orderby_time_limit3.js
// 找捷運台北車站附近距離2公里內的捷運站、依照建立時間做排序、找前3筆資料
db.lbs_test.aggregate(
{
$geoNear : {
near : [25.046084,121.517542],
distanceField : "dist",
maxDistance : 2 / 111.12
}
},
{
You can’t perform that action at this time.