Forum Replies Created

Viewing 8 replies - 1 through 8 (of 8 total)
  • My temporary workaround was to comment out the offending lines.

    We have the same error. (Our server runs PHP 7.3.32 even though php 7.4 dates to 2018).

    Unfortunately ofrayechiel is correct. When Zend added arrow functions in 7.4, it now throws errors in the syntax parser of existing, older versions of PHP.

    I think the only viable long term solution for us is to upgrade to at least PHP 7.4. But even 7.4 is already in end of life security fix mode, and Zend is now developing PHP 8.0.

    In the short term, if this new arrow syntax is necessary to run on 7.4 (I do not believe that this is the case–I know them from js, where arrow functions are a convenient shorthand), the plugin probably should now state it requires php 7.4.

    • This reply was modified 2 years, 10 months ago by timr.
    • This reply was modified 2 years, 10 months ago by timr.

    This problem with TinyMCE eating div tags is all over the support forum.

    But there is a way to keep using the visual editor and make things work better–use a plugin like quicktags or write a set of replacement functions to provide formatted div code in your theme’s functions.php.

    I did the latter for my rounded corners inside wordpress posts article…

    Thread Starter timr

    (@trohrer)

    Ok, it appears that ABSPATH is undefined before calling wp-config as I was trying to do in the above message.

    So I can crudely use relative paths as below, and then get wp-config to run, after which the php code to get the site_root URL will work.

    require_once( '../../../wp-config.php');
    $site_root = parse_url(get_settings('siteurl'));
    $site_root = trailingslashit($site_root['path']);

    This still seems clunky to me. Is there a better way?

    (I should note for the sake of not confusing others that my plugin resides in a directory. For a plugin not contained in its own directory there would need to be only two .. relative path-out markers–back out once to wp-content, then back out again to the wordpress root directory.)

    macbrink’s solution is nice, but it still leaves a self-created security hole for xmlrpc.php attacks. A simple and slightly better solution: First, copy xmlrpc.php to yourownrandomname.php,

    Second, use macbrink’s .htaccess modification method above, but instead of leaving the security hole open at xmlrpc.php, it is now at at a (hopefully) unique filename that the script-kiddies won’t bother to attack.

    <Files yourownrandomname.php>
    SecFilterInheritance Off
    </Files>

    Third, change DeepestSender or WindowsLiveWriter, Performancing or whatever blog client you use to point to yourownrandomname.php rather than xmlrpc.php.

    I’ve done lots more explanation at:

    https://timrohrer.com/blog/?p=96

    There is now a simple WordPress spreadsheet plugin to interactively work with spreadsheet data stored as an an html table. It is still fairly primitive and very much under development.

    You can read about it at:

    https://timrohrer.com/blog/?page_id=71

    There is now a simple WordPress spreadsheet plugin that interactively manages data in html tables. It is still pretty primitive and under development.

    You can read about it at:

    https://timrohrer.com/blog/?page_id=71

    There is now a native WordPress spreadsheet plugin (widget). It is still pretty primitive and in development. It does not take excel files as input however.

    You can read about it at https://timrohrer.com/blog/?page_id=71

    If you want to make the advanced toolbar the default, and have it appear every time you can check my post on customizing the TinyMCE visual editor buttons in WordPress 2.1 at

    https://timrohrer.com/blog/?p=29

    There’s also some instructions on how to customize the toolbar.

Viewing 8 replies - 1 through 8 (of 8 total)