Skip Navigation

[Resolved] Unable to update template when Custom Permalinks plugin is enabled

This support ticket is created 3 years, 6 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

This topic contains 3 replies, has 2 voices.

Last updated by beingk 3 years, 6 months ago.

Assisted by: Waqar.

Author
Posts
#2068243

Hello,

I am trying to use Custom Permalinks (tried Permalinks Customizer plugin too) for Toolset CPT content I've imported. It all seems to be working fine until I try to edit a template for a CPT and I'm stuck with Saving/Updating the template. I've already gone through the debugging process of installing/uninstalling plugins and determined that it's the 2 Permalinks modules (tested separately) that are causing the issue.

Just to reiterate, the plugin(s) seem to be working fine together with Toolset when I edit and publish posts. It's only when I try to save/update a template when the process hangs. Is this a known compatibility issue?

Thank you.

#2068861

Hi,

Thank you for contacting us and I'd be happy to assist.

During testing on my website, I was able to reproduce this issue.

When the ‘Custom Permalinks’ plugin (https://wordpress.org/plugins/custom-permalinks/) is active, the content template edit screen appears to be stuck when it is updated. The actual changes made to the template are saved correctly, however, the AJAX spinner keeps on spinning.

I've shared these findings with the concerned team for further review and will keep you updated through this ticket.

regards,
Waqar

#2072207

Thank you for waiting.

I've received an update and using the following code snippet, you can stop the 'Custom Permalinks’ plugin's script file from loading on the content template edit screen:


/**
 * Dequeue custom_permalinks script when editing Toolset Content Template
 */
add_action( 'current_screen', 'ts_current_screen' );
function ts_current_screen( $screen ){
    if ( in_array( $screen->post_type, array( 'view-template' ) ) )
    {
        add_action( 'admin_print_footer_scripts', 'ts_dequeue_custom_permalinks_assets', 1 );
    }
}
 
function ts_dequeue_custom_permalinks_assets(){
    wp_dequeue_script( 'custom-permalinks-form' );
}

Note: The above code snippet can be included through either Toolset's custom code feature ( ref: https://toolset.com/documentation/adding-custom-code/using-toolset-to-add-custom-code/ ) or through the active theme's "functions.php" file.

I hope this helps and please let me know how it goes.

#2072359

My issue is resolved now. Thank you!