{"id":71,"date":"2023-02-16T02:53:22","date_gmt":"2023-02-16T02:53:22","guid":{"rendered":"http:\/\/blog.aryapurwadana.com\/?p=71"},"modified":"2023-02-16T02:53:24","modified_gmt":"2023-02-16T02:53:24","slug":"laravel-8-installation","status":"publish","type":"post","link":"https:\/\/blog.aryapurwadana.com\/index.php\/2023\/02\/16\/laravel-8-installation\/","title":{"rendered":"Laravel 8 &#8211; Installation"},"content":{"rendered":"\n<p>Laravel is a PHP-based web application framework, it provides tools for building powerful and robust applications, it is an open-source framework, which provides a structure that saves a lot of time to build and plan for large applications. It is one of the most secure platforms using a PHP base. It provides built-in features for user authorization like login, registration, and forgot password.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"h-laravel-setup-on-windows-10\"><span id=\"laravel-setup-on-windows\"><strong>Laravel setup on Windows<\/strong><\/span><\/h2>\n\n\n\n<h3 id=\"1-install-composer-on-windows\" class=\"wp-block-heading\">1) <strong>Install composer on Windows:&nbsp;<\/strong><\/h3>\n\n\n\n<p><a rel=\"noreferrer noopener\" href=\"https:\/\/getcomposer.org\/download\/\" target=\"_blank\">https:\/\/getcomposer.org\/download\/<\/a><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-7.png\" alt=\"\" class=\"wp-image-32207\"\/><\/figure>\n\n\n\n<h3 id=\"2-check-the-server-requirement-for-the-setup\" class=\"wp-block-heading\">2) <strong>Check the server requirement for the setup:<\/strong>&nbsp;<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>PHP &gt;= 7.3&nbsp;<\/li>\n\n\n\n<li>BCMath&nbsp;PHP Extension&nbsp;<\/li>\n\n\n\n<li>Ctype&nbsp;PHP Extension&nbsp;<\/li>\n\n\n\n<li>Fileinfo&nbsp;PHP extension&nbsp;<\/li>\n\n\n\n<li>JSON PHP Extension&nbsp;<\/li>\n\n\n\n<li>Mbstring&nbsp;PHP Extension&nbsp;<\/li>\n\n\n\n<li>OpenSSL PHP Extension&nbsp;<\/li>\n\n\n\n<li>PDO PHP Extension&nbsp;<\/li>\n\n\n\n<li>Tokenizer PHP Extension&nbsp;<\/li>\n\n\n\n<li>XML PHP Extension.&nbsp;<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-3.png\" alt=\"\" class=\"wp-image-32203\"\/><\/figure>\n\n\n\n<h3 id=\"3-installing-laravel\" class=\"wp-block-heading\">3) <strong>Installing&nbsp;Laravel:<\/strong><\/h3>\n\n\n\n<p>Type the following command in your command prompt&nbsp;window:\u202f&nbsp;<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>composer global require \u201claravel\/installer\u201d.&nbsp;<\/li>\n\n\n\n<li>composer create-project \u2013prefer-dist&nbsp;laravel\/laravel&nbsp;Project_name: this command will install Laravel and other dependencies with it also generate the ANSI key.&nbsp;<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-6-1024x456.png\" alt=\"\" class=\"wp-image-32206\"\/><\/figure>\n\n\n\n<h3 id=\"4-create-database-for-project\" class=\"wp-block-heading\">4) <strong>Create Database for&nbsp;Project:&nbsp;<\/strong>&nbsp;<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Go to phpMyAdmin click on create a new tab.&nbsp;<\/li>\n\n\n\n<li>Name the database.&nbsp;<\/li>\n\n\n\n<li>Press create button.&nbsp;<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image.png\" alt=\"\" class=\"wp-image-32200\"\/><\/figure>\n\n\n\n<h3 id=\"5-update-env-file\" class=\"wp-block-heading\">5) <strong>Update .Env file:&nbsp;&nbsp;<\/strong>&nbsp;<\/h3>\n\n\n\n<p>APP_NAME=Laravel&nbsp;<\/p>\n\n\n\n<p>APP_ENV=local&nbsp;<\/p>\n\n\n\n<p>APP_KEY=base64:TJ9Sob7KFPhL5XkqT+TyQux3x7UbW08QLb0xtirLWSs=&nbsp;<\/p>\n\n\n\n<p>APP_DEBUG=true&nbsp;<\/p>\n\n\n\n<p>APP_URL=http:\/\/127.0.0.1:8000&nbsp;<\/p>\n\n\n\n<p>LOG_CHANNEL=stack&nbsp;<\/p>\n\n\n\n<p>LOG_LEVEL=debug&nbsp;<\/p>\n\n\n\n<p>DB_CONNECTION=mysql&nbsp;<\/p>\n\n\n\n<p>DB_HOST=127.0.0.1&nbsp;<\/p>\n\n\n\n<p>DB_PORT=3306&nbsp;<\/p>\n\n\n\n<p>DB_DATABASE=first-laravel&nbsp;<\/p>\n\n\n\n<p>DB_USERNAME=root&nbsp;<\/p>\n\n\n\n<p>DB_PASSWORD=&nbsp;<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-4.png\" alt=\"\" class=\"wp-image-32204\"\/><\/figure>\n\n\n\n<h3 id=\"6-migrate-database\" class=\"wp-block-heading\">6) <strong>Migrate database:\u202f<\/strong><\/h3>\n\n\n\n<p>Create tables in the database for&nbsp;Laravel&nbsp;access, also helps in database version control following are the commands for migration.&nbsp;<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>PHP artisan make migration&nbsp;<strong>create_databse_table<\/strong>: this command is used to create the DB migration file in your \u2018database\/migration\u2019 folder.&nbsp;<\/li>\n\n\n\n<li><strong>PHP artisan migrate<\/strong>: used to run the pending migration changes to the database&nbsp;<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-1.png\" alt=\"\" class=\"wp-image-32201\"\/><\/figure>\n\n\n\n<h3 id=\"7-start-development-server\" class=\"wp-block-heading\">7) <strong>Start development server<\/strong>:<\/h3>\n\n\n\n<p><strong>PHP artisan serve<\/strong>: this command starts your development server.&nbsp;<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-2.png\" alt=\"\" class=\"wp-image-32202\"\/><\/figure>\n\n\n\n<h3 id=\"8-go-to-the-ip-url-that-you-see-on-your-cmd-screen\" class=\"wp-block-heading\">8) Go to the IP URL that you see&nbsp;on your&nbsp;CMD&nbsp;screen.&nbsp;<\/h3>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/cynoteck.com\/wp-content\/uploads\/2021\/08\/image-5-1024x554.png\" alt=\"\" class=\"wp-image-32205\"\/><\/figure>\n\n\n\n<p>Following these steps, you will definitely be able to set up the Laravel on your windows system.<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"Laravel is a PHP-based web application framework, it provides tools for building powerful and robust applications, it is&hellip;\n","protected":false},"author":1,"featured_media":53,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"csco_singular_sidebar":"","csco_page_header_type":"","csco_appearance_grid":"","csco_page_load_nextpost":"","csco_post_video_location":[],"csco_post_video_location_hash":"","csco_post_video_url":"","csco_post_video_bg_start_time":0,"csco_post_video_bg_end_time":0,"footnotes":""},"categories":[4,12],"tags":[],"class_list":{"0":"post-71","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-programming","8":"category-web-framework","9":"cs-entry","10":"cs-video-wrap"},"_links":{"self":[{"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/posts\/71","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/comments?post=71"}],"version-history":[{"count":1,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/posts\/71\/revisions"}],"predecessor-version":[{"id":73,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/posts\/71\/revisions\/73"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/media\/53"}],"wp:attachment":[{"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/media?parent=71"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/categories?post=71"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.aryapurwadana.com\/index.php\/wp-json\/wp\/v2\/tags?post=71"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}