分類
好用軟體

我的足跡要停止服務了

又一個超棒的 APP/服務被 Google 結束了, 我的足跡. 官方說明:
https://support.google.com/gmm/answer/6333516

APP 已從 Play 商店上下架了: https://play.google.com/store/apps/details?id=com.google.android.maps.mytracks

之前登山時, 開啟要使用記錄時, 就看到了即將於 4/30停止服務的訊息, 不過還真不知有什麼好替代的軟體與服務, 官方的建議有以下幾項:

看起來都沒有原來的方便輕薄好用, 真是可惜了一個超棒的服務.

繼續閱讀:
http://beebom.com/2016/01/google-my-tracks-alternative

[2016/04/29 15:46]

目前使用 GeoTracker: https://play.google.com/store/apps/details?id=com.ilyabogdanovich.geotracker 還蠻不錯的, 大家可以參考看看.

分類
系統技術

免費好用的SSL-Letsencrypt

看到在 DigitalOcean 上的教學文章 – 如何在 ubuntu 的 apache 上加裝 SSL

https://www.digitalocean.com/community/tutorials/how-to-secure-apache-with-let-s-encrypt-on-ubuntu-14-04

於是來研究看 Letsencrypt 的 SSL 安裝.

步驟真的還蠻簡單的, 開了一台 CentOS 主機後, 先安裝了 apache:

yum install httpd

再安裝 git:

yum install git

然後便正式安裝 letsencrypt 作業:

git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt
./letsencrypt-auto

其實這樣就裝完了, 過程中會問幾個問題, 主要是網域名稱與 renew 用的 email , 輸入完成後, 便會自動進行 SSL 憑證的安裝, 其中還有一個問題是是否強制使用 https, 可以依自己的需求來進行選擇, 安裝好後, 就可以直接訪問 https://yourdomain.com 看看是否正常, 原則上 apache 不用重起就可以使用了呢.

這個憑證免費, 不過效期只有 90 天, 官方建議是每 60天 renew 一次, 所以記得要定期更新, 或使用 cron 自動來更新.

繼續閱讀:

  1. https://community.letsencrypt.org/t/quick-start-guide/1631
  2. 使用第三方 sslforfree 來手動申請 ssl: https://free.com.tw/ssl-for-free/
  3. https://blog.longwin.com.tw/2015/11/let-encrypt-ssl-certificate-setup-2015/
分類
PHP

PHP好用線上測試功能

這個線上的沙箱測試, 可以讓你在不同的 PHP 版本間進行 PHP程式的測試, 有時候需要一小段程式來測試與驗證時, 可以利用這樣的工具來達成, 網址:

http://sandbox.onlinephpfunctions.com/

不僅可以測試 php 程式碼, 還可以進行儲存與分享, 是在 php 程式開發時, 可以快速撰寫小程式的好用工具, 很方便快速, 請多多利用.

例如以 php 網站上的一個 callback function範例:

// Our closure
$double = function($a) {
    return $a * 2;
};

// This is our range of numbers
$numbers = range(1, 5);

// Use the closure as a callback here to
// double the size of each element in our
// range
$new_numbers = array_map($double, $numbers);

print implode(' ', $new_numbers);

放在該網站執行並存檔分享連結為:

http://sandbox.onlinephpfunctions.com/code/c9a175417fddfc1ed0aef4a48feb5de384c49e3d

真的又快又方便!