View Single Post
Old 09-21-2012, 01:58 PM   PM User | #7
zingzing45
New Coder

 
Join Date: Jun 2012
Posts: 57
Thanks: 13
Thanked 0 Times in 0 Posts
zingzing45 is an unknown quantity at this point
Angry This is so hard

Even though I followed all of your advice, this code below doesn't work!



<div id="secretcoin" onmouseover="addAward();">

</div>

<div id="newachievementdiv" align="center" class="awardBox"
style="display: none; margin: 0px auto; position: fixed; left: 250px;">
Congratulations! You have <span class="highlite-blue">found the secret coin</span>!
<br/>
<span></span>
</div>
<script>

$(document).ready(function()

{

function addAward()

{

$.ajax(

{

type: "POST",

url: "achievements.php",

data: { HomeCoinLocator: "Yes" }

});

var div = $("#newachievementdiv span").eq(1)

var span = $("span").get(4);

span.innerHTML = "' . $endtext . '";

$(div).fadeIn("4000");

setInterval( function() { $("#newachievementdiv").fadeOut("4000"); }, 4000);

}

});

</script>




BTW, that div junk at the beginning is where the function gets called.
zingzing45 is offline   Reply With Quote