Here is my code:
<script type="text/javascript">
$(".link").click(function(){
var id = this.id;
if(id == 'b1'){
$( "#conteudo" ).load( "teste.html", function(){
alert('Carregou de boa !');
});
}
});
</script>
All my pages are in localhost, I'm doing this just for study.
And this is the error that Chrome is giving me when I press the B1 button:
UPDATE Full Error:
OPTIONS file:///E:/mypath/folder/page.html No 'Access-Control-Allow-Origin'
header is present on the requested resource. Origin 'null' is therefore not allowed access.