[theme-reviewers] PHP 5.3 In Themes

Ryan Van Etten ryanve at gmail.com
Sun Apr 21 23:57:44 UTC 2013


*@Simon* Yes that syntax applies 5.3+

*@Chip @Otto* A viable way for themes to gracefully degrade:
action/functions.php<https://github.com/ryanve/action/blob/bb6a2ac2579e14c012256f1b68963afcff84222b/functions.php>


Ideally detection would be handled by wp-admin as described at the start of
this thread.

@ryanve <http://twitter.com/ryanve> | 646-853-4941 |
ryanve.com<http://ryanvanetten.com/>




On Sat, Mar 30, 2013 at 7:31 AM, Simon Prosser <pross at pross.org.uk> wrote:

> isnt using function like that 5.3 and above only? 5.2 you need
> create_function()
>
>
> On 30 March 2013 00:28, Ryan Van Etten <ryanve at gmail.com> wrote:
>
>> *Re: child theme friendliness:*  The anonymous pattern below removes any
>> possibility of calling a non-existing callback. It is future-safe b/c no
>> functions are exposed, yet it still gives child themes full flexibility.
>> Such a pattern prevents breakage b/c it is not reliant on parent theme
>> functions that may be removed or renamed in an update.
>>
>> add_action('@entry', apply_filters('@entry_actions', function() {
>>     # default actions
>> });
>>
>> @ryanve <http://twitter.com/ryanve>
>>
>>
>>
>> On Wed, Mar 6, 2013 at 12:07 PM, Otto <otto at ottodestruct.com> wrote:
>>
>>> On Tue, Mar 5, 2013 at 3:23 PM, Ryan Van Etten <ryanve at gmail.com> wrote:
>>> > I'd like to see WP be proactive about encouraging users to use 5.3+.
>>> The
>>> > sooner we get the majority on 5.3, the better it will be for the core
>>> too.
>>>
>>> Call me crazy, but I don't think it's a particularly good idea to
>>> offer code that won't work with 2/3rds of the existing user base.
>>>
>>> http://wordpress.org/about/stats/
>>>
>>> Note that most people don't have any control over what version of PHP
>>> is running on their server.
>>>
>>> -Otto
>>> _______________________________________________
>>> theme-reviewers mailing list
>>> theme-reviewers at lists.wordpress.org
>>> http://lists.wordpress.org/mailman/listinfo/theme-reviewers
>>>
>>
>>
>> _______________________________________________
>> theme-reviewers mailing list
>> theme-reviewers at lists.wordpress.org
>> http://lists.wordpress.org/mailman/listinfo/theme-reviewers
>>
>>
>
>
> --
> My Blog: http://pross.org.uk/
> Plugins : http://pross.org.uk/plugins/
> Themes: http://wordpress.org/extend/themes/profile/pross
>
> _______________________________________________
> theme-reviewers mailing list
> theme-reviewers at lists.wordpress.org
> http://lists.wordpress.org/mailman/listinfo/theme-reviewers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wordpress.org/pipermail/theme-reviewers/attachments/20130421/e38d6a80/attachment-0001.htm>


More information about the theme-reviewers mailing list