Reputation: 477
I want to set the value:
translate(-50%, -50%) translate(-100px, -300px);
to transform css property of div tag.
I use the next command:
jQuery('.content').css('transform', 'translate(-50%, -50%) translate(-100px, -300px);');
But I see nothing changes. How can I set that?
Upvotes: 0
Views: 723
Reputation: 989
In your jQuery code there is a semicolon ;
at the end of translate(-50%, -50%) translate(-100px, -300px);
which prevents jQuery from using the code. Remove it and it will work.
Upvotes: 3