SFSafariViewController内のShareボタンからShare Extensionを起動するとページタイトルが取得できない。
This file contains 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
'use strict'; | |
console.log('Loading function'); | |
const http = require('http'); | |
const https = require('https'); | |
const regexs = [ | |
new RegExp('<meta property=["\']og:title["\'] content=["\']([^>]+)["\']', 'i'), | |
new RegExp('<meta content=["\']([^>]+)["\'] property=["\']og:title["\']', 'i'), | |
new RegExp('<title>([^<]*)</title>', 'i'), | |
]; |
- http://justaway.info/ を Google Chrome で開く
- 適当なところを右クリックして「要素の検証」を選択
- 「Developer Tools」というウィンドウが立ち上がる、「Console」というタブを選択
- 🚫の下の「> 」となっている部分の少し右をクリックし、以下のコードをペーストしEnterキーを叩く(この時画面をよく見ておいて下さい)
$('img').animate({top: '-1000px'})
This file contains 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
package main | |
import( | |
"errors" | |
"fmt" | |
"net/http" | |
) | |
var RedirectAttemptedError = errors.New("redirect") | |
var nopasteClient = func() (*http.Client) { |
This file contains 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
ViewPager viewPager = (ViewPager) findViewById(R.id.X); // XMLに書いたViewPager(スワイプ出来る部分)のidを指定する | |
SectionsPagerAdapter pagerAdapter = new SectionsPagerAdapter(this, viewPager); | |
Bundle args = new Bundle(); | |
args.putSerializable("user", user); // Fragmentに渡す引数、とりあえずコメントアウトでよい | |
args.putSerializable("relationship", relationship); // Fragmentに渡す引数、とりあえずコメントアウトでよい | |
pagerAdapter.addTab(SummaryFragment.class, args); // `SummaryFragment.class`の部分をTweetFragment.classとかFollowerFragment.classとかにする、クラスはinfo.justaway.fragment.profileの下に配置する | |
pagerAdapter.addTab(DescriptionFragment.class, args); // 同上 | |
pagerAdapter.notifyDataSetChanged(); // これを呼ぶとaddTabの結果が反映される |
- 東方×BLACK LAGOON http://www.nicovideo.jp/watch/sm4680033
- 東方外貨取引 http://www.nicovideo.jp/watch/sm9955807
- 商品先物取引会社登録外務員霧雨魔理沙 http://www.nicovideo.jp/watch/nm13233091
- にとりのチルノ商法 http://www.nicovideo.jp/watch/sm6099641
- 東方十代録 http://www.nicovideo.jp/watch/sm8102777
- 博麗の拳 http://www.nicovideo.jp/watch/sm12841437
- DA☆ZEの谷のマリサ http://www.nicovideo.jp/watch/sm9740553
- 東方サスペンス http://www.nicovideo.jp/watch/sm12433674
- 東方GTA ~レミリア様がゆく~ http://www.nicovideo.jp/watch/sm5416201
This file contains 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
# Net::DNS::Paranoid with Furl | |
use Furl; | |
use Net::DNS::Paranoid; | |
use Socket; | |
my $resolver = Net::DNS::Paranoid->new(); | |
my $furl = Furl::HTTP->new( | |
agent => 'MyGreatUA/2.0', | |
timeout => 5, | |
get_address => sub { | |
my ($host, $errmsg) = $resolver->resolve($_[0], time(), $_[2]); |
This file contains 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
- document.styleSheets[0].insertRule(rule); // NG | |
+ document.styleSheets[0].insertRule(rule, document.styleSheets[0].cssRules.length); // OK |