Explore tweets tagged as #PHPtips
@RmeetsH
Roberto B.
2 years
PHP tip: you can run `composer audit` to check โœ… for security vulnerability advisories ๐Ÿ‘ฎ for installed packages. ๐Ÿ’… `composer audit` #php #ecosystem #composer #security #vulnerability #advisory #check #phptips
1
1
4
@alexdaubois
Alexandre Daubois
5 months
๐Ÿ“ฃ This JUST got merged in #PHP a few minutes ago! It is currently challenging to deal with recursion in anonymous functions. Not anymore in PHP 8.5: the "Closure::getCurrent()" method fetches the current closure you're in ๐Ÿš€ PR: https://t.co/F8eHMbIr7R #phptips
4
28
158
@iharpreetbhatti
Harpreet Singh
1 month
Need to reverse a string in #PHP? ๐Ÿ’กHere are 2 ways to get the same output in a single line! Which one do you prefer? #PHPTips #Coding #WebDev
0
0
0
@freelancerguy_
Dhiraj Mehta
1 year
Use the `wp_nav_menu()` function to easily display custom navigation menus in your theme. Simply add it to your template file where you want the menu to appear: This function is highly customizable, allowing you to create dynamic menus with ease! #WordPress #PHPTips
0
0
2
@amrcodes
Ray ๎จ€
3 years
#PHPTips Need to sum up all the values in an array? Try using PHP's built-in array_sum function! It's a simple and efficient way to calculate the total, without the need for loops or variables. #PHP #codingtips
0
0
0
@DanielSundayEf1
SigmaDev (ฮฃ)
3 years
Did you know: You can clone/reuse queries in Laravel #sigma_dev #100DaysOfLaravel #100DaysOfPHP #LaravelTips #PHPTips #100DaysOfCode day 6
1
1
5
@EmmaDSCodes
Emma De Silva
2 years
Here's a simple way to copy a string to the Windows Clipboard from a PHP CLI script. Use responsibly! #php #phptips
2
0
1
@ang3l1n
Angelin Dan ๐Ÿ’ป | DEV
2 years
Check if a key exists in an array with array_key_exists()๐Ÿš€ #php #webdevelopment #arrays #functions #arraykeyexists #phptips #phpbestpractices
0
0
0
@aecarlosae
Carlos Espinoza
1 year
PHP's array_filter for cleaner code! Here's how to remove all empty values from an array in just one line: This simple function call uses strlen to keep only non-empty strings. #PHP #PHPTips
0
0
0
@realtauseed
Taused ๐Ÿ‡ต๐Ÿ‡ธ
1 year
๐Ÿ”— PHP Tip: Use the nullsafe operator `(?->)` to avoid null pointer exceptions! ๐Ÿคฉ i.e: `$user?->username` No more pesky isset() checks or null checks! ๐Ÿ’ป #PHPTips #NullSafety
0
0
0
@realtauseed
Taused ๐Ÿ‡ต๐Ÿ‡ธ
2 years
๐Ÿš€ PHP Tip! ๐Ÿ’ป Need to execute multiple SQL queries at once? ๐Ÿค” Use the `multi_query()` method! ๐Ÿ’ฅ e.g: `$mysqli->multi_query("SELECT * FROM table1; SELECT * FROM table2;");` Executes multiple queries in a single call, reducing database connections! ๐Ÿ’ป #PHPTips #MySQLHacks
0
0
0
@realtauseed
Taused ๐Ÿ‡ต๐Ÿ‡ธ
1 year
๐Ÿ’ก PHP Tip: Make your code more flexible with `union types`! ๐Ÿ”ฉ Use `|` to specify multiple types for a single parameter or property, allowing for more flexibility. Example: `function greet(string|int $name): string { ... }` ๐Ÿคฉ Write more robust and adaptable code! #PHPTips
0
0
0
@realtauseed
Taused ๐Ÿ‡ต๐Ÿ‡ธ
1 year
๐Ÿš€ PHP Tip: Use the `<<<` heredoc syntax to define multiline strings in PHP! ๐Ÿ’ป i.e: `$multiLineString = <<<END This is a multiline string with multiple lines and no need for concatenation! END;` Goodbye, cumbersome concatenation! ๐Ÿ‘‹ #PHPTips #CleanCode
0
0
0
@CodeSushil
Sushil Kumar ๐Ÿ€
1 year
Learn PHP With Me: if-else, switch, and Match expression. #php #learnPHP #phptips #Tips #tricks #CodeWithSushil #CONNECT
0
0
2
@alnahian2003
Al Nahian ๐ŸŽฏ
3 years
๐Ÿ”ฅ #PHP Tip ๐Ÿ”ฅ Use PHP's built-in functions like `array_map`, `array_filter`, and `array_reduce` to manipulate arrays in a concise and readable way. ๐Ÿš€๐Ÿ” #PHPTips #PHPTricks #PHPDeveloper #LaravelCommunity #WebDevelopment #WebDev #CodeTips #CodingLife #CodingTips
0
0
0
@_sureshramani_
Suresh Ramani ๐Ÿ‡ฎ๐Ÿ‡ณ
2 years
UploadFile macro to get uuid/hashed name of the file. #laravel #laraveltips #php #phptips
0
0
1
@devhubbycom
Devhubby
1 year
Is mysqli the old-school PHP player while PDO is the new kid on the block? Source: https://t.co/r0atCogVgB #PHPTips #Coding #PHPDevelopment #CodingTips #difference #bethedifference
0
4
8
@CodeSushil
Sushil Kumar ๐Ÿ€
5 months
Right way to secure your session. ๐Ÿ’กTips: #php #session #phptips #phptricks #security #xss #csrf
0
0
2
@PHPZenOrg
PHP Zen
20 days
PHP Stream Wrappers are one of the most underrated features in the language. ๐Ÿ“Œ Local file? ๐Ÿ“Œ HTTPS? ๐Ÿ“Œ Inside a ZIP? โ†’ Same function. Only the URL changes. ๐Ÿ”— LINK : https://t.co/UJd3FmKBcB #PHP #Coding #Backend #WebDev #PHPTips
0
2
2