Your code looks much better and all your bugs are fixed :-). (Caveat: I did not go through your code line by line, just quickly tested it though)
There are however two problems left that you’ve missed, and that all come from when you’ve renamed your widget
-
register_widget( 'header_slide' );
should beregister_widget( 'Header_Slide' );
-
the_widget( 'header_slide');
should bethe_widget( 'Header_Slide');
Please see the_widget()
and how it is used. Just for example, the following
the_widget( 'Header_Slide', 'headline1=HEADLINE1&blurb1=BLURB1');
will output
HEADLINE1
BLURB1
I would however not use the_widget()
to display a widget, I would rather create a sidebar and then drop my widget in there.
You can register a sidebar conditionally for a specific page of template
Related Posts:
- How can I use the built in WordPress “browse link” functionality?
- Code for Recent Posts Widget
- Prevent widgets removal
- Is there a way to add more tags to the tag cloud?
- Modify recent post sidebar to show post thumbs with out plugins
- Why Can’t wp_editor Be Used in a Custom Widget?
- How to listen to color changes on the color picker?
- Add New Footer Widget Area with Limited Options?
- Disable default WordPress widgets in sidebar
- Updating to Version 4.5 bumped my “main sidebar” widget out of place
- How can I delete all inactive widgets?
- Call sidebar from a template
- Adding classes to dynamic sidebar
- Widget Area: Modify $param[‘xy’] from widget-$n
- Need help adding additional controls to a custom widget
- Why do none of my widgets have a title?
- Widget area inside a widget
- How to limit wp_get_archives to show months for the X years only
- Bolding specific word(s)/parts of widget title
- Adding a widget to a string of HTML
- Pass variables from one widget to another widget
- Remove the widgets tab from theme customizer
- Check if widget is active
- Radio buttons in widget not saving
- How can I apply css styling to the current day in the calendar widget
- AJAX Contact Form Issue
- Including PHP files doesn’t work outside of Localhost
- Is there an official email form widget or block?
- Widget html code error
- Display sidebar only if it has content
- Post-specific widgets in WordPress ‘Twenty Fourteen’ theme
- Can WordPress Read Its Own RSS Feed?
- Display custom widget, added as a shortcode in the correct place
- Debug errors on sidebar
- Dynamic sidebar based on category
- Show posts from one category with thumbnail and description on latest
- Show widget differently depending on if it’s in the sidebar or footer
- Get posts after today (upcoming events)
- How to pass data from page to widget functions?
- Adding a rich text editor to a widget – specifically CKEditor
- Enqueue script/style if certain widget has certain value
- How to display/register widget only on post pages in custom plugin
- Is it possible to display tag cloud widget by category?
- Widgets not saving values
- Widget page is missing from menu and default widgets are not showing
- wp_editor in widget breaks after save (no buttons and visual tab broken)
- How to use a dropdown to populate a list of post from CPT
- Fire on widgets_init only on dashboard
- Access Customizer widget instance form
- Registering a stylesheet inside my WordPress widget
- is_tax() not working in Widget Logic [closed]
- How to position custom dashboard widgets on side column
- WordPress widget title coding
- Text Widget in Footer for just 1 page template
- How to change color of registered widget areas in admin?
- Filter Text from sidebar widget?
- How to filter widget(s) based on a specific category landing page
- How do I remove/reset all current widgets from the database?
- Search transients through widget
- what is the difference between these two types of widget form method
- Change the background color of my theme widgets
- Change Woocommerce Product Categories Widget ‘Title’ based on Product Category
- Output column number according to active sidebars
- Why isn’t my custom widget outputting any content?
- Make single widget area top level in 4.0 Customize Panel
- Instance not inserting data for widget
- Why would apply_filters return a non-empty string, when the value returned is empty?
- Sidebar widgets – dynamic CSS : problem with widget-title
- widget not displayed
- Dynamically creating multiple widgets from Mustache templates
- How to customize wordpress sidebar widget
- changing the style of sidebar
- Vimeo Feed gived dead link with RSS widget?
- Preset Widgets ONLY after site is initially created
- How to translate widget titles in 2021 theme?
- Is it possible to add a preview to custom developed Widget?
- How to enable [archives] short code
- Where does the removing of widget through appearance – customize take affect
- Widget editing returns JSON response error
- Allow users to give a dashboard widget a custom name using ACF
- How to change widget title in wordpress version 5.8.1?
- why the code html apear in this widget in footer
- Why does my $instance within a custom widget return empty (undefined index)?
- A checkbox Option for description in Widget
- My widgets do not save
- How to move widget area to another section in WordPress Customizer
- I cannot customize custom widgets anymore after moving WordPress website
- Remove default WordPress widgets
- widget that will do shortcodes that user inputs
- How to show widget in frontend?
- Widget Development – Displaying dropdown content
- WordPress function breaks widget’s markup?
- Registering multiple copies of a widget
- page url in shortcode
- iframe/embed vid in text widget loads outside container and moves around when scrolling the page?
- menu in different page in different style
- Add text to Text Widget using Javascript
- Widget logic not working
- Subpages menu on sidebar plus widgets
- getBlockVariations(…) is undefined in Widget and Template Part editors but not Post Editor