Defer JS [Deleted]

I have this working in PHP 5.3.

Unless I've overlooked something, the only thing that isn't PHP 5.3 compatible is your array syntax. You're using the relatively new array shorthand.

So you're using:
PHP:
[$this, 'collect']
Instead of:
PHP:
array ($this, 'collect')

In my testing, I have just adjusted the array syntax and it appears to be working fine.

View attachment 69527

View attachment 69528
Is it possible to make that available for people on PHP 5.3?
 
Is it possible to make that available for people on PHP 5.3?
I have suggested the code changes in a pull request on GitHub to @Jeremy P. I'll leave it up to him if he chooses to release those changes or not. That's not my place. I was just trying to help him ensure his excellent work with this add-on can get a wider reach.

php 5.4 is the old stable
php 5.5 is the current release
php 5.6 is in the development

5.3 Blah !
5.2 wtf ?


I'm happy the developer is encouraging people to use 5.4 or newer.
I do not disagree. I am not a fan of sticking around on old versions.

Absolutely, PHP 5.2... that can take a long jump.

But:

upload_2014-3-14_10-45-2.webp

5.3 should still get some attention. As much as it would be nice, people aren't likely to upgrade to PHP 5.4 or higher on the basis of this add-on alone. And a big portion of that 50+% is probably down to crap shared hosts being lazy, or a requirement to maintain backwards compatibility with other essential applications. It really isn't fair to start leaving them behind over the syntactical difference between [] and array().
 
As much as it would be nice, people aren't likely to upgrade to PHP 5.4 or higher on the basis of this add-on alone. And a big portion of that 50+% is probably down to crap shared hosts being lazy, or a requirement to maintain backwards compatibility with other essential applications. It really isn't fair to start leaving them behind over the syntactical difference between [] and array().
I just wanted to say that I fully understood on release that the only difference is trivial. I didn't release it unsure why it wasn't working with 5.3, it is that way on purpose.

I don't expect people to upgrade to PHP 5.4 "on the basis of this add-on alone," but because there's great reason to be on 5.4+ even without it. There's no good excuse for being on an older version. You can (and should) run multiple versions of PHP on the same server if you need to support legacy applications.

If you're running a crap shared host I can't imagine why you'd be concerned over the performance to the degree this addon emphasizes. And if you really are, vote with your dollar and move to a better host. Any host worth your money supports 5.4.

All of that said, I do realize the real-world implication is this will exclude bunches of people from being able to use this addon. And people aren't going to read the above and do an about-face and move hosts.. it's optimistic at best. I just think people giving money to hosts that can't be bothered to properly support PHP is part of the problem and offering 5.3 compatibility is no solution to the underlying issue.

In the interests of not being a jerk, I will release a single version that is 5.3 compatible. It won't be supported, it won't receive updates (just like PHP 5.3 ;)), and it won't be in the main download, you'll have to grab it from the FAQ.

@Chris D thanks for the pull request I'll see to it that a 5.3 version is available.. and the above isn't directly solely at you, I'm just explaining my reasoning and venting my frustrations. :)

Do i need this, when i have the Cache Addon from xfrocks installed? :sneaky:
Probably. Check GWTMetrix.
 
hmm i have an issue with adding a new Widget Framework
when i choose render its should give me another options and fields but its dosnt load when ur addon r enable !!

i dono how to exclude it cuz i dono what js tag it called =(
 
hmm i have an issue with adding a new Widget Framework
when i choose render its should give me another options and fields but its dosnt load when ur addon r enable !!

i dono how to exclude it cuz i dono what js tag it called =(
I'll look into this as soon as I can, I might be going to Mexico for the day.
 
That sucks- I have neither, hope all works on my install. :)
If not, simply disabling it should turn it off until it can be worked out. I'll get most of the popular conflicts skipped by default as long as people keep bringing them to my attention.

It's Friday and I'm right about to head south for the evening so I'll get any problems sorted out over the weekend. In the meantime if you can figure out what scripts aren't working you can skip them in the settings.
 
Top Bottom