wordpress-hum icon indicating copy to clipboard operation
wordpress-hum copied to clipboard

Rewrite rules not flushed when adding custom types to custom plugin

Open jimkleiber opened this issue 1 year ago • 1 comments

I have been trying to add custom types and it was working when I had a custom redirect to something like q under i/q/ but not when I was adding it just as /q/.

I found that the rewrite rules weren't being flushed when I updated my custom plugin, only when I activated/deactivated the hum plugin. Once I did that, my custom types were working properly.

Maybe a dumb question, but any suggestions on how I can call the flush_rewrite_rules method from my custom plugin?

jimkleiber avatar Apr 10 '24 21:04 jimkleiber

We use the register_activation_hook for that https://github.com/willnorris/wordpress-hum/blob/3dd7e5db821ba05d834498dc5855a7ed6e1e0b34/hum.php#L21

pfefferle avatar Apr 11 '24 08:04 pfefferle

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 09 '24 12:08 stale[bot]