{"id":47222,"date":"2020-04-15T23:42:44","date_gmt":"2020-04-15T15:42:44","guid":{"rendered":"https:\/\/www.hongkiat.com\/blog\/?p=47222"},"modified":"2020-04-12T22:38:01","modified_gmt":"2020-04-12T14:38:01","slug":"how-to-upgrade-php","status":"publish","type":"post","link":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/","title":{"rendered":"How to Upgrade PHP to Latest Version"},"content":{"rendered":"<p>PHP7.4 has been released with <a href=\"https:\/\/www.php.net\/manual\/en\/migration73.new-features.php\" target=\"_blank\" rel=\"noopener noreferrer\">a handful of new features<\/a> \u2014 like the arrow function <code>array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo)<\/code>, typed properties and array spread operator <code>['foo', ...$foo, ...$bar];<\/code> \u2014 and that it\u2019s also faster compared to PHP7.3.<\/p>\n<p>So if you\u2019re thinking to update PHP on your machine, take a look at the following post in which I\u2019ll show you how to do so in several ways.<\/p>\n<div class=\"ref-block ref-block--post\" id=\"ref-post-1\">\n\t\t\t\t\t<a href=\"https:\/\/www.hongkiat.com\/blog\/best-php-frameworks\/\" class=\"ref-block__link\" title=\"Read More: 10 PHP Frameworks For Developers \u2013 Best of\" rel=\"bookmark\"><span class=\"screen-reader-text\">10 PHP Frameworks For Developers \u2013 Best of<\/span><\/a>\n<div class=\"ref-block__thumbnail img-thumb img-thumb--jumbo\" data-img='{ \"src\" : \"https:\/\/assets.hongkiat.com\/uploads\/thumbs\/250x160\/best-php-frameworks.jpg\" }'>\n\t\t\t\t\t\t\t<noscript>\n<style>.no-js #ref-block-post-24698 .ref-block__thumbnail { background-image: url(\"https:\/\/assets.hongkiat.com\/uploads\/thumbs\/250x160\/best-php-frameworks.jpg\"); }<\/style>\n<\/noscript>\n\t\t\t\t\t\t<\/div>\n<div class=\"ref-block__summary\">\n<h4 class=\"ref-title\">10 PHP Frameworks For Developers \u2013 Best of<\/h4>\n<p class=\"ref-description\">\n\t\t\t\t\t\tPHP, known as the most popular server-side scripting language in the world, has evolved a lot since the...\t\t\t\t\t\t<span>Read more<\/span><\/p>\n<\/div>\n<\/div>\n<p><strong>Shortcuts to:<\/strong><\/p>\n<ul>\n<li><a href=\"#macos\">Upgrade PHP in macOS<\/a><\/li>\n<li><a href=\"#windows\">Upgrade PHP in Windows<\/a><\/li>\n<li><a href=\"#ubuntu\">Upgrade PHP in Ubuntu<\/a><\/li>\n<li><a href=\"#doctor\">Upgrade PHP in Docker<\/a><\/li>\n<\/ul>\n<h2 id=\"macos\">Upgrading PHP in macOS<\/h2>\n<p>To begin with, you\u2019ll have to check the PHP version that\u2019s currently installed in your system by typing the following command line:<\/p>\n<pre>php -v<\/pre>\n<p>As we can see below, we are currently using PHP 7.3.7 on our macOS.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg\" alt=\"php version macos\" width=\"750\" height=\"480\"><\/figure>\n<p>Arguably the easiest way to install and update PHP on your macOS machine is by using <a href=\"https:\/\/brew.sh\/\" target=\"_blank\" rel=\"noopener noreferrer\">Homebrew<\/a>. Homebrew is a <strong>package manager for macOS<\/strong> though it is now also available in Linux and Windows too. With Homebrew, you can type the following command.<\/p>\n<pre>brew upgrade php<\/pre>\n<p>The process may take a bit long, however, once it\u2019s done you can run the <code>php -v<\/code> command again. You should now see that the version is updated:<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/php-74.jpg\" alt=\"php74\" width=\"740\" height=\"220\"><\/figure>\n<h2 id=\"windows\">Upgrading PHP in Windows<\/h2>\n<p>If you\u2019re using Windows, it\u2019s much easier to run your PHP application on a <strong>pre-packaged localhost environments<\/strong> such as <a href=\"https:\/\/www.wampserver.com\/en\/\" target=\"_blank\" rel=\"noopener noreferrer\">WAMP<\/a> or <a href=\"https:\/\/www.mamp.info\/en\/\" target=\"_blank\" rel=\"noopener noreferrer\">MAMP<\/a>. These applications comes with PHP pre-installed and configured. You will just need to update them to their latest version or install it using the built-in tool to get the latest PHP version.<\/p>\n<p>In addition to that, both <strong>WAMP and MAMP provide an option<\/strong> within the application to switch PHP easily.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/mamp-pro.jpg\" alt=\"php and mamp\" width=\"750\" height=\"480\"><\/figure>\n<h2 id=\"ubuntu\">Upgrading PHP in Ubuntu<\/h2>\n<p>As mentioned previously, you should first check the PHP version that\u2019s in your Ubuntu machine.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/php73-ubuntu.jpg\" alt=\"php and ubuntu\" width=\"750\" height=\"480\"><\/figure>\n<p>As you can see above, currently I have PHP7.3 installed. In Ubuntu, the PHP package can be <strong>installed from the <code>ondrej\/php<\/code> respository<\/strong>. First, run the following command to tap the repository.<\/p>\n<pre>\r\nsudo add-apt-repository ppa:ondrej\/php\r\nsudo apt-get update\r\n<\/pre>\n<p>Then, we can run the following commands which will install PHP7.4, some PHP extensions and packages, and the PHP CLI.<\/p>\n<pre>\r\nsudo apt-get install php7.4 php7.4-common php7.4-cli\r\n<\/pre>\n<p>That\u2019s all. Your Ubuntu machine will successfully be running PHP7.4 and you can confirm by running the <code>php -v<\/code> command again.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/php74-ubuntu.jpg\" alt=\"php ubuntu\" width=\"750\" height=\"480\"><\/figure>\n<h2 id=\"docker\">Upgrading PHP in Docker<\/h2>\n<p>The latest PHP version is also available as an official Docker image. Docker is compatible in several different platforms including macOS, Windows, and Linux so you should be able to follow the same procedure for all these operating systems.<\/p>\n<p>To do so, first I\u2019d like to see if I have the Docker image for PHP7.4 in my machine.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/docker-images.jpg\" alt=\"php docker images\" width=\"750\" height=\"480\"><\/figure>\n<p>It looks like that I don\u2019t have it yet. Let\u2019s type the following command to download the image. This <strong>command will download the Docker image for PHP7.4<\/strong> in the <a href=\"https:\/\/alpinelinux.org\/\" target=\"_blank\" rel=\"noopener noreferrer\">Alpine Linux<\/a> flavour which smaller than the Debian-based image thus also faster to download. You can find the full list of the Docker image available in <a href=\"https:\/\/hub.docker.com\/_\/php\" target=\"_blank\" rel=\"noopener noreferrer\">Docker Hub<\/a>.<\/p>\n<pre>\r\ndocker pull php:7.4-fpm-alpine\r\n<\/pre>\n<p>Once downloaded, we could run it as standalone container with this command below:<\/p>\n<pre>\r\ndocker run --rm -i -t php:7.4-fpm-alpine sh\r\n<\/pre>\n<p>The container should be up and running in a second and immediately creates a Shell session inside the container. If we run the <code>php -v<\/code>, we should be seeing that it is the PHP7.4 within the Docker container.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/docker-run-php74.jpg\" alt=\"php docker run\" width=\"750\" height=\"480\"><\/figure>\n<h2>Wrapping Up<\/h2>\n<p>That\u2019s all how to install and update PHP version to the latest. It\u2019s not as complicated as you\u2019d expected, isn\u2019t it? Finally, PHP core development is progressing at a rapidly with PHP8 aimed for the next release by the end of this year with, of course, some interesting features and improvements. It\u2019s an exciting time to be a PHP developer.<\/p>","protected":false},"excerpt":{"rendered":"<p>PHP7.4 has been released with a handful of new features \u2014 like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties and array spread operator [&#8216;foo&#8217;, &#8230;$foo, &#8230;$bar]; \u2014 and that it\u2019s also faster compared to PHP7.3. So if you\u2019re thinking to update PHP on your machine, take a look at the following&hellip;<\/p>\n","protected":false},"author":113,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[3400],"tags":[511],"topic":[4520],"class_list":["entry-content","is-maxi"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v22.8 (Yoast SEO v27.3) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>How to Upgrade PHP to Latest Version - Hongkiat<\/title>\n<meta name=\"description\" content=\"PHP7.4 has been released with a handful of new features &mdash; like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Upgrade PHP to Latest Version\" \/>\n<meta property=\"og:description\" content=\"PHP7.4 has been released with a handful of new features &mdash; like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/\" \/>\n<meta property=\"og:site_name\" content=\"Hongkiat\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/hongkiatcom\" \/>\n<meta property=\"article:published_time\" content=\"2020-04-15T15:42:44+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg\" \/>\n<meta name=\"author\" content=\"Thoriq Firdaus\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@tfirdaus\" \/>\n<meta name=\"twitter:site\" content=\"@hongkiat\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Thoriq Firdaus\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/\"},\"author\":{\"name\":\"Thoriq Firdaus\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/person\\\/e7948c7a175d211496331e4b6ce55807\"},\"headline\":\"How to Upgrade PHP to Latest Version\",\"datePublished\":\"2020-04-15T15:42:44+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/\"},\"wordCount\":591,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/how-to-upgrade-php\\\/check-php-version.jpg\",\"keywords\":[\"Web Developers\"],\"articleSection\":[\"Hosting\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/\",\"name\":\"How to Upgrade PHP to Latest Version - Hongkiat\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/how-to-upgrade-php\\\/check-php-version.jpg\",\"datePublished\":\"2020-04-15T15:42:44+00:00\",\"description\":\"PHP7.4 has been released with a handful of new features &mdash; like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#primaryimage\",\"url\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/how-to-upgrade-php\\\/check-php-version.jpg\",\"contentUrl\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/how-to-upgrade-php\\\/check-php-version.jpg\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/how-to-upgrade-php\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Upgrade PHP to Latest Version\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/\",\"name\":\"Hongkiat\",\"description\":\"Tech and Design Tips\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#organization\",\"name\":\"Hongkiat.com\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/wp-content\\\/uploads\\\/hkdc-logo-rect-yoast.jpg\",\"contentUrl\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/wp-content\\\/uploads\\\/hkdc-logo-rect-yoast.jpg\",\"width\":1200,\"height\":799,\"caption\":\"Hongkiat.com\"},\"image\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/hongkiatcom\",\"https:\\\/\\\/x.com\\\/hongkiat\",\"https:\\\/\\\/www.pinterest.com\\\/hongkiat\\\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/person\\\/e7948c7a175d211496331e4b6ce55807\",\"name\":\"Thoriq Firdaus\",\"description\":\"Thoriq is a writer for Hongkiat.com with a passion for web design and development. He is the author of Responsive Web Design by Examples, where he covered his best approaches in developing responsive websites quickly with a framework.\",\"sameAs\":[\"https:\\\/\\\/thoriq.com\",\"https:\\\/\\\/x.com\\\/tfirdaus\"],\"jobTitle\":\"Web Developer\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/author\\\/thoriq\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"How to Upgrade PHP to Latest Version - Hongkiat","description":"PHP7.4 has been released with a handful of new features &mdash; like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/","og_locale":"en_US","og_type":"article","og_title":"How to Upgrade PHP to Latest Version","og_description":"PHP7.4 has been released with a handful of new features &mdash; like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties","og_url":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/","og_site_name":"Hongkiat","article_publisher":"https:\/\/www.facebook.com\/hongkiatcom","article_published_time":"2020-04-15T15:42:44+00:00","og_image":[{"url":"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg","type":"","width":"","height":""}],"author":"Thoriq Firdaus","twitter_card":"summary_large_image","twitter_creator":"@tfirdaus","twitter_site":"@hongkiat","twitter_misc":{"Written by":"Thoriq Firdaus","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#article","isPartOf":{"@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/"},"author":{"name":"Thoriq Firdaus","@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/person\/e7948c7a175d211496331e4b6ce55807"},"headline":"How to Upgrade PHP to Latest Version","datePublished":"2020-04-15T15:42:44+00:00","mainEntityOfPage":{"@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/"},"wordCount":591,"commentCount":0,"publisher":{"@id":"https:\/\/www.hongkiat.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#primaryimage"},"thumbnailUrl":"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg","keywords":["Web Developers"],"articleSection":["Hosting"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/","url":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/","name":"How to Upgrade PHP to Latest Version - Hongkiat","isPartOf":{"@id":"https:\/\/www.hongkiat.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#primaryimage"},"image":{"@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#primaryimage"},"thumbnailUrl":"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg","datePublished":"2020-04-15T15:42:44+00:00","description":"PHP7.4 has been released with a handful of new features &mdash; like the arrow function array_map(fn (Foo $foo) =&gt; $foo-&gt;id, $foo), typed properties","breadcrumb":{"@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#primaryimage","url":"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg","contentUrl":"https:\/\/assets.hongkiat.com\/uploads\/how-to-upgrade-php\/check-php-version.jpg"},{"@type":"BreadcrumbList","@id":"https:\/\/www.hongkiat.com\/blog\/how-to-upgrade-php\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.hongkiat.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Upgrade PHP to Latest Version"}]},{"@type":"WebSite","@id":"https:\/\/www.hongkiat.com\/blog\/#website","url":"https:\/\/www.hongkiat.com\/blog\/","name":"Hongkiat","description":"Tech and Design Tips","publisher":{"@id":"https:\/\/www.hongkiat.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.hongkiat.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.hongkiat.com\/blog\/#organization","name":"Hongkiat.com","url":"https:\/\/www.hongkiat.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.hongkiat.com\/blog\/wp-content\/uploads\/hkdc-logo-rect-yoast.jpg","contentUrl":"https:\/\/www.hongkiat.com\/blog\/wp-content\/uploads\/hkdc-logo-rect-yoast.jpg","width":1200,"height":799,"caption":"Hongkiat.com"},"image":{"@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/hongkiatcom","https:\/\/x.com\/hongkiat","https:\/\/www.pinterest.com\/hongkiat\/"]},{"@type":"Person","@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/person\/e7948c7a175d211496331e4b6ce55807","name":"Thoriq Firdaus","description":"Thoriq is a writer for Hongkiat.com with a passion for web design and development. He is the author of Responsive Web Design by Examples, where he covered his best approaches in developing responsive websites quickly with a framework.","sameAs":["https:\/\/thoriq.com","https:\/\/x.com\/tfirdaus"],"jobTitle":"Web Developer","url":"https:\/\/www.hongkiat.com\/blog\/author\/thoriq\/"}]}},"jetpack_featured_media_url":"https:\/\/","jetpack_shortlink":"https:\/\/wp.me\/p4uxU-chE","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts\/47222","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/users\/113"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/comments?post=47222"}],"version-history":[{"count":3,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts\/47222\/revisions"}],"predecessor-version":[{"id":49921,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts\/47222\/revisions\/49921"}],"wp:attachment":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/media?parent=47222"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/categories?post=47222"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/tags?post=47222"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/topic?post=47222"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}