php file problem error showing by vscode extension named php intellisense - php

enter image description here
I have been facing this problem for a long time while using the extension for the PHP file, I always see this error about some kind of deprecation, didn't find any solution yet, it's very annoying actually.
tried solving by:
reinstalling vscode
uninstall then install the extension again,
while used in other IDE, it works just fine
the file works but, don't know what's the error

Related

Problem with formatting PHP code within VsCode

I am running Windows 10 latest version and VsCode latest version. I'm setting up a website using a PHP framework. Natively there seems no formatting support for PHP so I turned to plugins. I tried 'Format HTML in PHP' and that does exactly what it says - a page of HTML in a file with a .php extension is formatted on save. However when I try to format say a Controller, either on save or by pressing Alt-Shift-F, absolutely nothing happens. I have tried installing 'PHPfmt', 'PHP Intelephense, and 'Prettier' but in each case any attempt to format the Controller (Alt-Shift-F) failed to change anything. Yes I did restart the editor in every case. Can anyone suggest why this is not working or a plugin better than the ones I have tried? Is 'Format HTML in PHP' incompatible with the other plugins? I have really spent a long time on this and got nowhere.

Vscode php debugger Illuminate\Contracts\Filesystem\FileNotFoundException: File does not exist at path

I trying to debug a laravel code using vscode debugger, but I did, mark a break point on some controller line and then run debugger I encountered this
Illuminate\Contracts\Filesystem\FileNotFoundException: File does not exist at path /mnt/c/projects/www/mycrateclub/storage/framework/cache/data/6f/cf/6fcf17e03636125ae681cea5779f3e9bfc88abbb
I running it in WSL with ubuntu 18.04 version and with php 7.2 installed.
I don't know what to do with, I'm stack.
Does anyone has experience the same?
I don't know where exactly the problem, laravel or vscode debugger, and I don't know either where to create issue, on vscode or laravel.
Turn off Exceptions in the Run/Debugging panel in the bottom left corner of your VS Code window. As Jeeba mentioned in the question comments, this error is a false positive. This is the only work-around I've found.
VS Code Breakpoints screenshot

Visual Studio Code can't validate PHP, I added it to the path, but it's still alerting me

That's the alert it's showing.
As you can see, I already set the path (I also tried another .exe, from WAMP), but it is still alerting that PHP executable wasn't found.
I have no idea why, but it started to happen after I installed this extension:
Before that it was set the same way as now (executablePath: php.exe) and it was all right. After I installed the PHP IntelliSense, I've found no way to fix that.
Hope some of you already faced this, and can help me.
Thanks!

Netbeans - Ubuntu - Php - Code suggestion

I have a strange situation on Netbeans for PHP on Ubuntu. I have enabled code completion and It only happens for me once.
meaning, Ex: if I type in_array (php base function) for the very first time it gives me suggestion. Then in the next code line if I type in_array, Now I don't see suggestions.
I googled and what I found was to enable code completion.
Does anybody had experience on this strange situation? Any one knows how to make it work?
I dont know what causes this. But I could fix it. Simply uninstall netbeans and re-install it. (re installation done with a fresh download from the site)
Thats it.

Pear DB Error: extension not found

I am still new to php and linux but i try to give you all information I know.
We got a PHP web application using pear and smarty. It's runing on PHP 4 on a Linux system and with XAMP and PHP5 on my PC. I am trying to move the application on a new server with PHP7 and updated PEAR and all extensions (it's the same version as on XAMP), but all I get is: DB Error: extension not found.
I tried to find a solution but wasn't able to find anything which could help me.
The database we are using is a normal mysql database.
I'm not sure if there is still a path missing or what went wrong.
Maybe someone of you got a clue what the problem could be.
It sounds like your very old PHP4 code is using the mysql_ database extension?
If so that extension has been deprecated for years and was completely removed from PHP7. You wont be able to move that code to any version of PHP higher than PHP5.6 and even trying to do that you will almost definitely come across lots of other incompatibilities
I suggest you read http://php.net/manual/en/migration70.php in the menu on this page there is a section on migrating from all sorts of versions of PHP.
You will have to work out how far up the migration levels your code will actually move without major amendments. I would guess, not very far!

Categories