I am using following code which works perfeet when i click on Link1, what i want to do is it should automatically on pageload fire the event loadContent, how to do that ?
<head>
<title>jQuery test page</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
<script type="text/javascript">
function loadContent(elementSelector, sourceUrl) {
$(""+elementSelector+"").load("http://abc.com/"+sourceUrl+"");
}
</script>
</head>
<body>
<a href="javascript:loadContent('#content', 'displayimages.php');">Link 1</a>
<div id="content">content will be loaded here</div>
</body>
</html>
Just call the method on page load