The first example you give works for me. If it's complaining about a
missing ")" then the error is elsewhere.

The second is indeed invalid JavaScript. This:

   background-position

Is the same as this:

   background - position

So you should either use quotes around the CSS property (like you
used) or use camelCase, like so:

   backgroundPosition

Karl Rudd

On 5/29/07, joomlafreak <[EMAIL PROTECTED]> wrote:

I have tried many ways but it seems this is not possible. The css
function does not allow me to use two values for background position
with a space between the values and gives an error that ")" is missing
when I use this

css("background-position","0 50%").

Even if  I use this
css({background-position,0 50%})

it does not work and gives an error.

Can someone please throw some light on this property and how can I use
it to manipulate the background image position. I want to use it for
css sprite kinda use for a single image of many small icon images.

thanks in advance.


Reply via email to