This extension is a great addition to the Visual Studio product. It allows us to integrate PHP programming in the classroom using Visual Studio, providing the debug support that we are use to with other languages such as C++ and C#. In addition, this product provides a much easier path for getting PHP setup and working using the local machine.
We're very sorry for this experience. Most likely this would be result of unexpected interaction with another extension. While we test with most frequent VS extensions, it's hard to test all of them. If we'd know more details about the exception we'd fix this immediately. Or if the issue is present in another extension we could contact the other vendor. If you'd like to try the extension again, please contact us at firstname.lastname@example.org we will be very happy to assist.
I would like to use this but doesn't seem compatible with Uniserver. The php.ini file has macros in it for file paths, and this extension just keeps complaining it can't find the php.ini file. I tried copying the one uniserver eventually uses based on its configuration, from php_production.ini to php.ini, but after getting it to work, now this extension says it can't find mysqli, which is built into the configuration (again) of uniserver. I have no issue using Eclipse, I'm not sure why this extension insists on validating my php setup before running.
Thanks for your feedback. We do this only for "Controlled environments" as IIExprees, but if you want to use different server, just select Use Custom Server in project properties ( right click on project node in Solution Explorer, select Properties) and fill URL of the project. No configuration will be checked and we won't care about php.ini.
Please let us know if that solved the issue you've been having. You can just ping us on email@example.com or on http://support.devsense.com
This addon is relly best! The best choice for developing in PHP! Thanks a Visual Studio and really AWESOME integrating a AutoComplete and others (and mainly thanks with support of PHP Docs feature), the OOP MVC framework is really easy to work, improve etc.! Absolutly love it!
To future some ideas: - Custom PHP server, for support a Mod Rewrite too (so apache) - When again debug a website (for sample in Chrome), it will not open a new tab but just refresh a tab what exists (like as in Apache Cordova) - Add support for Database Servers and his explorer (for sample PHPmyADMIN).
Some bugs: Autocomplete and other stuffs dont show a functions of extended class (so when is "user extends dbObject", its not shows function from dbObject class)
That would be nice to see in future updates! Thank you for good job and im glad for this is work of Czech people!
-- Editing php Files Problems to detect the correct language in mixed mode. Many php scripts use a mix from php, html, js and css. It seems that PHP Tools have problems to detect what language is used in current segment -> Wrong (or none) syntax highlighting.
-- Speed It's slow. Project analyse need 10-20 minutes for bigger projects (in my case a Joomla CMS) - In PDT same job needs 30s
-- Stability Bigger projects will kill VS. Sometimes the UI is unresponsive for 30s. I need to disable big parts of code to work without crashes -> IntelliSense will not longer work
-- Price Price is too high for a Plugin. phpStorm is same price, PDT is free and works better
-- Free version I download the test version but after the trial period it's impossible to jump to declarations what makes it complete useless in free mode
-- Summary I really want to like PHP Tools, but in it's current state it's impossible to work with it (slow, unresponsive, crashes...). Price is too high for a product that's not ready for productive work
I'll give PHP Tools another try after some versions - Hope Devsense can fix the problems :-)
Thank you for your review and feedback! I'm sorry we didn't fulfill the expectations at this time.
- Editing mixed code php files May I ask you what version of Visual Studio and PHP Tools are you using ? Since VS2015 we are using new Visual Studio HTML editor which is very different from previous VS versions. If there are some pieces of mixed code which are not handled as expected, please send them to us.
- Speed and stability Joomla is one of the regularly tested frameworks and it should take few sec to analyze as expected. I’ve just smoked tested it and it took ~15 sec on 7 years old laptop.
I’m thinking there might be some specific piece of code which we have an issue with. E.g. we had an issue in older version of PHP Tools to analyze one php function which had ~3000 lines of code and >200 local variables in one of the joomla plugin
Or the project is located on network share, which is unfortunately known issue as we have to go through all the project files.
If you could please contact us at firstname.lastname@example.org or you can contact me directly at email@example.com we would handle these issues with top priority.
Can you make it cheaper? I understand is a lot of work, but to be honest with you, people will always search for a pirated version, instead to buy it. Is 80 bucks. Which is quite substantial for a personal license, while phpstorm costs 150 and is much more complete tool, or eclipse PDT which is free.
After years of using Dreamweaver for PHP development and mastering the language, I finally became fed up with Adobe’s crap software and fees.
Recently having gotten acquainted with Visual Studio for C++ coding, I found myself longing to code PHP in a Visual-Studio-like environment. This extension made that possible for me and it offers all kinds of hints that Adobe will never add to their software because they have become a total crap company. Dreamweaver has gotten so bogged down in useless crap that real programmers don't need, but can't even line up FIXED WIDTH fonts in the code editor properly.
[Part 2 -- silly 9-tweet limit!] 5. The syntax highlighting and checking is slightly broken in a .hmtl file -- the closing angle bracket in a <?PHP ... ?> escape looks to your parser like a closing tag for some previous tag. 6. I get bogus warnings about not being allowed to use <input> or <select> in a <table> row. Of course you can. 7. After a fresh install on Win 10 with VS 2015 Community, the debug menu command were disabled. I thought I got prompted on my other (not Community) installation to install IIS. 8. All in all, this extension is not quite ready for prime time. I think it would wise for DEVSENSE to offer it for a loss-leading price to encourage the community to find bugs and suggest enhancements.
Thanks for taking the time to write use the detailed feedback.
Most of the stuff you've mentioned is related to HTML editor we reuse from Visual Studio( you can submit these bugs directly to Microsoft through Connect, or we'll do it ourselves when we have explicable test case ). If you could send us some sample case for 5 and 6, we would do contact the MS and make sure it would get done.
Validation of HTML tags is very complex process (built in Visual Studio, not PHP Tools) taking into account current HTML scheme. Of course we have detailed feedbacks and feature requests we've been collecting for years, and we are happy for more.
If you would like to get rid of VS HTML Editor issues, just turn it off in Tools | Options | PHP Tools | Advanced). Our HTML editor will be used.
Thanks again for the feedback, if you'd have any other question/issue or you'd need an assistance with anything just ping us on firstname.lastname@example.org or http://support.devsense.com. We'll be very happy to help.
I develop with Symfony, and I really miss a few things with PHP Tools: - Twig template support - With Symfony it's a must, but it's missing from PHP Tools - Invoke app/console for me to generate resource files or controllers - Auto-adding of new files - My project is shared among a group of people, most of them use other IDEs, and if they add new files, they have to be added manually to my project - "File Structure" tab is not supported - "Code Definition Window" is not supported - Sometimes files are saved with UTF-16 instead of UTF-8
I like PHP Tools, because it makes development with PHP possible in a familiar environment, but unfortunatelly it stops there. It's great to have a tool to edit simpler PHP projects, but the minimal support for any well-known PHP framework is missing. So as long as you edit your own website with only a few files or your WordPress PHP template, it does the job.
Hi John, Thank you for your review and list of features you are missing. We do prioritize our development list strictly based on feedback.
- Twig template support is currently in progress - Invoking commands,generating controllers, etc... will be supported in REPL window, which is planned - Auto-adding of new files. We are aware of this limitation and we are trying to figure this out, but it's going to be a longer run... It's kind of inherited behavior coming from how Visual Studio works with projects and need for project file. - File structure tab. We do not have dedicated window for this, but this information is available e.g. in navigation bar. - "Code Definition Window", The true is we didn't even know about this one. I've added it to the list. But there are currently alternatives as F12 or Alt +F12 (VS2013,VS2015) - We do not interact with encoding settings, but we do have an option to force saving as UTF8 without BOM on each file. Tools | Options | Text Editor | PHP | Advanced | Override PHP Files Encoding
Please let us know if you'd have any other feedback.
I am using in trial version, everything is alright but suggesting already defined variable automatically (like when pressing ctrl+space) seems restricted for trial version. Every basic source editor like notepad++, sublime suggests words that are already found in the current file. It should have been enabled and restricting other things like suggesting php inbuilt functions etc. Also it should have been made clear that it can be used in trial mode and try full feature and then can be used even after trial period finished. Official website seems vague about it and gives us the feeling like we have to explicitly buy it after using trial period. And avoid even to download and try out because of that. All in all, very good job guys, keep it up. Just make clear in website, it can be used in trial mode as long as we want and try out pro feature. That will bring hesitating users.
I use PHP Tools on daily basis, so I feel like I should also post a review (I do work at DEVSENSE). I really like how IntelliSense helps me to stay productive when I switch to PHP, as I usually code in C#. The switch between languages is less noticeable for me with each update of PHP Tools.
With the code assistance I do not need to look at PHP documentation almost at all. I do really like refactoring capabilities and ability to debug the code.
I love how I can use PHP Tools with the other great extensions as Web Essentials, Task Runner Explorer, etc.
I want to thank to the rest of the team for great work!
Hello, i just started looking your extension. Pretty far i get tha feeling that everything is as i want to make this my main php editor. BUT what about debugging php projects that require a POST Http method? i searched through your tutorial but there is no option to configure VS to make a POST method with user-specific params...
Thanks in advance.
When I start up debugger (using F10) I get an error...
The requested resource /?XDEBUG_SESSION_START=F7C6016 was not found on this server.
Any idea? Recently added license, everything worked fine until trial ran out. Just downloaded and installed newest version, 1.17.8075.2013.
Thanks for your post! This seems like a server settings more than debugger issue. IF you simply run your project without debugging (Ctrl + F5) do you see the expected page?
If not, it would be the server settings. Let's solve the issue through email, as I can see you've submitted the feedback earlier.
I am considering replacing Eclipse PHP with this. However, my only downfall that I have found is I am not able to auto-format the code like I can with Eclipse. With Eclipse, i press CRTL + Shift + F. I have found CTRL + K + F or D should work, but not with PHP.
Am I missing something or is it not available?
Code formatting is supported by PHP Tools. The standard shortcuts are Ctrl+F,D and Ctrl+K,F (see Edit|Advanced|Format .. for your actual shortcuts).
The code is also formatted when you paste a text, type a semicolon or a closing bracket. If some of these functions do not work as expected, please contact us directly from VS in Help|PHP Tools Feedback (http://docs.devsense.com/troubleshooting/feedback)
Is it possible to set a custom web root? I have set up a structure for my project that mirrors what will be on the final server it requires having sub directories in the project to protect php's that will only ever be included or required and contain vital information that can never be exposed to the client. It seems the only possible way to set the web root is to put the project file in the directory that is to be the web root but then the project no longer recognizes any folders above the one it's in and puts all the other files in the root of the project. I would prefer if there was an option in the properties dialog for the project to set the web root, since I'm sure this is being passed as a parameter to the built in php server. Will these be a feature available in the future or is there any way to possibly do this already?
You are right, that would be quite useful reasonable feature to configure relative path to actual server root.
For now, you can setup custom web server, and we'll try to put this option into close future update.
Jakub Misek, was there any update to this? We wanted our project to point to our root above htdocs, but then when we go to launch our project it is pointing to htdocs/index.php, which is technically correct but it'd be better if we could have project root and project web root or something.
We have found a similar situation where the composer.json file is not in our htdocs directory but the directory above it. We did this so both our vendor directory and our composer.json is not publicly visible.
I tried adding composer.json as a linked file when I setup a new project to point at my htdocs folder as the project folder, but it resulted in this error when attempting to update packages.
Could not read ./composer.json
file_get_contents(./composer.json): failed to open stream: No such file or
Only other solution I see is to put composer.json in my htdocs folder, have some php/apache config so it isn't accessible via web access and get the composer.json to store its vendor folder in ../vendor/
Infact you cant. Tried mssql_connect for my mssql server and couldnt connect. I tried editing the php.ini/development and release ini's and adding microsofts drivers to the extension folder but that buggered the entire PHP for visual studio up. I couldnt run it after that. (Reinstalled) So this basically has no MSSQL functionality and is forcing you to use MySQL which then means a massive hassle if your hosting in Azure.
Just enable mssql as described at MSSQL driver documentation. This has actually nothing to do with PHP Tools or Visual Studio itself. Please read related information for more details:
Please let me know if it helps.
I already followed that stackoverflow tutorial when I wrote the comment. Like I said editing the ini files causes debug to stop and for a constant message stating Php tools isnt isntalled etc once you fix the errors it just does it again and again. You cant edit the ini files in IIS Express without buggering Php tools up.
Hi! I wanted to use your extension for php developing, everything is fine, code completion etc but when I am adding new files in VS2013 they are created as ANSII files. It makes my site showing weird signs. Is there any posibility to force UTF8 decoding on files?
Second thing is that I don't have code completion for CSS files. I have included i.e. bootstrap file into project and in editor there is no classes from that file.
Thank's for explanations.
First of all, the encoding of files must match the charset of your web application (http://www.w3.org/International/O-HTTP-charset). Then the web browser will decode the content correctly.
UTF8 & PHP cause a few issues. Mostly the BOM (which is 3 bytes pattern at the beginning of regular UTF8 file) is not handled by PHP and is shown at every 'include' you have. That's why you can either use 'UTF8 without BOM' or use local encoding. Sadly, if there is no BOM, text editor has to guess what encoding should be used to display the file content.
Visual Studio is somewhat smart about determining what encoding the file is. In case there is no BOM at the beginning of file, it looks for UTF8 characters (if enabled in Tools | Options | Text Editor | General - Auto-detect UTF-8). Otherwise it fallbacks to your computer local encoding.
Anyway, we have an option to force 'UTF8 without BOM' in Tools | Options | Text Editor | PHP | Advanced. Try this one, and ensure your are setting the charset header correctly.
Second; css InteliSense is a Visual Studio feature, and it should work for css files inside a PHP project. For more information please send us feedback directly from VS http://docs.devsense.com/troubleshooting/feedback
Publish method: SFTP
1 )Select php project, right click open context menu
2) Add Existing File, choose other php project's php file
3) Click the drop down at the right of Add button, select Add as link
Selected linked file, right click open context menu, "Publish xxxx.xxx"
Selected project, right click open context menu, click Publish, click Publish
Project start publishing, but linked file is not being published to server.
I guess this is bug?
When publishing a project, I get a dialog box asking me to select the 'Publish Profile', however I do not get this when I publish a single file or folder. Can this be added, or is it a setting that I have missed?
The extension is fantastic, by the way.
Sorry for the delay. We're very happy that you like PHP Tools!
Publish selection feature uses the currently selected (last used profile). So you have to go to Publish dialog to select the profile. We are going to think of something which would make this switching easier.
Thanks for the feedback!