- Scott Chacon on the Interwebs(リンク切れ)
- Scott Chacon on the Interwebs
- GitHub Flow - The best way to use Git and GitHub
31 Aug 2011
======== | |
パッチの作り方 | |
======== | |
$ mkdir wordpress | |
$ cd wordpress # ここがドキュメントルート | |
$ svn co http://develop.svn.wordpress.org/trunk/ . | |
$ svn update # 作業を行う直前に毎回実行! | |
ファイルを追加した場合は `svn add` でそのファイルを追加する。 |
<?php defined('C5_EXECUTE') or die("Access Denied."); | |
Loader::model('section', 'multilingual'); | |
class MultilingualTextHelper { | |
/** | |
* Takes area name string (like Header) and add language string (like Header Ja JP) | |
* @param string $text | |
* @return string |
(function() { | |
if (!window.Modernizr) { | |
return; | |
} | |
var ua = new String(window.navigator.userAgent.toLowerCase()); | |
ua.has = function (cond) { | |
return this.indexOf(cond) != -1; | |
}; |
<?php defined('C5_EXECUTE') or die("Access Denied."); | |
Loader::library('3rdparty/mobile_detect'); | |
$md = new Mobile_Detect(); | |
if ($md->isMobile()) { | |
include('mobile.php'); | |
} else { | |
include('default.php'); | |
} |
<?php foreach ($pages as $page): | |
// Prepare data for each page being listed... | |
$pubTime = strtotime($page->getCollectionDatePublic()); | |
// 60 seconds, 60 minutes, 24 hours, 3 days | |
$new = ((time() - $pubTime) < (60 * 60 * 24 * 3)) ? '<p class="new">New</p>' : ''; | |
/* The HTML from here through "endforeach" is repeated for every item in the list... */ ?> | |
doctype html | |
html.no-js(lang='en') | |
head | |
meta(charset='utf-8') | |
meta(name='viewport', content='width=device-width, initial-scale=1.0') | |
title Foundation | |
link(rel='stylesheet', href='stylesheets/app.css') | |
script(src='bower_components/modernizr/modernizr.js') | |
body | |
.row |
Tested with concrete5.7.3.
[SITE NAME]
to your site name on the line 572 and 585 of controller.php
controller.php
to /application/blocks/form/
(create folder if not existed)block_form_submission_user.php
block_form_submission_user.php
to /application/mail/
<?php | |
// application/jobs/update_page_permissions.php | |
namespace Application\Job; | |
use Concrete\Core\Cache\Cache; | |
use Job as AbstractJob; | |
use Page; | |
use PageList; | |
class UpdatePagePermissions extends AbstractJob |