I'm just developing a new site on Wordpress. I'm using a free template and there is no support so I hope to get help here.

I'm having problems with the contact form on this site: http://harjumused.ee/kontakt/

I'm using Firefox and everything works great. But now I tried to send this form with Chrome and IE and it goes to 404 page. And I also got reports that some other people can't send it also with FF. How can this be?
Since the form is using Javascript I think the problem could be somewhere there.

I post the codes below. I have only translated the texts, no more changes. Maybe some of you will spot what could be wrong. Or maybe is the error somewhere else. Please try to write me from this form and see it it works.

Code from contact.php:

PHP Code:
<?php 
//Template Name: Contact Page
get_header() ?>
<div class="container">
        <header class="title">
            <h2><?php the_title() ?></h2>
        </header>
        <?php while ( have_posts() ) : the_post(); ?>
    
        <div class="post">    
                <article>
                    <?php the_content() ?>
                </article>
                <div class="social-links">
                    <a href="http://facebook.com/<?php echo get_option('fb_id'); ?>" class="facebook">
                        <i class="icon-facebook"></i>
                    </a>
                    <a href="http://twitter.com/<?php echo get_option('twitter_id'); ?>" class="twitter">
                        <i class="icon-twitter"></i>
                    </a>
                    <a href="http://plus.google.com/<?php echo get_option('gplus_id'); ?>" class="google">
                        <i class="icon-google-plus"></i>
                    </a>
                    <a href="<?php echo get_option('linkedin_id'); ?>" class="linkedin">
                        <i class="icon-linkedin"></i>
                    </a>
                </div>
                
                <div class="contact-form">
                <h2>Kirjuta mulle</h2>
                    <article style="display: none" id="sent-message">
                        <h2>Sinu kiri läks teele</h2>
                        <p>Aitäh sulle! Vastan esimesel võimalusel.</p>
                    </article>
                    <article style="display: none" id="error-message">
                        <h2>Oioi, midagi läks valesti, sinu kiri ei läinud teele.</h2>
                        <p>Palun proovi uuesti ja täida kõik väljad.</p>
                    </article>
                    <form id="ajaxContact">
                        <div>
                            <label>Nimi</label>
                            <input name="name" type="text" placeholder="Nimi" required/>
                        </div>
                        <div>
                            <label>E-post</label>
                            <input name="email" type="email" placeholder="E-posti aadress" required/>
                        </div>
                        <div>
                            <input name="subject" type="hidden"  value="Kiri harjumused.ee lehelt"/>
                        </div>
                        <textarea name="message"></textarea>
                        <input type="hidden" name="contact_email" value="<?php print get_option('contact_email')?>"/>
                        <input type="submit" class="submit" value="Saada" />
                    </form>
                </div>
                
                <?php endwhile; ?>
            </div>
        
    </div>    
    <script type="text/javascript">
                $(document).ready(function(){
                    $("#ajaxContact").validate();
                    
                    $('#ajaxContact').submit(function() {
                        if ($("#ajaxContact").valid() == false){
                            return false;
                        }
                        // got event!!
                        $("#ajaxContact").fadeTo("slow", 0.33);
                        //-------------------
                        $.ajax({
                                type: "POST",
                                url: "<?php echo get_template_directory_uri() ?>/mailsend.php",
                                data: $(this).serialize(),
                                success: function(data) {
                                    if (data == "true"){
                                        // msg sent...
                                        $("#ajaxContact").slideUp();
                                        $("#sent-message").slideDown();
                                    }else{
                                        // cannot sent msg
                                        $("#ajaxContact").slideUp();
                                        $("#error-message").slideDown();
                                    }
                                },
                            });
                                return false;
                        });
                    });
                        
                </script>
<?php get_footer() ?>

Code from mailsend.php:

PHP Code:
<?php
    
if(isset($_SERVER['HTTP_X_REQUESTED_WITH']) && strtolower($_SERVER['HTTP_X_REQUESTED_WITH']) == 'xmlhttprequest') {
        
$msg ="A new message from: " $_POST[name] ."<br />" $_POST['message'];
        
$to =  $_POST['contact_email']; 
        
$subject $_POST['subject']; 
        
$from $_POST['email'];
        
$headers  "From: $from\r\n" 
        
$headers .= 'MIME-Version: 1.0' "\r\n";
        
$headers .= 'Content-type: text/html; charset=UTF-8' "\r\n";
        
$headers .= "X-Mailer: PHP" phpversion(); 
        if (@
mail($to$subject$msg$headers)){
            echo 
"true";
        }else{
            echo 
"false";
        }
    }else{
        die();
    }
?>