标签:throw get lov try size love try catch exce style
?
<?php
?
try {
if (file_exists(‘test_try_catch.php‘)) {
require (‘test_try_catch.php‘);
} else {
throw new Exception(‘file is not exists‘);
}
} catch (Exception $e) {
echo $e->getMessage();
}
?
?
?
具体使用场景:
?
?
文章来源:外星人来地球
欢迎关注,有问题一起学习欢迎留言、评论
标签:throw get lov try size love try catch exce style
原文地址:https://www.cnblogs.com/lovebing/p/11505553.html