Click to See Complete Forum and Search --> : Clickable background


AbrarNazeer
April 2nd, 2008, 09:10 AM
I want to use following code for Clickable background.

<style type='text/css'>
BODY { background-image:url('my.aspx?id=001') }
</style>

where "my.aspx?id=001" will return an image randomly, but i also want this background
to be clickable (Navigate to my randomly specified Url)
How is it possible ? Share the Ideas and give me chance of thanks.

PeejAvery
April 2nd, 2008, 10:54 AM
You can't use CSS to create clickable objects. You can, however, use the JavaScript event onclick.

<body onclick="JavaScriptFunction()">