Ajax请求在cakephp中不起作用

I'm trying to do an ajax request in cakephp.
My submit is #enviar. My action is pages/contato.

This is my ajax request:

$(document).ready(function() {
    $('#enviar').click(function(){
        $.ajax({
            type: 'post',
        url:"<?php echo Router::url(array('controller' => 'pages','action' => 'contato')); ?>",
        })
    })
});

I change the $.ajax for a simple alert() and when i click submit this works.
Where is my problem?

Better change the url, in your ajax function :-

$.ajax({
        type: 'post',
    url:"http://localhost/teste/pages/contato"
    })

Add an .htaccess file to the working directory with the following code:

allow from all

Have you tried with Html helper and an absolute path?

$.ajax({
    type: 'post',
    url: "<?=$this->Html->url(array('controller' => 'pages',
                                    'action' => 'contato'),
                              true);?>"
});