• About

Viet PHP

PHP = ['newbie' => 'cơ bản', 'coder' => 'nâng cao', 'professional'=>'chuyên sâu']

  • PHP
    • OOP
    • Basic
  • WordPress
  • Bài tập PHP
  • PHP 7

Các tính năng bị loại bỏ (deprecated) từ PHP5 lên PHP7

Posted on April 15, 2018 Written by admin Leave a Comment

Gone (or Deprecated)

  • Assigning the Result of new by Reference
  • Static Calls of Instance Methods
  • Accessing Raw POST Data
  • Hash-Sign Comments in ini Files
  • Server APIs (SAPIs)
  • ASP Tags
  • Extensions
  • Magic Quotes
  • Dynamic Extension Loading in PHP-FPM
  • call_user_method()
  • preg_replace() /e modifier
  • Support for Old Versions of Windows
  • Support for NetWare
  • PHP 4-Style Constructors
  • Eval Option for mb_ereg_replace() Deprecated
  • mbstring.func_overload Directive
  • sql.safe_mode Directive
  • track_errors Directive
  • __autoload()
  • create_function()
  • assert() with String Argument
  • (unset) Cast
  • each()
  • parse_str() without Result Argument
  • png2wbmp() and jpegwbmp()

Nguồn: https://php7explained.com/content.html#gallery

Có lẽ cần tham khảo thêm: http://php.net/manual/en/migration70.php

Filed Under: PHP

Bài tập Array [4]

Posted on April 14, 2018 Written by admin Leave a Comment

Bài toán sau nói về việc sử dụng hàm count() với số.

Hàm này vốn chỉ để đếm thành viên trong array hay object. Giờ đếm số thì sao?

Định nghĩa của PHP thần thánh.

count — Count all elements in an array, or something in an object

Hàm count() vốn chỉ đếm array hay object, nhưng nếu nó đếm số thì kết quả sẽ trả về 1. Thật buồn cười :-).

[Read more…]

Filed Under: Bài tập PHP, Basic, PHP

Chuyển đổi cơ số từ hệ nhị phân (Binary) 16 (Hex) và 8 (octal) sang 10 (decimal)

Posted on April 14, 2018 Written by admin Leave a Comment

Hệ số đếm quen thuộc vẫn là hệ số 10. Nhưng máy tính lại dùng hệ nhị nhân để xử lý. Ta còn có cơ số 8 (octal) và cơ số 16 (hex)

Để chuyển đổi cơ số nhị phân (binary), 8 (octal) và 16 (Hex – hexadecimal) sang cơ số 10 (decimal), đầu tiên ta xem các hệ số giống khác nhau như thế nào qua bảng sau. Tiếp đến ta sẽ tìm cách chuyển đồi các cơ số dạng nhị phân, bát phân và thập bát phân sang hệ thập phân.

[Read more…]

Filed Under: Basic, PHP

Chữ hoa lớn hơn chữ thường- PHP string

Posted on April 13, 2018 Written by admin Leave a Comment

Chữ hoa lớn hơn chữ thường.

$a = 'abc';
$b = 'ABC';

if($a>$b){

    echo "Số hoa lớn hơn số thường";
}else{

    echo "như nhau";
}

Kết quả "Số hoa lớn hơn số thường", Vãi thật.

Filed Under: Basic, PHP

  • « Previous Page
  • 1
  • 2
  • 3
  • 4
  • Next Page »

Recent Posts

  • How to pass a variable to the callback function provided by Laravel Collection
  • Cài Sodium trên PHP 7.2 Centos
  • Dependency Injection và Container
  • Hàm array_map() và array_walk()
  • Dependency Injection

Recent Comments

  • admin on Dependency Injection
  • Vượng on Dependency Injection
  • vượng on Dependency Injection
  • vượng on Dependency Injection
  • vượng on Dependency Injection

Archives

  • July 2018
  • June 2018
  • May 2018
  • April 2018

Categories

  • Bài tập PHP
  • Basic
  • Laravel
  • OOP
  • OOP
  • PHP
  • String
  • Uncategorized
  • WordPress

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org

Copyright © 2021 · Focus Pro on Genesis Framework · WordPress · Log in