Actually i want to take url and id from one fn to another whether this method will work.
function addElement(url, id) {
alert(url);
var main = document.getElementById('mainwidget');
main.innerHTML = "<iframe src=" + url + " align='left' height='1060px' width='576px' scrolling='no' frameborder='0' id='lodex'></iframe>";
alert("google");
addUrl(url, id);
}
function add() {
addUrl(url, id)
alert("id" + id);
document.getElementById("Listsample").innerHTML = "<a href='#' onclick='addUrl(" + url + ");' id='cricket' tabindex='1' name='cricket'>" + id + "</a>";
}