Title: Upade permalink structure from wp cli
Last modified: January 8, 2021

---

# Upade permalink structure from wp cli

 *  Resolved [k83uhse6v](https://wordpress.org/support/users/k83uhse6v/)
 * (@k83uhse6v)
 * [5 years, 5 months ago](https://wordpress.org/support/topic/upade-permalink-structure-from-wp-cli/)
 * Hi,
 * when I update the permalink structure from CLI, the Cache Enabler still says:
 * Cache Enabler requires a custom permalink structure. Please enable a custom structure
   in the Permalink Settings.
    -  This topic was modified 5 years, 5 months ago by [k83uhse6v](https://wordpress.org/support/users/k83uhse6v/).

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Anonymous User 16850768
 * (@anonymized-16850768)
 * [5 years, 5 months ago](https://wordpress.org/support/topic/upade-permalink-structure-from-wp-cli/#post-13882895)
 * Are your pages being cached? Does this still occur after a hard refresh of your
   page? Updating the permalink structure from the command line should trigger the
   [`permalink_structure_changed`](https://developer.wordpress.org/reference/hooks/permalink_structure_changed/)
   hook, which then triggers Cache Enabler updates to occur.
 * If your pages aren’t being cached and/or the warning is still shown afterward,
   can you please provide the exact command ran so I can replicate this issue to
   troubleshoot it further?
 *  Thread Starter [k83uhse6v](https://wordpress.org/support/users/k83uhse6v/)
 * (@k83uhse6v)
 * [5 years, 5 months ago](https://wordpress.org/support/topic/upade-permalink-structure-from-wp-cli/#post-13883310)
 * Pages are not cached. Yes, this still occur after a hard refresh of page.
 * I used this command, because I use Plesk:
 * plesk ext wp-toolkit –wp-cli -instance-id 1 — rewrite structure ‘/%postname%/’
 * The permalink structure has been changed correctly, but the plugin keeps showing
   the notification.
 * But you can try with the standard WP CLI command:
 * wp rewrite structure ‘/%postname%/’
 * [https://developer.wordpress.org/cli/commands/rewrite/structure/](https://developer.wordpress.org/cli/commands/rewrite/structure/)
 * Manual change from the WP admin panel of course solves the problem.
 *  Anonymous User 16850768
 * (@anonymized-16850768)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/upade-permalink-structure-from-wp-cli/#post-13893416)
 * I’m unable to replicate this issue. When in the Permalink Settings, if the permalink
   structure is set to Plain and the `wp rewrite structure '/%postname%/'` command
   is ran it triggers the `permalink_structure_changed` hook to be fired, which 
   triggers the `Cache_Enabler::update_backend()` method to be called.
 * Once the backend is updated the settings file is also updated. Please note that
   the `permalink_structure_changed` hook is only fired if the permalink structure
   has actually changed in the database. If the database didn’t require an update,
   like if the permalink structure wasn’t actually changed, then it won’t be fired.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Upade permalink structure from wp cli’ is closed to new replies.

 * ![](https://ps.w.org/cache-enabler/assets/icon.svg?rev=2442383)
 * [Cache Enabler](https://wordpress.org/plugins/cache-enabler/)
 * [Support Threads](https://wordpress.org/support/plugin/cache-enabler/)
 * [Active Topics](https://wordpress.org/support/plugin/cache-enabler/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/cache-enabler/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/cache-enabler/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: Anonymous User 16850768
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/upade-permalink-structure-from-wp-cli/#post-13893416)
 * Status: resolved