Monday, November 16, 2009

CSS is not working in FBML (backround image)

If you are going add any page on face book page using the FBML. There are some point that need to be noted before that.
your Content:
Shoud not contained the HTML tag.
Should not contained the BODY tag.
If you are using the background image then in that case don't use the partial URL(if you are using it through the CSS. like this background: url 'http://moveforfree.com/images/new_h1.gif' and background-image: url(bg.png);

You need to use absolute urls in your CSS (and also in other places like image tags) because partial urls will be interpreted as relative to apps.facebook.com/yourapp.

solution is this:
background-image:url(http://www.yourserver.com/yourappdir/bg.png);
Make sure there are no html style comments ( FireFox doesn't like those) and make sure you don't have any extra commas, semi-colons, or other markup that shouldn't be there.