Skip to content

Instantly share code, notes, and snippets.

Avatar

Tao Sasaki tao-s

View GitHub Profile
@tao-s
tao-s / sp_menu.js
Created Jun 21, 2019
Sample script for menu
View sp_menu.js
window.addEventListener('load',function(){
$('#spMenuButton').click(function(){
if($('#leftcolumn').hasClass('open')){
$('#leftcolumn').addClass('open');
}else{
$('#leftcolumn').removeClass('open');
}
});
});
@tao-s
tao-s / sp.css
Last active Jun 21, 2019
Base setting
View sp.css
@media screen and (max-width:480px){/* 480pxまではスマホ表示。ここは760pxでも良いと思います */
*{ max-width: 100%; } /* 手抜きのおまじない */
html,body{
width: 100vw; /* bodyの横幅を画面横幅に指定 */
max-width: 100vw; /* bodyの最大横幅も画面横幅に指定 */
overflow-x: hidden; /* 横にはみ出す部分を非表示に設定 */
font-size: 4vw ; /* お好みで基本文字サイズを設定 */
}
#header,
#container,
@tao-s
tao-s / site_frame.tpl
Created Jun 20, 2019
Link tag for smart phone
View site_frame.tpl
<!--{printXMLDeclaration}--><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--{*
* This file is part of EC-CUBE
*
* Copyright(c) 2000-2010 LOCKON CO.,LTD. All Rights Reserved.
*
* http://www.lockon.co.jp/
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@tao-s
tao-s / .env
Last active Mar 15, 2019
EC-CUBE4でURLの/user_dataを変える ref: https://qiita.com/tao_s/items/2d951ea2d087fcc525d0
View .env
#ECCUBE_USER_DATA_ROUTE=user_data
@tao-s
tao-s / .env
Last active Dec 6, 2018
EC-CUBE4を日本語以外で使う ref: https://qiita.com/tao_s/items/4a4d658a40ce1340eee6
View .env
ECCUBE_LOCALE=en #言語設定
ECCUBE_TIMEZONE=Asia/Tokyo #タイムゾーン
ECCUBE_CURRENCY=USD #利用する通貨
@tao-s
tao-s / TR_websub.md
Last active Jun 23, 2017
W3CにあるWebSubのTRの日本語版
View TR_websub.md
@tao-s
tao-s / get_updated_stack_pages.php
Last active Mar 24, 2016
concrete5 5.7系で、更新されたスタックとグローバルエリアが利用されているページのcID一覧を取得するJobのサンプルコード
View get_updated_stack_pages.php
<?php
namespace Application\Job;
use Concrete\Core\Cache\Cache;
use Config;
use Job as AbstractJob;
use Core;
use Database;
use PermissionKey;
@tao-s
tao-s / app.php
Created Feb 24, 2016
concrete5 5.7系でファイル一覧を吐くだけのURLを作る
View app.php
<?php
//application/bootstrap/app.php
/**
* ----------------------------------------------------------------------------
* # Custom Application Handler
*
* You can do a lot of things in this file.
*
* ## Set a theme by route:
*
@tao-s
tao-s / file0.txt
Created Feb 24, 2016
concrete5にPSR-4 autoloader形式でコード追加した時に、追加したclassが見つかりませんエラーで毎度ハマるのでメモ ref: http://qiita.com/tao_s/items/1e83fea9116cc8f41c78
View file0.txt
application
-controllers
--controller.php
@tao-s
tao-s / get_file_data.php
Last active Feb 12, 2016
Fileの一覧吐く
View get_file_data.php
<?php defined('C5_EXECUTE') or die("Access Denied.");
namespace Application\Controller;
use Concrete\Core\File\FileList;
class GetFileDataContoroller {
public function index(){
$fl = new FileList();
You can’t perform that action at this time.