Widgets are configurable elements used to dynamically build sections of a WordPress theme.

learn more… | top users | synonyms (2)

1
vote
1answer
13 views

Add before_content and after_content to register_sidebar

Is there any way to add two new functions, before_content and after_content to the register_sidebar function? These would work like before_title and after_title, except it would wrap everything that ...
1
vote
0answers
7 views

Save/update widget outside admin panel

Is there some way to update/save widget from page - not from admin ? I create widget with charts and do not know how to update it from sidebar. I found of course form in admin: <form action="" ...
0
votes
0answers
1 view

feedjit plugin in not update in real time [on hold]

I have been using Feedjit plugin to monitor my website visitor but from past few days it is not not updating the live traffic in real time. To see the traffic I need to refresh the page please help.
0
votes
1answer
9 views

Downloading Generated XML File

I'm making a Widget which presents users with categories as drop down list. When user selects category and press download, I want to get all posts under category and download them. I have faced a ...
0
votes
0answers
9 views

Displaying a widget with custom taxonomies

I'm trying to display a widget that would pull all the information from custom taxonomies for the relevant post, like this: http://www.onlinecasinos.fm/reviews/bet365-casino In that example, on the ...
2
votes
0answers
26 views

How to make a widget expand wider than the column width when editing its settings in the admin

The WordPress Text widget expands horizontally beyond the margin of the sidebar when added to a sidebar and opened in the admin and I am trying to apply that function to a widget. I see inline css is ...
0
votes
0answers
15 views

Post List Widget with custom posts and editing the Read More Link

I actually have 2 questions, one related to the Post List Widget, the other concerns the "Read More"-link. ad 1) I want to show a certain category of posts (only one post at a time) in this widget. I ...
2
votes
1answer
25 views

How can I delete all inactive widgets?

I want to cleanup all inactive widgets. I tried following snippet as suggested by this answer Script to remove all inactive widgets?. $sidebars_widgets = get_option( 'sidebars_widgets' ); ...
0
votes
1answer
13 views

How to allow editing of text in sidebar?

I am developing a theme which has an area of the sidebar which displays the blog owner's bio and photo as a background image. I could hard-code this information, however, I'd like to learn how to make ...
0
votes
0answers
12 views

Multilingual multisite > customisable footer across different sites with widgets?

I'd like to keep the structure of the footer similar across all sites using the same Theme. However, each site would need different content in their footer. Here's a concrete example - for Site A: ...
0
votes
0answers
64 views

Showing a Thickbox (tb_show) does nothing

I'm trying to add a media uploader to a widget/plugin and I'm at the stage where I need to add a picture from the media library (or upload a new one). I added some javascript and added an event to a ...
0
votes
1answer
20 views

Are widget arguments always set inside My_Widget::widget()?

Specifically, are the before_widget, after_widget, before_title and before_title array keys always set inside My_Widget::widget()? I'm wondering if statements such as the following are necessary ...
0
votes
1answer
11 views

How to get data from one wordpress site to another

I have the following sites: 1. Community News site 2. Classifieds site 3. Coupon Site Is there any way I can get data from my classifieds and coupon site on my community news site....like in the ...
0
votes
0answers
11 views

Can't seem to make display:flex work, so that the 3 divs are the same height [migrated]

I need to make sure that my 3 footer widgets are the same height, even if the site user decides to put more content in one of the widgets, so that they adjust in height. I understand using display: ...
0
votes
0answers
18 views

do_action inside of onclick

I'm brand new with making plugins/widgets, and am probably pretty limited to basic in knowledge with php as well. I want to be able to register a function that runs when a button is clicked. The ...
0
votes
1answer
18 views

Widget Script Loads at Bottom of Page

I've been working on a plugin that adds a script to the sidebar when activated. So far, I've been able to display the code, but it loads at the bottom of the page and not in the sidebar. I'm pretty ...
0
votes
1answer
30 views

widgets not working

