Custom post type redirect. (2 posts)

  1. c0nc3pt.SF
    Posted 6 years ago #

    Greetings. I have 2 custom posts types. Whenever I update a post in one of those types I am redirected to the regular post section. The data saves with no problem but it is a bit annoying to constantly have to click back through to get back to the custom post type. Does anyone have any idea what the problem may be? Or is it just supposed to work like that?

  2. DeviousBlue
    Posted 5 years ago #

    I had this same problem tonight and was pulling my hair out for a couple hours. I started commenting out my code and noticed that this starts happening after I use mysql_connect() in my functions.php file.

    I read about mysql_connect() and apparently it always makes a new link to a db UNLESS the same user and pass word are used to connect!
    I realized I had wordpress system and my custom save_post methods using the same user/pass combo and this was messing it up.

    So created a new user for my custom save methods and it stopped happening.

    Hope this helps!

Topic Closed

This topic has been closed to new replies.

About this Topic