當使用 preg_replace 作關鍵字批次 pattern 替換時, 要小心避免關鍵字巢狀替換的問題, 要先替換成獨一無二的代碼,再從代碼替換回來。另外在使用 preg_replace 作字串比對替換時,若 DB 為 BIG5 編碼,也要小心雙位元字碼交錯, 所造成的比對錯誤問題,這裡在處理時要特別小心,免得一失足成千古恨...
GET urlencode(), encodeURIComponent(), form hidden & 注意與 js 串接 (form.action, location.href, location.replace) 變數隱私問題 id -> token 關係到個資或敏感資訊的API,程式中最好隱藏這類的參數傳遞 不管是用 get 或 post,一定要讓傳遞的參數使用一組獨一無二的亂碼 QueryString, KeepBack, Pager, Sorter, Searcher POST name[] vs name[0] <input name="name[]" /> 有可能會產生兩種可能,1組時是變數,1組以上是陣列 改用 name[0] 明確的數值鍵,可以強迫接到時都是陣列。 <input name="name[0]" /> <input name="name[1]" /> SSL 串接限制 PostBack, FormToken, FormAuth
樂倍達數位科技 版權所有 Copyright © 2004-2011 DoubleService Digital Technology. All Rights Reserved.