Tagged Questions
6
votes
2answers
1k views
Update widget form after drag-and-drop (WP save bug)
I've posted a bug-report about this a few months ago (on WordPress trac (Widget Instance Form Update Bug)) and I thought I'd try writing about it here too. Maybe someone has a better solution to this ...
3
votes
1answer
736 views
Get the sidebar ID in which the current widget was dropped
How can I find out in which sidebar was a widget dropped? From inside that widget. More precisely from the form() function.
Can I automatically remove the widget if it's not added in the appropriate ...
2
votes
1answer
238 views
Count widgets of a certain type
How can I get the number (count) of, let's say, text widgets from a sidebar?
for eg. if I drop 4 text widgets in the sidebar, I want to get this number somehow from another widget
2
votes
2answers
449 views
Is There A Hook To Process The Content Of The Text Widget?
Is there any filter which can be used in a plugin to process the content of the text widget before it is rendered?
2
votes
1answer
283 views
Schedule cron event from widget
Can I use wp_schedule_event() to set up a cron job from within a widget?
I tried, but I can't make it work, The problem seems to be the $hook parameter. The function I'm trying to hook is located ...
1
vote
1answer
62 views
Do widget options need to be escaped widget()?
I was wondering if you really need to escape user submitted data (widget option fields) within the widget() and form() functions (from the widget class) ?
I don't see a reason to do this, if the data ...
5
votes
2answers
1k views
What is the quickest way to make a widget?
I have some PHP code that I would like to pull out of an existing page of a template, and put into a widget so I can move it around.
What is the quickest way to create a widget?
1
vote
4answers
578 views
How Can A Widget With Only One Instance Be Defined?
How can a widget which of which only one instance can be used?
1
vote
1answer
432 views
Widget Javascript code (ajax)
I have a widget like this:
class test_widget extends WP_Widget{
function test_widget(){
$widget_ops = array('description' => 'test widget');
$this->WP_Widget(false, 'Test', ...
1
vote
1answer
273 views
How did I enable atom feeds in a fresh WP3 install?
I've just install Wordpress 3, and I can't figure out how to put an atom link in the sidebar, under (or otherwise near) the RSS links. I looked at sidebar.php, but it simply references a meta ...
1
vote
3answers
7k views
How do register_sidebar() and get_sidebar() work together?
Disclaimer: I am brand spanking new to WP.
I am using the Starkers HTML5 framework theme. In the functions.php I see this code:
function starkers_widgets_init() {
// Area 1, located at the top ...