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
<!DOCTYPE html> | |
<html> | |
<head> | |
<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE"> | |
<META HTTP-EQUIV="EXPIRES" CONTENT="0"> | |
<META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE"> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<title>開啟「全民健保行動快易通」App</title> | |
</head> | |
<body> |
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
#!/usr/bin/php | |
<?php | |
$csv = file_get_contents('https://rate.bot.com.tw/xrt/flcsv/0/day'); | |
// Check line by line | |
foreach(preg_split("/((\r?\n)|(\r\n?))/", $csv) as $line) { | |
$values = explode(',', $line); |