-
Notifications
You must be signed in to change notification settings - Fork 862
comments.php error #297
Comments
Also getting this error with a fresh install, looking at 7acc16c and reverting line 39 code back to what it was resolves the issue. Hoping olefredrik has a chance to take a look at this. |
Same here - I also tried this with Josh's fork https://github.com/josh-rathke/FoundationPress I wanted to try to use FP as a parent theme, but it looks like it's really better to approach this like using UnderscoreS - and just start adding / removing what I need directly, instead of building a Child theme. |
Same here... Fatal error: Can't use function return value in write context in C:\EasyPHP14\data\localweb\projects\w4\wp-content\themes\foundationpress\comments.php on line 39 Like @t-fulton says, I change the line and works... Fallback to: if (!empty($_SERVER['SCRIPT_FILENAME']) && 'comments.php' == basename($_SERVER['SCRIPT_FILENAME']))
die (__('Please do not load this page directly. Thanks!', 'FoundationPress')); |
Assigning to a variable and then checking if the variable is empty seems to work. $file_name_to_check = sanitize_file_name( $_SERVER['SCRIPT_FILENAME'] );
if ( ! empty( $file_name_to_check) && 'comments.php' == basename( sanitize_file_name( $_SERVER['SCRIPT_FILENAME'] ) ) ) {
die (__( 'Please do not load this page directly. Thanks!', 'FoundationPress' )); } |
That helped me @LukePettway, thanks. |
Fixed #309 . Shoutout to @josh-rathke for saving the day! |
I'm getting this error:
Fatal error: Can't use function return value in write context in .../comments.php on line 39
any ideas?
The text was updated successfully, but these errors were encountered: