{"id":22151176,"url":"https://github.com/leta91/how-to-run-php-in-vs-code-2022","last_synced_at":"2025-03-24T13:21:16.467Z","repository":{"id":161022527,"uuid":"552242637","full_name":"leta91/how-to-run-PHP-in-VS-Code-2022","owner":"leta91","description":"How to run PHP on Visual Studio Code 2022 using WAMP software","archived":false,"fork":false,"pushed_at":"2022-10-16T06:11:45.000Z","size":2,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-29T18:23:15.822Z","etag":null,"topics":["beginner-friendly","bugs","fixed","how-to","howto","howto-tutorial","installation","installation-notes","php","php-framework","php7","php8","visualstudiocode","vscode","wamp","wamp-server","wampserver"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leta91.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-10-16T06:09:38.000Z","updated_at":"2022-10-16T06:14:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"abff7d88-6505-45f3-ba1a-ec566efc0937","html_url":"https://github.com/leta91/how-to-run-PHP-in-VS-Code-2022","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leta91%2Fhow-to-run-PHP-in-VS-Code-2022","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leta91%2Fhow-to-run-PHP-in-VS-Code-2022/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leta91%2Fhow-to-run-PHP-in-VS-Code-2022/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leta91%2Fhow-to-run-PHP-in-VS-Code-2022/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leta91","download_url":"https://codeload.github.com/leta91/how-to-run-PHP-in-VS-Code-2022/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245276093,"owners_count":20588895,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["beginner-friendly","bugs","fixed","how-to","howto","howto-tutorial","installation","installation-notes","php","php-framework","php7","php8","visualstudiocode","vscode","wamp","wamp-server","wampserver"],"created_at":"2024-12-02T00:31:11.140Z","updated_at":"2025-03-24T13:21:16.446Z","avatar_url":"https://github.com/leta91.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# How to run 🐘PHP on Visual Studio Code 2022 and how to fix some related bugs 🐛:\n\nYou need 3 things to run PHP on your local machine:\n1. PHP\n2. a web server\n3. a database\n\nThe software that offers all 3 and that I found to be the best choice is **WAMP** 🥇\n\nOpen WAMP \n    🔽\ngo to *C:\\wamp64\\www\\newfolder*\n    🔽\n:file_folder: *newfolder* is the folder's name I created within the *www* folder (it's important to keep all PHP files inside the *www* folder in order for them to be opened)\n    🔽\nselect *newfolder*'s path and type `cmd` and click *Enter*\n    🔽\nwithin Command Prompt type `code .` \nthis will set VS Code as the default text editor to open this specific folder with a PHP file\n    🔽\nto access this file, type in the browser *localhost* that will show the homepage of all the folders within the *www* folder of WAMP, select the one that says *newfolder* ▶️ *indexb.php* \n*indexb.php* will show the output of the PHP code that in this case corresponds to the word **Greetings**\n\nAbout bugs 🐛 here are the solutions to the error messages that you might get on WAMP\nwhen you left-click on your 🖱️ on the small WAMP icon that is located on the right side of the taskbar \n\n- #### default text editor does not exist\nwithin the folder *wamp64* open with normal notepad the file named *wampmanager.conf* and swap the previous text editor .exe to VS Code. Type on your computer the **Windows key + R** and type *%appdata%\\..\\Local\\Programs\\Microsoft VS Code*\n\nAdd right after `editor =` in *wampmanager.conf* the path to VS Code that needs to have a similar syntax to the following `C:\\..\\..\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe\"`\n\n- #### default log viewer does not exist \ncopy and paste the same .exe path after it says `logviewer =`\n\n- #### warning C:\\wamp64 or PHP in PATH\nin Windows search bar type *environment variables* and click on *edit* when you see on *Path* `C:\\wamp64\\bin\\php\\php7.4.26` or something similar delete it and click ok. then right-click on 🖱️ and select *exit* on WAMP small icon. When you will re-open WAMP all 3 bugs will be fixed ✅\n\n\n\n    \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleta91%2Fhow-to-run-php-in-vs-code-2022","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleta91%2Fhow-to-run-php-in-vs-code-2022","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleta91%2Fhow-to-run-php-in-vs-code-2022/lists"}