Hi,
everytime I try to use "list-style-image" to replace a list bullet point with an image, the whole style gets deleted by wordpress when I try to save the custom css. Is the CSS command "list-style-image" blocked by wordpress and if so, why?
tina
WordPress.com is an easy way to start blogging. Get a blog, check out our features, read the latest announcements, choose from great themes, or learn about the team behind it.
Need help? Check out our Support site, then
Hi,
everytime I try to use "list-style-image" to replace a list bullet point with an image, the whole style gets deleted by wordpress when I try to save the custom css. Is the CSS command "list-style-image" blocked by wordpress and if so, why?
tina
i can't think why wordpress would strip that out, i can't imagine that it's a security risk.
however, it's generally more reliable to do the following:
li {<br />
list-style-type: none;<br />
padding: 2px 2px 2px 8px;<br />
background: url(http://path.to/your/image.jpg) 0 50% no-repeat;<br />
}
exactly, thanks I'll try that and report back if it worked :)
Style tags are stripped for security reasons. That's how that MySpace worm got in. That's probably what is occuring here.
drmike -
did you fail to notice which forum we're in here?
he's talking about a specific style in
http://fitzel.wordpress.com/?css=css&rev=0
thanks sunburntkam - it worked, with just a small modification. Here is what I did:
<br />
#subcontent ul.categories li,#subcontent ul.months li {<br />
list-style-image:none;<br />
background:url('http://my.website.com/categories_yellow.gif') left no-repeat;<br />
margin:0;<br />
padding:0 0 0 18px;<br />
}
It strange though ... I can use list-style-image:none; but I cant use
list-style-image:url('url');
thanks for your help :) much appreciated
tina
did you fail to notice which forum we're in here?
Yes, I did and I already looked at the CSS file in question. No reason to be rude. Did you notice I said 'probably' in there?
I sent in a Feedback asking about the situation. I had thought it might be an oversite with the filters but if 'list-style-image:none;' is working...
hi drmike,
thanks for looking anyway! would be really interesting if you could find out why list-style-image seems to be blocked with a url ... well if you have time :)
Hi fitzel. Sorry about the problem! It's fixed now. I just tested with this lovely and flattering rule:
li { list-style-image: url(/favicon.ico); }
;-)
Hi Andy,
great - it works!
Thanks very much for the fix :)
resolved
This topic has been closed to new replies.