• Resolved Dheeraj Singh

    (@dheeraj-singh)


    Hi,

    Permalink manager is not automatically working when we use a form plugin to create posts. We are using rehub’s RH frontend publishing pro.

    Thanks

    • This topic was modified 4 months, 2 weeks ago by Dheeraj Singh.
Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Maciej Bis

    (@mbis)

    Hi,

    Could you check if any permalink is appended to the custom permalinks array in the debug section?

    Also, please check if the permalink editor is displayed for that specific user:
    https://permalinkmanager.pro/docs/basics/uri-editor/#how-to-edit-custom-permalinks

    If not, you can change the allowed user role in “Settings -> Advanced settings -> URI Editor role capability“.

    Thread Starter Dheeraj Singh

    (@dheeraj-singh)

    Hi.

    Actually the form we are using for creating the post is the issue. We are using Rehub RH frontend pro and any posts created through that form are not setting the permalink correctly. If i go and resave the post from admin panel then the permalink is updated correctly.

    Plugin Author Maciej Bis

    (@mbis)

    Unfortunately, I do not have access to Rehub RH code and that theme is not officially supported by Permalink Manager. Theoretically, you can try to force saving the custom permalink using extra code snippet:

    function pm_set_custom_permalink( $data ) {
    if ( ! empty( $data['post_id'] ) && is_numeric( $data['post_id'] ) ) {
    $new_uri = Permalink_Manager_URI_Functions_Post::get_default_post_uri( $data['post_id'] );
    Permalink_Manager_URI_Functions::save_single_uri( $data['post_id'], $new_uri, false, true );
    }
    }
    add_action( 'wpfepp_form_actions', 'pm_set_custom_permalink', 999 );
    Thread Starter Dheeraj Singh

    (@dheeraj-singh)

    Thanks. This resolved it.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.