A plugin that adds that ability to insert any PHP code into a sidebar widget.
The text widget that comes with the wordpress does not allow you to include PHP code. This plugin adds a new widget called
Samsarin PHP Widget, which will allow you to include PHP code, as well as plain text and HTML.
Samsarin PHP Widgetsto your sidebar.
Warning: This widget provides great flexibility in customizing your sidebar. It achieves this by automatically evaluating any included PHP included in the title or the body of the widget. Care should be taken when including PHP code in the sidebar, as with anywhere else in the WordPress system.