i would like put link after each widget in dynamic sidebar. I thinks is possible if i use static sidebar, but i don't found any tutorial for this.

Thanks you

migrated from stackoverflow.com Mar 3 '11 at 14:12

This question came from our site for professional and enthusiast programmers.

  • 1
    Welcome on the SO, we have SE Wordpress page for this kind of question wordpress.stackexchange.com – igor milla Mar 3 '11 at 13:53

If you useWidget Logic it adds a new filter


which you can hook your function to and add link to it somthing like:

function add_link_to_widgets($content){
   return $content . '<br /><a href="http://www.domain.com">my link</a>'


You are missing the point, the plugin is great if you want to use his ability to limit the display of widgets, Beside that it add a new filter.

so you can use that filter like i said to add your links, each widget has an id you can add the link based on that.

  • Thanks but what I put in field widget logic ? – IA.Design Mar 3 '11 at 15:56
  • Nothing unless you want to use the logic part of the widget logic – Bainternet Mar 3 '11 at 16:00
  • So I put "add_filter('widget_content','add_link_to_widgets'); function add_link_to_widgets($content){ return $content . '<br /><a href="domain.com">my link</a>' }" in functions.php and if i want unique link for each widget ? – IA.Design Mar 3 '11 at 16:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.