• Hello! My site was working great and suddenly the home page is redirecting to the blog, although I have it configurated to show a static page. I didn’t change plugins or add information from yesterday, where it was working perfect. Tried to update wordpress, but nothing changes.

    I have a slider and 3 featured links set up and when I choose to show blog entries in the home page, it works fine, also when I choose not showing anything, but any static page I use causes showing (or maybe redirecting) to the blog.

    Can you help? site: https://www.aldeadeluz.com

    Thank you

Viewing 4 replies - 1 through 4 (of 4 total)
  • Have you tried:

    – deactivating all plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    – switching to the default theme to rule out any theme-specific problems.

    resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems.

    – resetting your permalinks to the default structure

    Thread Starter guezs

    (@guezs)

    Yes, I tried all that. Even I tried a debug plugin and suddenly I have an email infinite loop which I’m trying to fix right now…

    In the midtime, I saw the page appear. Maybe it has to be with a code in functions.php, as I also disabled all the functions. Maybe that will fix it.

    Do you know how to stop wordpress sending debug emails?

    Thank you

    Thread Starter guezs

    (@guezs)

    ok, this is the function making the misfunctionality:

    function add_events_to_rss_feed( $args ) {
    if ( isset( $args[‘feed’] ) && !isset( $args[‘post_type’] ) )
    $args[‘post_type’] = array(‘post’, ‘tribe_events’);
    $args[‘orderby’] = ‘date’;
    $args[‘post__not_in’] = array(737);
    return $args;
    }

    add_filter( ‘request’, ‘add_events_to_rss_feed’ );

    I’m using The Events Calendar and adding the events to the feed. If I comment the 2 first lines inside the if, the home page appears.

    // $args[‘post_type’] = array(‘post’, ‘tribe_events’);
    // $args[‘orderby’] = ‘date’;

    If I un-comment them, so they can work, the home page dissapears. What could it has to do with the home static page?

    Thread Starter guezs

    (@guezs)

    ok, got it… I copied it from an example code with just one line and added two more without the {} and guess it was causing a null pointer… I don’t know why that causes to not show static pages, but now seems to be working.

    Thank you

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Home page – static page dissapear’ is closed to new replies.