The problem is your update function. $old_instance is kind of special variable. The simplest is
function update($new_instance, $old_instance) {
return $new_instance;
}
For the safe
function update($new_instance, $old_instance) {
$instance = array();
$instance['name'] = htmlentities($new_instance['name']);
$instance['divclass'] = htmlentities($new_instance['divclass']);
$instance['paypal'] = htmlentities($new_instance['paypal']);
return $instance;
}
Related Posts:
- Conditionally enqueue a widget’s script/stylesheet in HEAD (only when present on page!)
- Plugin upgrading: Widget settings
- How can I make my custom shortcode work in a Custom HTML Widget?
- How to pass JavaScript variable to PHP in wordpress widget?
- Is dynamic forms/entries possible in Widget?
- How do I add a widget programmatically to a newly created site (WPMU) within a plugin?
- WordPress widget / plugin….fields not appearing in my widget
- Created Widget Not Showing up on Admin Panel
- How do I register a stylesheet inside a WordPress widget?
- Detect if a plugin was included in a certain page
- Passing $this->get_field_name() to javascript
- Can I use a form in a dashboard widget?
- Ajax gives 400 error
- Archive – same title for the first two posts
- Ajax contact form widget plugin data not insert in database
- WordPress Widget – Saving multidimensional arrays into $instance
- Widget’s container?
- strange shortcode error: does shortcodes requires any dependency?
- How to set the default value as the saved value once a form of widget is saved?
- My widget won’t update its values when save is clicked
- How to add captcha to publish widget
- Table of contents (TOC) plugin is not showing header tag
- Widgets are not displaying in the admin panel
- The styles in the recent posts widgets plugin not working
- Using foreach loop for `$instance` of form and update array widget iteration
- One time call to external API in widget
- Widget outputs the value but doesn’t save anything inside the textarea
- WordPress Widget: Is it possible to make the form dynamic without updating?
- Plugin Works, but Widget Doesn’t
- Widget Script Loads at Bottom of Page
- Widget redirecting to home page
- WordPress plugin not eching popular posts
- What are the downsides of using bootstrap in plugin development?
- What can I do to customize a widget provided with this plugin? from where have I to start?
- dbDelta only creates the last table
- How can I make it so the Add New Post page has Visibility set to Private by default?
- Is There A Hook To Process The Content Of The Text Widget?
- How does WordPress handle MySQL row lock errors?
- Sync my svn repositories
- Override plugin localization
- When do I need to use esc_attr when using WordPress internal functions
- Where should my plugin POST to?
- How to list the Hooks and order of execution in current loading page? [duplicate]
- Get all options saved by another plugin
- How to bulk send emails
- I need some direction on how to have a sidebar based on meta rather than page
- How to get the permalink of a page when loading my plugin
- The Point of Using apply_filters()
- WordPress Plugin Page is Loading in Admin Content Container Instead of Separate Page
- Serialize data for wp options
- Is Wrapping intval() Around esc_attr() Redundant for Escaping Input?
- React JSX in WordPress Plugin Development
- My plugin wants to update another plugin
- Plugin Options Not Saving to Database in WP 4.5
- Using SVN to upload plugin created with gutenberg blocks
- Force quit running background job
- How to make WordPress customizable for clients
- Conditional tag in Widget Logic for checking if top level page or if subpage
- Unable to delete custom post types, confusion around capabilities
- Getting wp.me shortlink for wordpress custom post type
- where is the main file in this plugin?
- Insert Array in Plugin Database
- Problem since update 3.5 [duplicate]
- plugin wraps the entire content
- Shortcode Attributes to Return different $_POST
- Plugin onclick button activate other plugin
- How programatically cause uploads folder to be created?
- Issue with wp_handle_upload
- Different registration form for different roles
- WordPress Post HTML after Posting
- How to append new form elements in “Add New” form of Users in WordPress admin panel?
- Settings options not showing up on Sub Menu page in WordPress plugin
- My plugin does not install correctly if a previous version is still installed
- unregister a sidebar widget
- Why aren’t my Follow Me links working?
- Could add_query_arg() redirect user to external site?
- How to solve conflict with scripts?
- wp_insert_post not inserting post from XML
- The Build menu theme is frozen with the wordpress theme
- Access “wp site health info” data from plugin
- WordPress Frontend Page using Plugin
- How to prevent redoing get_posts queries and make results available to other scripts?
- Prefix WordPress Taxonomy Tags With Hashtag Symbol Like Twitter
- Change Woo Custom Endpoint Titles from a Plugin
- Using slightly modified widget
- Get input form data posted by users
- wp_verify_nonce fails always
- Custom Plugin: Point to `template_directory`
- WP internationalization not loaded
- Plugin options not appearing on options page using tabbed navigation
- Adding custom cron_schedule prior to wp_schedule_event
- Create plugin with form in post and submit it to specific form
- Storing values in Post Meta vs new tables
- Capturing POST data
- map urls to plugins
- Why is my menu page not being displayed?
- manage_{taxonomy}_custom_column not working
- How to be Variables and options must be escaped when echo’d?
- Mixed results with is_page() WordPress function, when using $this, or self
- I have created a custom plugin. After activation it creating page but i am not getting how to add another php file at page content?