• Resolved setevoy

    (@setevoy)


    Hi.

    I’m trying to move to the PHP-7 (7.2, 7.3) from PHP-5.6 and faced with really weird behavior.

    The problem is:

    – I’m creating a new post, let’s say called “test1”
    – after going back to the Posts dashboard – I can’t see this new post until I’m pressing F5
    – then I’m going to the “Add new post”, and creating a new post, let’s say called “test2”
    – going back to the Posts dashboard – and still seeing the “test1” one
    – after pressing F5 again – I can see “test2” – but “test1” disappears

    What’s interesting – they all stored under the same ID, i.e. “post.php?post=17988“.

    This also happens with a fresh WP install on this Dev environment.
    error_reporting = E_ALL, display_errors = On and log_errors = On – but nothing in UI or logs.

    Anybody had similar issues?
    I believe this happens because of PHP version but not sure.
    Will try to add PHP-5 and test it.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi,

    Can you try adding new post after switching the theme? Also, clear your browser cache after switching the theme.

    Thread Starter setevoy

    (@setevoy)

    Yeah, that looks like caching issue, @emmtoor.
    Found this after opened WP in another browser: after adding a new post from it, let’s say “test3” – I saw previously added “test2” + “test3”. After adding “test4” – I saw “test2” and “test4”.
    And yes – after cleaning browser’s cache – it works now.
    I’m trying to find why that happens… I did some changes with NGINX’s configuration and trying to roll-back them one by one to find where the root cause was.
    Although – after cleaning browser’s cache looks like it works anyway.

    P.S. Even more: after I cleaned cache in my _first_ browser – I got all my test posts added before 😀

    • This reply was modified 6 years, 5 months ago by setevoy.

    Awesome! glad to head that your problem is resolved 🙂

    Thread Starter setevoy

    (@setevoy)

    Well, I’m still interested in the root cause… Did it happen because of changing NGINX’s settings? Or just a “bug” in browsers?
    Looks like it was something in NGINX as it affected two different browsers – Chromium and Opera (on Linux).

    But anyway – will mark this topic as Resolved.
    Thank you for confirming my guess about cache 🙂

    You’re welcome!

    If you recently installed any caching plugin or cache extenstion in NGINX then that may be causing this.

    • This reply was modified 6 years, 5 months ago by Maninder.
    Thread Starter setevoy

    (@setevoy)

    OK, it was the expires max; option in the nginx.conf – added it into the server {} block during “performance tuning” attempt.
    Removed it, cleaned cache again – and looks like all works now.
    Instead – need to set it to the images location block:

        location ~* \.(jpg|swf|jpeg|gif|png|css|js|ico)$ {
            root {{ web_data_root_prefix }}/{{ item.0.name }}/{{ item.1 }};
            expires 24h;
        }

    (this is part of my Ansible template)

    • This reply was modified 6 years, 5 months ago by setevoy.
    • This reply was modified 6 years, 5 months ago by setevoy.
    • This reply was modified 6 years, 5 months ago by setevoy.
    • This reply was modified 6 years, 5 months ago by setevoy.

    Awesome!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Post created overwrites previous one’ is closed to new replies.