Are you ignoring your Host's PHP Set Up?

  Рет қаралды 2,126

Web Squadron

Web Squadron

17 күн бұрын

Are you ignoring your Host's PHP Set Up?
Grab our Course and $1 Business Packs: learn.websquadron.co.uk/#packs
Elementor Hosting - managed wordpress hosting :
be.elementor.com/visit/?bta=2...
Elementor Pro - The builder that will make you a pro
be.elementor.com/visit/?bta=2...
Book your 1-2-1 Consultation: learn.websquadron.co.uk/#support
We love to create - share - respond - and deliver.
Join our Facebook Group: / 3309523509284305
Get Code Snippets Pro: r.freemius.com/10565/3304295/

Пікірлер: 40
@phillankester
@phillankester 14 күн бұрын
Based on our experience, a 768M memory limit for PHP is typically more than sufficient; we rarely encounter situations where PHP workers exhaust even 512M. In shared hosting environments, the primary constraint tends to be the availability of PHP workers, with many shared hosting environments capping this at 2 workers. This limitation is more likely to impact performance than the memory limit. Additionally, our default file size upload limit is set to 16M to protect the hosting environment from potential abuse. However, we sometimes increase this limit upon request for clients who need to upload larger files. :D
@websquadron
@websquadron 14 күн бұрын
Great points.
@zadekeys2194
@zadekeys2194 14 күн бұрын
Out of interest, what files are they uploading that are 16MB or more? Hopefully not images 😂
@phillankester
@phillankester 14 күн бұрын
@@zadekeys2194 sometimes PDFs can be huge. a few clients have various media types. :)
@nigelhancock3580
@nigelhancock3580 14 күн бұрын
I have a strong suspicion that there are hosting companies out there that allow you to apparently increase PHP memory limit but, in the background it's still capped at some silly low number.
@websquadron
@websquadron 14 күн бұрын
Totally agree. There is one that begins with 'K' that cap you at 256 Limit unless you go to their highest Premium Package but they don't reveal that to you until you hit a problem :(
@ericblackwell3727
@ericblackwell3727 14 күн бұрын
@@websquadron Yep. I hit that head on awhile back and had to move away from them.
@phantomcraneflymusic
@phantomcraneflymusic 14 күн бұрын
@@websquadron Would there be a way to test this?
@StuartLowPhotography
@StuartLowPhotography 14 күн бұрын
This is a touch misleading because there's no one size fits all. If your site uses more than 100 MB per request or if your site needs more than 256Mb to generate a single page, something is very wrong with your site's code. You shouldn't just increase the limit to 768mb for the sake of it because that won't speed up your site. 256mb is a safe default limit and you should only increase it if you're seeing memory limit hit fatal errors etc. A site with PHP 7 + Cache enabled uses up to 5x less memory. For example, a site 7.4 with 20mb per request doesn't need more than 64mb.
@boutzero
@boutzero 15 күн бұрын
Muchísimas gracias!!
@CFGroove
@CFGroove 14 күн бұрын
You. Are. The. Man. xo
@just_jen
@just_jen 14 күн бұрын
Good to know! Thanks, Imran!
@websquadron
@websquadron 14 күн бұрын
No problem 👍
@zadekeys2194
@zadekeys2194 14 күн бұрын
Imran, my host (Hetzner) limits the RAM to 256MB, and I've never had any issues. With no CDN or Cache plugins, I can get my sites to above 90% in GTmetrix and other speed tests. I think this comes down to proper image opt and setting the site to load properly, eg preload logo, company name, menu, hero image and lazy load the rest.
@websquadron
@websquadron 14 күн бұрын
Agreed on all points
@markbratton111
@markbratton111 14 күн бұрын
VERY important
@Mymysticmama
@Mymysticmama 15 күн бұрын
This is very useful. I have both those settings at 1024M (trying to solve a problem with Printful where if I have more than 3 variants on a product it kicks some timeout error. Still haven't solved it). My site health keeps reminding me I have an "outdate SQL server". Clueless on how to fix that. BUT.......I have I told you lately that yer AWESOME!!! ♥
@websquadron
@websquadron 15 күн бұрын
Go to your WordPress dashboard, navigate to Tools > Site Health > Info, and check the database version. Contact your hosting provider’s support and ask them to update the MySQL server to the latest stable version. They will handle the update for you. PS: Optimize your database using a plugin like "WP-Optimize" to ensure it’s running efficiently.
@zadekeys2194
@zadekeys2194 14 күн бұрын
Make sure you are running php 8 and that your images are scaled properly and optimised before converting them to webp. My host limits me to 256MB and I've never had issues with performance. Most if not all of my sites get over 90% in GTmetrix, page speed score etc. This is without any cache or CDN plugin.
@tamera00
@tamera00 12 күн бұрын
As usual I love your vids, BUT PHP 7.4? you really should be on 8.3 or at least 8.1 for plugins to work correctly. But always love your videos
@hosterplus
@hosterplus 15 күн бұрын
Tolles Video, Imran! 👏 Die Betonung auf die PHP-Memory-Limits und die maximale Dateigröße beim Upload ist extrem wichtig und wird oft übersehen. Deine Erklärungen sind klar und praxisnah, besonders für diejenigen, die ihre Websites optimieren möchten. Eine Frage hätte ich: Wie siehst du die Entwicklung von PHP in den nächsten Jahren, insbesondere in Bezug auf die zunehmende Nutzung von serverlosen Architekturen und modernen Webtechnologien? Denkst du, dass PHP weiterhin eine wichtige Rolle spielen wird oder werden andere Technologien die Oberhand gewinnen? 🤔 Freue mich auf deine Antwort und weitere informative Videos! 😊
@websquadron
@websquadron 15 күн бұрын
Great question! PHP has been a powerhouse for web development for years, and it's constantly evolving. While other languages and frameworks are gaining traction, PHP's large ecosystem, continuous updates, and strong community support ensure it will remain a key player. It's not going anywhere soon-expect it to coexist and integrate with emerging technologies rather than be overshadowed. I think. And I am probably wrong :)
@johnwellington269
@johnwellington269 13 күн бұрын
whats ur view on cloudways? is it allow 768mb?
@Tom59Kriek
@Tom59Kriek 10 күн бұрын
My SP limits the max file upload size to 4G. They claim you do not need more than that. They have made me jump hoops to get the latest SEO Pro plugin (4.12G) uploaded and installed. I queried them and they do not want to budge, saying it is to limit DDOS attacks. It sounds like hogwash to me. So, they give two reasons. Bigger than 4G is not needed and DDOS. Any comments?
@shuvobaroi7766
@shuvobaroi7766 15 күн бұрын
@Imran is there any way to change these PHP settings from the website by plugin or custom code? Some clients, don't want to share hosting credentials :)
@websquadron
@websquadron 15 күн бұрын
I refuse to work with clients that don't share hosting, or don't have a named person who is clued up for any hosting issues. Yes, you can change PHP settings directly from your WordPress website using either a plugin or custom code. Here are both approaches: ### Using a Plugin 1. **WP Config File Editor Plugin:** - Install and activate the "WP Config File Editor" plugin. - Go to the plugin settings from the WordPress dashboard. - Use the plugin interface to modify PHP settings in the `wp-config.php` file. 2. **PHP Settings Plugin:** - Install and activate the "PHP Settings" plugin. - Navigate to Settings > PHP Settings. - You can change various PHP settings directly from the plugin interface. ### Using Custom Code You can add custom code to your `wp-config.php` file to change PHP settings. Here’s how to do it: 1. **Edit `wp-config.php`:** - Access your WordPress installation files via FTP or a file manager. - Locate and open the `wp-config.php` file. 2. **Add PHP Settings:** - Add the following lines of code to modify PHP settings. Adjust the values as needed: ```php @ini_set('upload_max_filesize', '64M'); @ini_set('post_max_size', '64M'); @ini_set('memory_limit', '256M'); @ini_set('max_execution_time', '300'); @ini_set('max_input_time', '300'); ``` - These lines set the `upload_max_filesize`, `post_max_size`, `memory_limit`, `max_execution_time`, and `max_input_time` PHP settings. 3. **Save and Upload:** - Save the changes to the `wp-config.php` file and upload it back to your server if you used FTP. ### Example: Changing Memory Limit via Code If you want to increase the memory limit, add the following line to your `wp-config.php` file: ```php define('WP_MEMORY_LIMIT', '256M'); ``` ### Note: While these methods are generally safe, incorrect changes to the `wp-config.php` file can break your site. Always back up your site before making changes. By using either of these methods, you can easily adjust PHP settings from within your WordPress site.
@zadekeys2194
@zadekeys2194 14 күн бұрын
Setup a staging environment on the client's environment and work in a clone of the site there, one where you have access. Clients who refuse to share such details only slow you down and that means more cost for the client....
@shuvobaroi7766
@shuvobaroi7766 14 күн бұрын
@@websquadron Thanks for your valuable feedback! Take love 💟
@stevebullman4116
@stevebullman4116 14 күн бұрын
just to confuse matters....I checked one of my sites which shows its running 512M so I queried this with my host. The server runs 512M per php worker but has 3 workers per website, so in fact I have available 1536, yet Wordpress doesn't recognise the multiple workers. Am I missing something, or is Wordpress missing something?
@websquadron
@websquadron 14 күн бұрын
Oooooooh - great question!
@sigma.m
@sigma.m 15 күн бұрын
What hosting provider do you recommend? Which host are you using in this video?
@websquadron
@websquadron 15 күн бұрын
I use SiteGround, and Elementor Hosting. 20i are good too.
@sigma.m
@sigma.m 15 күн бұрын
​@@websquadron I currently use Chemicloud and it shows the ff: PHP memory limit - 1G; Upload max filesize and PHP post max size - 100M. Do you think the 100M is acceptable? In your sample it shows 250M which is higher. Thanks for your response!
@websquadron
@websquadron 14 күн бұрын
@@sigma.m 100M is fine :)
@zadekeys2194
@zadekeys2194 14 күн бұрын
​@@sigma.mtry not to upload such large files. Images should be waaaaaay smaller.... Video should be placed on a separate CDN and not on your actual site host storage.
@zadekeys2194
@zadekeys2194 14 күн бұрын
​@@sigma.m also, having a large file upload does mean that if your site is compromised, an attacker can upload big files, likely exe's etc and then distribute that using your site. I take mine down to 2-4MB as all my images are under those sizes.
Slash your WordPress Plugins for Code Snippets
18:35
Web Squadron
Рет қаралды 4,5 М.
Leaving Adobe (a long time coming)
18:54
Mike Gastin
Рет қаралды 106 М.
你们会选择哪一辆呢#short #angel #clown
00:20
Super Beauty team
Рет қаралды 17 МЛН
Alat Seru Penolong untuk Mimpi Indah Bayi!
00:31
Let's GLOW! Indonesian
Рет қаралды 15 МЛН
Osman Kalyoncu Sonu Üzücü Saddest Videos Dream Engine 170 #shorts
00:27
Elementor Beta 3.23 just dropped with 3 BIG Features!
13:32
Web Squadron
Рет қаралды 10 М.
Proven Website Formula That Has Made Millions
16:54
Wes McDowell
Рет қаралды 23 М.
build your own cloud
47:13
NetworkChuck
Рет қаралды 1,8 МЛН
`const` was a mistake
31:50
Theo - t3․gg
Рет қаралды 126 М.
3 ways Germany could have won WWII
0:42
Preston Stewart
Рет қаралды 1,8 МЛН
How to Fix a Hacked Site & be Protected from Malware
9:56
Web Squadron
Рет қаралды 2 М.
How to Accept Scope Creep
3:58
Web Squadron
Рет қаралды 593
I cannot live without this WordPress plugin anymore (ASE)
12:18
Rino de Boer
Рет қаралды 25 М.
you STILL need a website RIGHT NOW!! (yes, even in 2024)
19:15
NetworkChuck
Рет қаралды 337 М.
Бездомный помог ребятам на дне рождения 🤯
0:39
Фильмы I Сериалы
Рет қаралды 3,5 МЛН
Ripe watermelon 🍉😍🤣 #demariki
0:11
Demariki
Рет қаралды 1,3 МЛН
Smart Appliances! New Gadgets, Versatile Utensils, Tool Items #shorts #gadgets 73
0:30
Magnetic 🧲 #настольныеигры #boardgames #games #игры #настолки #настольные_игры
0:34
Головоломка с кольцом🤨
0:42
FERMACHI
Рет қаралды 4,9 МЛН