Skip to content

Instantly share code, notes, and snippets.

View laddy's full-sized avatar

Yuya Tanaka laddy

View GitHub Profile
@laddy
laddy / sha.php
Created March 14, 2018 01:46
PHP SHA256 Test
<?php
$now = microtime();
echo $now . "\n";
for ( $i = 0; $i < 1024; $i++ )
{
$now = hash('sha256', $now );
}
echo $now . "\n"
@laddy
laddy / poll.js
Created August 18, 2017 06:32
例のアレ
function goPoll(mode, no) {
j.ajax({
type: "POST",
url: "ajax/goPoll.nc",
data: "selectNo=" + no + "&mode=" + mode,
success: function(data) {
var jsonData = eval('(' + data + ')');
if (jsonData.isSysError) {
// alert(jsonData.sysErrorDesc);
return;
@laddy
laddy / sample2.html
Created February 11, 2017 09:04
VueJS List Add
<html>
<body>
<!-- VUE CONTROL AREA 2 -->
<div id="vue-control-area2">
<h1>Get Weater Api</h1>
<button v-on:click="get_list()">Get List</button>
<ul>
<li v-for="l in list">Name: {{l.name}} | Status : {{l.status}}</li>
</ul>
</div>
@laddy
laddy / sample.html
Last active February 11, 2017 09:03
VueJS Sample1
<html>
<body>
<!-- VUE CONTROL AREA 1 -->
<div id="vue-control-area1">
<h1>{{ title }}</h1>
<input type="text" v-model="message">
<p>{{ message }}</p>
<button v-on:click="push_this('Pushed Button!!')">Push This!!</button>
</div>
@laddy
laddy / file0.txt
Created May 4, 2016 17:35
VirtualBoxをアップデートしたらHost-Only Ethernet AdapterのエラーでVagrantが起動しない ref: http://qiita.com/laddy/items/4ed70336f6f3f815b215
$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
default: Adapter 1: nat
default: Adapter 2: hostonly
==> default: Forwarding ports...
default: 80 => 8080 (adapter 1)
default: 22 => 2222 (adapter 1)
There was an error while executing `VBoxManage`, a CLI used by Vagrant
@laddy
laddy / file0.txt
Last active December 31, 2019 04:50
悪用厳禁 nmapでポートスキャン ref: https://qiita.com/laddy/items/8e4d151b60407bcd4c3b
$ nmap www.hogehoge.co.jp
Starting Nmap 6.47 ( http://nmap.org ) at 2015-04-23 17:46 JST
Nmap scan report for www.hogehoge.co.jp (xxx.xxx.xxx.xxx)
Host is up (0.030s latency).
Not shown: 998 filtered ports
PORT STATE SERVICE
80/tcp open http
2222/tcp open EtherNet/IP-1
@laddy
laddy / file0.txt
Created September 17, 2015 07:54
eラーニング構築ツールMoodleをUbuntuにインストールする ref: http://qiita.com/laddy/items/a174a5089cac8229dc16
$ sudo apt-get update
$ sudo apt-get upgrade
- alpha
- bravo
- charlie
解釈→ ['alpha', 'bravo', 'charlie']
@laddy
laddy / cal.php
Created May 7, 2015 08:11
PHPでカレンダー表示
<?php
system('cal');