[jQuery] Attribute Selectors

[jQuery] Attribute Selectors


I have the following code.
var newsCookie = readCookie('newsTabCk');
var tabId = $("#tabPanel2 ul li a[onclick*=newsCookie]").attr('id');
In the second statement above, newsCookie is being considered as text
rather than a variable. What should be done to consider newsCookie as
a variable rather than as text/string ?
Thanks