Apache error.log

Posted in: Newspaper
Post count: 45

Hi everybody,

I am using the Newspaper 7.1.1 With wordpress 4.6.1 and a small and clean theme child customization.
The site seems to be OK, and run without problems, but watching my error.log file in my site in production, i can see a lot of these errors:

[Wed Oct 05 04:26:44 2016] [error] [client 127.0.0.1] PHP Fatal error: Call to undefined function get_header() in /var/www/domain.com/public_html/wp-content/themes/Newspaper/index.php on line 6, referer: http://www.domain.com/wp-content/themes/Newspaper

[Wed Oct 05 04:38:12 2016] [error] [client 127.0.0.1] Invalid URI in request GET /../fonts/vc_grid/vc_grid_v1.eot?-9hbgac HTTP/1.1, referer: http://www.domain.com/wp-content/plugins/js_composer/assets/css/js_composer.min.css

These can be resolved?

Post count: 285

Hi,

1. open your index.php and change the line 6 get_header(); with this

if (function_exists('get_header')) {
get_header();
}else{
header("Location: http://www.yourdomain.com ");
exit;
};

change the link in location with your domain

2. you are using an old version of theme & plugins with the last version of WP, the actual version of Newspaper is 7.4 (also Visual Composer was updated)

Post count: 2

I replaced the code and can not see the site

Post count: 22421

Hello,

Did you change the URL in the code? If you just copy the code as it is, it will redirect to http://www.yourdomain.com.
You have to adapt the code to your own url. Add your homepage for example. Add the full url including the http part.

Thank you!

Post count: 24

I had the same problem in NEWSMAG theme.
Following your instructions, SOLVED.
Thank you very very much.
Just letting you now i am using latest versions BUT i had the same problem.
I don’t now why !!!
So, after 6 months you helped me FIX it.
Dinos.
http://www.diorama.com

Post count: 22421

Glad you solved the issue!
Have a nice day!

Viewing 6 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic.