I am trying to add the height of some elements based on a variable. I thought it was the right approach, but it is going to break my javascript.
$ ('# content'). CSS ('height': '+ = variableable'); It seems that there are so many different approaches, I'm not sure what's right. I know that generally, at least for JSON, everything should be around it. Although I believe for primitive values, you can leave quotation marks, but in the end, I would like to be guided in the direction of a guide which reflects the best practice of syntax. Obviously I found it wrong.
Thank you.
If my calculation is something wrong, then it is here. It is not that the adjustment (width of the browser window / 960px) is the difference between my container height (540px) after the lower browser window height should generate a value.
on addHeight = windowH - (540 * (windowW / (960)); I've added another line of my code because I think the way I'm ordering this zoom effect to add more audiences might be breaking the result? Maybe not though. Not sure it is important.
else {$ ('# wrapper'). CSS ({'zoom': windowW / (960)}); $ ('# Content'). CSS ('height': '+ =' VariableX); }
I will manage increments beyond JQuery call: < Pre> var VariableX = $ ('# content'). Height (); VariableX + = 1; . $ ('# Content') height (VariableX);
No comments:
Post a Comment