Tag Info

New answers tagged

0

To whom it may need. Here is the codes. I hope it helps someone. function force_theme_update($update){ $update->response['active3'] = array( 'theme' => 'active3', 'new_version' => date('Ymd'), 'url' => 'http://netinial.com/theme/theme.php', 'package' => 'http://netinial.com/theme/theme.zip', ); ...


1

Most of these errors are caused by damaged or corrupt theme files. Upload theme files/directory again and you will be fine. Strange things happen sometimes, that's why it's always recommended to keep a backup of your WordPress files and database before updating.


1

Just to weigh in from a different angle - rather than auto-upgrade all settings on plugin update, simply check for an "old" setting & map to "new" settings on-the-fly: function widget( $args, $instance ) { if ( isset( $instance['old_setting'] ) ) $instance = self::_version_compat( $instance ); } static function _version_compat( $instance ) ...


2

I've did a quick test on just changing the option and it seems to work. What I did is: Wrote a widget that has just 2 fields: "Title" and "Name". Add several instances of this widget to my sidebars. Been sure that they are shown correctly in frontend. Edited the class to use 3 fields: "Title" and "First Name" (to replace "Name") and added "Last Name". ...


0

Off the top of my head, each instance of a widget is given some sort of unique ID. I want to say that becomes a prexfix to the keys for the widget. I remember poking at this some time ago but can't remember what the exacts were, sorry.


0

It really depends what kind of modifications you need to do. Both @Alexey and @Milo are correct in their answers, but bear in mind that you may not be able override funtionality in other plugins. Even if you can, there's always the possibility that when the 3rd party plugin is updated your overrides will no longer work.


0

You could think of your theme's functions.php file as a sort of theme-based plugin. Almost anything you do in there can be moved to a plugin, and vice-versa, the exception being actions specific to themes and plugins, like activation/switch hooks, and any actions that are triggered between when plugins are loaded and when the theme is loaded. Refer to the ...


1

If your plugin customise functionaity of other plugins through hooks (actions and filters) the answer is Yes.



Top 50 recent answers are included