I am trying to force an image to reload as a cache issue. I tried to follow this example but my result is that the image cannot be found:
<img id="profile_image" class="profile" src="http://localhost/PDO/asset/user_image/201658.jpg#1495177084338" alt=" profile">
var base_url = $("#base_url_side").val();
function myForeverFunc(){
$.ajax({
url: base_url + "TimeKeeping/get_latest_login",
cache: false,
dataType: 'json',
success: function(data){
$(".user_name").html(data[0].Name);
$("#profile_image").attr('src', base_url+"asset/user_image/"+data[0].Userid+".jpg#"+ new Date().getTime());
}
});
}
myForeverFunc();
setInterval(myForeverFunc, 500);