There are several ways to grab file extension (E.g, 'txt' from 'my.txt') using PHP. You can use anyone from flowing. But I prefer to use pathinfo function, because it is PHP's build in function to grab file path information and others are string functions.
1. Using end>explode Function:
1. Using end>explode Function:
$ext = end(explode('.', $filename));
2. Using substr>strrchr Function:
$ext = substr(strrchr($filename, '.'), 1);
3. Using preg_replace Function:
$ext = preg_replace('/^.*\.([^.]+)$/D', '$1', $filename);
Finally pathinfo Function (PHP Build in Function to Grab File Path Information):
$ext = pathinfo($filename, PATHINFO_EXTENSION);
dich vu ke toan thue dich vu lam bao cao tai chinh tín
ReplyDeletekhóa học kế toán thực hành re
cong ty dich vu ke toan
dich vu ke toan tai bac ninh
dịch vụ kế toán trọn gói giá rẻ
dịch vụ kế toán tại tp.hcm
dịch vụ báo cáo thuế
dịch vụ quyết toán thuế uy
học kế toán tại tphcm
học kế toán tại cầu giấy tín
học kế toán tại long biên
học kế toán tại hà đông re
học kế toán tại thanh xuân
học kế toán tại bắc ninh
học kế toán tại bình dương
học kế toán tại hải phòng
dịch vụ thành lập doanh nghiệp công ty trọn gói
dịch vụ thành lập doanh nghiệp trọn gói tại hải phòng
dịch vụ quyết toán thuế tại quận 5
dịch vụ quyết toán thuế tại quận 3
dịch vụ quyết toán thuế tại tphcm
dịch vụ quyết toán thuế tại quận cầu giấy
dịch vụ quyết toán thuế tại quận long biên
dịch vụ quyết toán thuế tại quận hà đông
dịch vụ quyết toán thuế tại quận thanh xuân
I have read your blog its very attractive and impressive. I like it your blog.
ReplyDeletePHP Training in chennai | PHP Training Course
PHP Training in chennai | Online PHP Course
The blog or and best that is extremely useful to keep I can share the ideas of the future as this is really what I was looking for, I am very comfortable and pleased to come here. Thank you very much.
ReplyDeleteanimal jam | five nights at freddy's | hotmail login
Thanks for the information you brought to us. They are very interesting and new. Look forward to reading more useful and new articles from you!
ReplyDeletewings io
Many thanks for sharing this very diverse opinion post where each expert has no doubt shared his best knowledge on the topic. Have more success in your journey.
ReplyDeletehtml color
The information you share is very useful. It is closely related to my work and has helped me grow. Thank you!
ReplyDeletedespacito lyrics
Very good informative article. Thanks for sharing such nice article, keep on up dating such good articles.
ReplyDeleteNO.1 AQM Services | Application Quality Managment Services | Austere Technologies
wow...nice blog, very help full information. Thanks for sharing.
ReplyDeleteBest Digital Transformation Services | DM Services | Austere Technologies
great article.
ReplyDeleteBest Mobility Services | Austere Technologies