PHPでtry~catch文
2014/07/02
PHPでもあるってのを知らなかったのでメモ。
■参考サイト
http://www.php-ref.com/basic/06_try_catch.html
<?
try {
//例外処理
} catch (Exception $e) {
echo $e->getMessage();
}
?>
関連記事
-
-
GoogleスプレッドシートとPHPを連携させデータを取得・追記する方法
GoogleスプレッドシートとPHPプログラムを連携させたいという案件をたまに見 ...
-
-
eval関数について
ちょくちょく見ることがあったeval関数について、 なんとなく分かってきたのでメ ...
-
-
PHPで「Unable to allocate~」とエラー
PHPで「Unable to allocate memory for pool」 ...
-
-
FPDIで「This PDF document probably uses~~」エラーの対処方法
FPIDであるPDFを読み込ませようとすると「This PDF document ...
-
-
PHP8系で「Warning: Attempt to read property "xxxxxx" 」エラーの対応方法
PHP8系&WordPress6.4.3で「Warning: Attem ...