I pasted my siderbar widget code in widgets.php file function right_sidebar_widget() { register_sidebar( array( 'name' => 'Right Siderbar', 'id' => 'right-siderbar', ...
0
votes
1answer
37 views

How do I get shortcode, widget and template tag CSS to load in the head only as required? [duplicate]

I have a shortcode, widget and template tag that need to load CSS. I am registering in init, and enqueueing as required. The only problem is, it is adding the CSS loader at the bottom of the page, ...
0
votes
0answers
11 views

Retrieve the real time widget area class

I'm trying to retrieve programmatically the sidebars classes in my developed pluging. I use the global $GLOBALS['wp_registered_sidebars'][1] and try to access the 4th element(class) in the array but I ...
1
vote
1answer
18 views

WordPress widget / plugin…fields not appearing in my widget

Trying to create my first plugin. A simple one. It's doing mainly what I want to do except the widget itself in Appearance-->Widgets doesn't display my fields. Wondering if anyone could point me in ...
-1
votes
0answers
21 views

How do I add testimonial image to testimonial widget for Spacious theme?

I have a website with the Spacious Wordpress them installed on it. The website is www.PlanetReputation.com. At the bottom of the homepage you can see some testimonials that I have added using the ...
0
votes
0answers
13 views

Show widget location borders for development

I'm taking over a wordpress site, whose template has a high number of widget locations in the appearance section. Is there a way to temporarily turn on the widget location borders so I know where ...
0
votes
0answers
19 views

add_filter('body_class') running from widget even when widget is not loaded on page/post

This should be adding a function to init() to check if the widget is active widget on the front end on a page/post - but even when the widget is not loaded on a page/post, .Widget_FilterProject is ...
0
votes
0answers
13 views

Add TinyMCE to WordPress default text Widget

Wonder if there is any way to add the TinyMCE (limited options) to the textarea of a default "Text Widget" in WordPress, Is there any way to do that ? There are few plugins to do the same kind of ...
0
votes
0answers
9 views

Hide/show radio buttons stop working on save

everyone! Here's my case. I'm developing a little widget, and I was looking for a way to hide/show different DIVs on selecting a set of radio buttons. I found the proper code and adjusted it to my ...
3
votes
1answer
46 views

How to use wp_dequeue_style() for style enqueued in WP_Widget class

I've got a plugin that makes a widget that enqueues some front-end CSS to style the widdget. I call wp_enqueue_style from the public widget() method in the extended WP_Widget class: <?php class ...
0
votes
0answers
23 views

Wordpress Widget Administration Javascripts do not work?

I have been working on a widget in WP 4.1.1 and cant seem to even get simple javascript to function on the backend unless WP is put into Enable Accessibility Mode. For example in your Form($instance) ...
0
votes
1answer
17 views

Cannot access variables within a widget

I'm currently learning PHP and Wordpress development from a Java background at the moment. How do I access variables in public function Example_Widget() from public function widget( $args, $instance ...
0
votes
1answer
26 views

Can't save widget

I can't save widget. When I click save, I can see wait circle, and nothing happend. When I visit again widgets section, it's empty. Then I changed view to Accessibility Mode, and still no luck. Then ...
0
votes
1answer
12 views

Display custom widget, added as a shortcode in the correct place

I've created a custom Widget and I would like to add it to the page content as a shortcode. function show_custom_widget() { the_widget( 'WP_Custom_Plugin'); } add_shortcode('custom-widget', ...
2
votes
2answers
93 views

Displaying Widgets

During theme development, I understand how to create basic widgets within the functions.php file. However, when it comes to displaying the widget within a theme, is there a preferred way to display ...
0
votes
1answer
12 views

Editor Widget Role

i need to give to editor role the access on widget (or if possibile on a specific widget). I use the code on this question and function but i have a problem. The editor can see the widget and also ...
0
votes
1answer
17 views

How to activate or install the Gallery Widget?

I would like to activate the Gallery Widget which is presented here. It seems that it's part of the general Wordpress distribution but the widget is not listed under Appearance → Widgets. BTW, I don't ...
1
vote
0answers
23 views

Limit number of widgets in widget area

I used code to limit each widgets area to one widget only. It works great: It uses JavaScript to do so, using the fact that the dashboard’s widgetized areas all use the jQuery UI Sortable library, and ...
0
votes
1answer
40 views

Remove the widgets tab from theme customizer

In some of our sites, I would like the site admins to customize the widgets only on the widget page, and not in the Theme Customizer. How can I remove the widget tab from there?
0
votes
1answer
22 views

I cannot customize custom widgets anymore after moving WordPress website

Originally posted here. The situation is the following one: A colleague of mine built a WordPress theme with some custom widgets which need to be configured through /wp-admin/widgets.php. In the ...
1
vote
0answers
32 views

Access Customizer widget instance form

On the WordPress admin widgets page there is a known issue with the widget form not being available the first time a widget is added to a widget area. This can be seen in this trac ticket here: ...
1
vote
0answers
20 views

Override Widget class in plugins with custom plugin

I am currently modifying a purchased theme for a client that has several required plugins for it to work. One of the required plugins, creates a widget that displays a post type and client would like ...
0
votes
0answers
12 views

How know the “admin” blog from wordpress multisite?

I'm try to construtc a multisite plugin and when I've the multisite list with all the blogs, I need to remove from this list the "admin" wordpress multisite. For example: I've the multisites 'ids' ...
0
votes
0answers
11 views

image carousel widget

Is there tutorial how to build widget where you can upload multiple images? I was trying to look some tutorials on widgets but to my surprise there are only few online. Or then my googling skills are ...
0
votes
0answers
17 views

PHP Wordpress Monthly Top Author in Sidebar

Im trying to show List of Top Author by Property Update Count (Monthly) in my sidebar. How to adjust this php code. This php only show AUTHOR list in my sidebar, not sort it by Monthly Property Update ...
0
votes
1answer
43 views

I want to create a posts widget and be able to select categories

Can you please tell me how can I create a wordpress posts widget that outputs posts based on a categories selection ( category checkboxes of all the post categories ) This is in my form function: ...
0
votes
1answer
25 views

How should I add a “widget” like element?

I would like to add a custom slideshow like "template" which can be called in to other template files. My first thought was to create exactly that; a separate slideshow.php template file which ...
0
votes
0answers
19 views

How to display comments with recent comments default widget?

I would like to create custom widget from the default Recent Comments widget to show also the comment content of commenter. How can I do it? class YOUR NEW WIDGET NAME extends WP_Widget { // ...
0
votes
1answer
36 views

How to add a text widget on the posts admin page?

I need to add a text widget on the posts admin page ie, the post editor page. so that I can add some code in the text widget for some purposes. Right now I have used text widget and this can only be ...
0
votes
0answers
6 views

How do I default the widgets in my dynamic sidebars? [duplicate]

Similar to a previous question that was not technically answered: I have a custom theme with dynamic sidebars and custom widgets. I would like to set what widgets are in those sidebars by default. ...
0
votes
0answers
20 views

creating widget of rotating testimonials

Using this article, http://www.wpbeginner.com/wp-tutorials/how-to-add-rotating-testimonials-in-wordpress/ I converted entire code into widget. In widget creation, I have used title option only. Also ...
0
votes
1answer
23 views

Why isn't a list of posts from my custom post type displaying in this widget?

I have a custom post type called 'blog' . I wish to show a selected number of posts from this custom post type in a widget. But all I get is 'No listing found,' which is the else statements if no ...
0
votes
1answer
22 views

Shortcode into widget

I have this particular shortcode "[example]" I know I can put this in a text widget to make it work. But I was wondering about how I can turn this into a widget called "Example." Any suggestion? ...
0
votes
1answer
56 views

Can I have a widget and sidebars in custom theme?

Wordpress 4.1.1: simular problem to another question: I have a add_action widgets_init call back in which I have a call to register_widget that registers a class and a call to register_sidebar that ...