Hi folks, My first post on here so please be gentle :-)
Basically, I'm trying to insert a single character from the 'Modern Pictograms' font as a prefix to the title text of each widget in a sidebar. So, for example, latest tweets will have the little birdie in front of it, search the site will have a magnifying glass, you get the idea.
The easy way to do this would have been to stick a div with an id in the title text for each widget via the Wordpress control panel but it doesn't seem to want to let me do this (you click save and the html disappears).
I've burrowed deeper down and am now looking at register_sidebar. Ideally, I'd simply include a simple conditional statement at the start of the /new_widget_init()/ function which would have a string called $icon or something similar which could then be defined based on what widget it is and then it's simply a case of including something along the lines of: "/<div id="pic">' . $icon . '</div>/" in 'before_title'.
My question is:
1. Am I missing something bloody obvious here which is going to make me go 'doh!' when someone points it out (I don;t think I am but fairly new to wp)
2. Failing that, does anyone know if it's possible to circumvent the above by somehow getting widget title fields to accept html (ie the div with id) in the title text field?
3. Failing that. does anyone know how I reference an individual widget via the PHP? I tried "if (/$widget-id == "search-2"/)" but that doesn;t seem to be going anywhere.
Many thanks
R