Last active
August 4, 2016 17:42
-
-
Save hogashi/edd7377534e32a7103f11a29532aa55b to your computer and use it in GitHub Desktop.
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
<?php | |
$word = '+' . $_GET['query']; | |
$page = shell_exec ( 'curl -o- http://ejje.weblio.jp/small/content/' . urlencode($word) . ' | tr "\n" "\000" | sed "s/<\/\(\|no\)script>/\n/g" | sed "s/<\(\|no\)script.*$//" | sed "s/<meta[^>]*>//" | sed "s/\"http\:\/\/ejje\.weblio\.jp\/small\/content\/\([^\"]*\)\"/\"\.\/ws\.php\?query=\1\"/g" | sed "s/\"http\:\/\/ejje\.weblio\.jp[^\"]*\"/\"\.\/ws\.php\"/g" | tr "\000" "\n"' ); | |
print $page; | |
print "It works.<br>"; # 動作確認用文字列 | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment