The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

Need to find code for 2 of the default widgets (3 posts)

  1. dv-design
    Posted 6 years ago #


    I want to create a widget based on 2 of the default widgets; tabbed siderbar, featured sotries. I know how (or have a basic template) for creating a custom widget, the problem is that i want to use segments of code from each of the default widgets to create a kind of hybrid, however i cant find the code for individual widgets.

    I have found the file /wp-includes/widgets.php. Is this where individual default widget code is, or does this just call other files for each widget?

    Any help would be great, thanks.

  2. dv-design
    Posted 6 years ago #

    Found my answer.


  3. Dan Cole
    Posted 6 years ago #

    The default widgets are defined in ../wp-includes/default-widgets.php

    ../wp-includes/widgets.php includes code that loads widgets from different sources (plugins, themes, and core), integrates them into WordPress, and allows them to function.

    The widgets you have named are not default widgets to my knowledge. They were most likely added by a plugin or theme that is currently activated on your WordPress install.

    Edit: Too slow at posting.

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.