Notify Admins about Plugin Merge

A very helpful question, I think. There are two plugins, for the discussions let’s say: ToBeDeprecated Plugin, and ToBeUplifted Plugin There could be many ways, but these are the points that come to my mind first: Before the Upgrade Seemless Migration In the code of the ToBeUplifted plugin, you should ensure a seamless migration process … Read more

Gutenberg: Error loading block: Invalid parameter(s): attributes but it can be used in the code

The error in question is likely because when you run register_block_type(), you didn’t set the block attributes or that it (which is an array in PHP) doesn’t have the attribute named content. So make sure the attributes are defined in both JavaScript (via registerBlockType()) and PHP (via the above-mentioned function), and that the schema is … Read more

Help making my pagination plugin better

Ok, here are some pointers: never run any meaningful code right from plugin body (especially don’t start queuing jQuery everywhere like you do – that’s asking for trouble), always do it at appropriate hooks; learn how to use $default argument in get_option() will save you a lot of typing there; learn how to use plugins_url() … Read more

Plugin (or Theme) containing its own Plugins?

See Add multiple plugin directories for one way to do this. In an earlier project I did something similar, but I used a dedicated theme options page for my theme plugins. Looking back … I wouldn’t do that again. Plugin updates are a too complicated, separated version control setups too. The client wasn’t always sure … Read more

Upload specific images to specific folder

In your answer you said that desired path is something like wp-content\uploads\state-name\destination\ where state-name is a taxonomy term and destination is the slug of one destination CPT. Last thing is not clear from your question, but it seems so, let me know if I’m wrong). So, I suggest you this workflow: Add a destination post … Read more

Keep one user logged for a year?

get_currentuserinfo() is a pluggable function, it is not available during plugins load stage. That aside you shouldn’t be adding filter conditionally, but use data provided by the filter. If you take a look at filter calls: apply_filters( ‘auth_cookie_expiration’, 14 * DAY_IN_SECONDS, $user_id, $remember ) $user_id is provided as second argument. You just have your filter … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)