This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once 'Services/Amazon.php'; | |
// Product Advertising APIのアカウントを作成し、 | |
// https://aws-portal.amazon.com/gp/aws/developer/account/index.html?action=access-key | |
// からアクセスキーなどの情報をコピーしてきます。 | |
$access_key = ''; // 上記URLのアクセスキーID | |
$access_key_secret = ''; // 上記URLのシークレットアクセスキー |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var url = 'chrome-extension://eemcgdkfndhakfknompkggombfjjjeno/main.html'; | |
var url_pattern = new RegExp('^' + url); | |
chrome.tabs.getAllInWindow(null, function(tabs){ | |
for (var i = 0, len = tabs.length; i < len; i++) { | |
var tab = tabs[i]; | |
if (url_pattern.test(tab.url)) { | |
chrome.tabs.update(tab.id, { selected: true }); | |
return; | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// トリガーのイベントを「From spreadsheet」の「On form submit」にして下さい | |
function onFormSubmit(e) { | |
var recipient = ''; // 送信先メールアドレス | |
var subject = 'お問い合わせ'; | |
var field_names = ['氏名', 'メールアドレス', '件名', '本文']; | |
// メールで送りたい内容のフィールド名 | |
var body = 'お問い合わせがありました。\n\n'; | |
for (var i = 0, len = field_names.length, name; i < len; i++) { | |
name = field_names[i]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Imports System.Drawing.Imaging | |
Imports System.Runtime.InteropServices | |
Partial Public Class ImageProcessing | |
''' <summary> | |
''' Bitmapからグレースケール化されたBitmapを生成します。 | |
''' </summary> | |
''' <param name="image">Bitmap</param> | |
''' <returns>グレースケール化されたBitmap</returns> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"> | |
<CodeSnippet Format="1.0.0"> | |
<Header> | |
<Title>prop2</Title> | |
<Shortcut>prop2</Shortcut> | |
<Description>プロパティとバッキング フィールドに対するコード スニペット (C# 2.0)</Description> | |
<Author>nissuk</Author> | |
<SnippetTypes> | |
<SnippetType>Expansion</SnippetType> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- ユーザーを追加するストアドプロシージャを定義します。 | |
-- 氏名と性別名('male', 'female')を入力し、 | |
-- プロシージャ内部で性別名から性別idを引き出して追加します。 | |
DROP PROCEDURE IF EXISTS insert_user; | |
DELIMITER $$ | |
CREATE PROCEDURE insert_user(IN name TEXT, IN gender_name TEXT) | |
COMMENT "ユーザーを追加します。" | |
BEGIN | |
-- カーソルの値を受け取る変数とカーソルを定義します。 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once 'qdmail.php'; | |
$to = array('[email protected]', 'to san'); | |
$from = array('[email protected]', 'from san'); | |
$reply_to = array('[email protected]', 'reply san'); | |
$subject = 'subject'; | |
$message = 'message'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- プリペアドステートメントを定義します。 | |
PREPARE s FROM 'SELECT * FROM users WHERE id = ?'; | |
-- プリペアドステートメントを実行します。 | |
-- (実行の構文が | |
-- EXECUTE stmt_name [USING @var_name [, @var_name] ...] | |
-- となっているのでリテラルは使えません) | |
SET @id = 1; | |
EXECUTE s USING @id; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Text; | |
// 使用する前に nunit.framework を参照設定に入れて下さい。 | |
using NUnit.Framework; | |
namespace ExampleAppTest | |
{ | |
[TestFixture] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# C:\Windows\System32\drivers\etc | |
# ServerName で指定したドメイン名を127.0.0.1に向けます。 | |
127.0.0.1 dev.localhost |