PHP Intelephense Error in Laravel Blade File - php

I get this error using thi type of code in my blade file, anyone have a way to remove this error?
the red underline should be gone

Usually, installing the previous version or slightly older version of the plugin works. Try installing the previous version of PHP Intelephense. Once encountered this on VS Code. All the best.

Related

VSCode: PHP syntax error on multiple return types

syntax errors
Its ok where we have one return type, and syntax error when two
What should i install to have correctly supported syntax for this, There is no mistake in code and php-interpreter accepts this fully correct use
You need PHP 8.0 or newer to support union types
It looks like some plugin configuration error.
What vscode plugin do you use?
I recommend to install this one - it has support of php >8.0 features, which will be useful and probably solve your problem.
Removed PHP Tools, removed php intelisense, reload and after installed only php intellisense
Now it works))

PHP version update issue

I Tried to update my PHP version located on Hostgator. Actually, I'm using but PHP 5.0 and WordPress is requiring at least the PHP 7 version.
After doing that, through the c-panel, my website went down.
This is the message that I received:
Your PHP installation appears to be missing the MySQL extension which is required by WordPress
I was obliged to roll-back so that it works again.
Please can you help me solve that problem?
Thanks in advance.
The php mysql api is deprecated. It's kaput --- going away -- not to be used, finito.
If you have a modern version of PHP (> 5.6) then Wordpress should automatically switch to make use of mysqli. That should be your first attempt.
If you can not update your php, rather than attempting to resurrect something that php no longer supports, just patch your wordpress: http://wordpress.org/plugins/mysqli/

How guess php version by static analysis of code

How to "guess" php version by looking at code?
Suppose you're handed a zip file containing php code for an application.
Are there any telltale signs about which version (5.x, 7.1, 7.3,etc )
the original author was working with?
My issue is, I suspect I'm running an incorrect php version for my (phalcon) application, my users can't log in. I see in logs
"PHP Warning: Use of undefined constant success - assumed 'success' (this will throw an Error in a future version of PHP)"
and
Uncaught Error: Class 'View' not found in ....
In general, this is not possible. You can inspect the set of features the original author used and try to identify a minimal version. When you find removed features you can also find a maximum version.
According to your warning message I assume you are using PHP 7.2 right now?!
The author probably developed this with a lower version (5.x) or has disabled warnings.
Maybe have a look here for more info about your warning message.
However, the warnings and errors you get are not really version related but seem to result from missing files and / or bad programming.
You should try to make it work with Version 7.2+ instead of choosing the version matching the developers version. Have a look at PHP versions here.

Twig does not render just anything

I have problems since I've upgraded PHP on my server to version 7.1.8 from 5.6.something.
Twig engine just does not want to render anything. Even the basic array example. It just returns the plain text of the page. Currently I am using Twig version 2.4.4, but I have noticed that it was doing the same with previous that I had - version 1.something.
There is no error, no notice, nothing, just it returns the plain text of the template.
Can you give me an idea where can I look and is there any specific setting of PHP that I have to adjust?
Ok. I've found the problem!
In PHP version 7.1.8 there is a problem with PCRE library.
It uses outdated 8.38 version internaly.
I don't know what is the exact problem but I've found that it has execution problem with complex search patterns.
I had problems with PHPMailer too and I found that it's not evaluating perfectly valid host mach regex.
I've solved all of my problems by updating PHP to the latest version.

TYPO3 PHP Runtime Deprecation Notice:

i have a problem with some old TYPO3 stuff, i tried to make a old TYPO3 Website run on my Ubuntu system.
And sorry if somethings are not clear to understand for me, i am new in CMS's and i am forced to change some stuff on a old page.
Problems are:
1.
Backend seems working, half. If i enable the ext. TemplaVoila my be Page module shows me a white page.
On TV disable,
Page module, seems working but it gives me some strange error messages inside the content fields.
if i try to look at the front-end it gives me this exception:
1: PHP Runtime Deprecation Notice: Non-static method tx_ttnews_div::getSubCategories() should not be called statically,
assuming $this from incompatible context in
/var/www/projectfolder/projectfolder-typo3/typo3conf/ext/tt_news/pi/class.tx_ttnews.php
line 3740
Just apart from this, i read about a removed php feature in update 5.6 i was using currently.
Things i checked already:
-Correct PHP -v
-Database import correct
-LocalConf correct (took from live server and changed for my localhost)
-Checked install-tool and rm -rf * inside typo3temp folder
Thanks for you help
Your PHP version combined with the versions of TYPO3 and extensions seems to be incompatible. You either need to use a different PHP version or upgrade TYPO3 and/or the extensions being used. FYI, the method being called is from a very old extension so although you don't say which version you're using, I assume your TYPO3 version is very old (either 6.x or even 4.x versions).
The normal recommendation would be to upgrade TYPO3 and any extensions. The less recommended alternative would be to use a different PHP version. But please be aware that remaining on older TYPO3 versions means your site may not be patched for security issues and may not be compatible with modern browsers.

Categories