skip to Main Content

I just started with WordPress and I published a website a few weeks ago. Today I wanted to edit the homepage, but I get the following error:

Sorry, the content area was not found in your page. You must call the_content function in the current template, in order for Elementor to work on this page.

I haven’t edited my homepage and it worked perfectly a couple of weeks ago. Is there someone that can help me fix this issue?

6

Answers


  1. Probably you’ve edited the page template from Templates -> Theme Builder -> Single. Anyway, even if you don’t, you can fix it that way: Go to Templates -> Theme Builder -> Single -> Add New, then select page and create a template for all single pages (make sure that you drag the page content widget in the template). This should overwrite your theme single page template (which misses the content function).

    Login or Signup to reply.
  2. Just make sure your ‘Home Page’ and ‘Posts Page’ are different, otherwise you get your page mixed up and this error occurs.. Worked for me!
    You can verify this setting in Appearance>Customize>Homepage Settings ๐Ÿ™‚

    Login or Signup to reply.
  3. If you are using any shortcode on your page and you are fetching post on that page and looping through the post in a while loop. Please add this after the loop ends. No sure why but this always cause issue for me.

    wp_reset_postdata();

    Code will look like this:

    $posts= new WP_Query($args);
    while ($posts->have_posts() ) : $posts->the_post();
      .....
      .....
      .....
    endwhile;
    wp_reset_postdata();
    

    It doesn’t matter it’s a shortcode or what if we are doing something like above make sure to add wp_reset_postdata();

    This is one of the issues that I usually face. There can be other reasons too.

    Login or Signup to reply.
  4. I found myself in the same place yesterday and freaked for a moment and did some research to find out why I was receiving the error and came across this page. Believe for me it occurred due to the situation Ed Jones posted about above, I had inadvertently edited the post template. But a fast and easy fix was to go back to an earlier revision of the page in my history. That solved my problem quickly.

    Login or Signup to reply.
  5. The Answer to this error is to check the structure of your permalinks. Try to save your permalinks one more time. Also, try to change the permalink structure to โ€œPlainโ€. Some servers do not allow to write to the .htaccess file and as a matter of fact, you cannot always modify your permalink structure and edit with Elementor.

    Login or Signup to reply.
  6. Add the_content() at the end of your templates

    enter image description here

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search