Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/291.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 数据库无法从crawl.php获取数据_Javascript_Php_Mysql_Web Crawler - Fatal编程技术网

Javascript 数据库无法从crawl.php获取数据

Javascript 数据库无法从crawl.php获取数据,javascript,php,mysql,web-crawler,Javascript,Php,Mysql,Web Crawler,我试图输入URL并按下提交按钮,但数据库没有在wamp64中更新, 在上面这张照片中,你可以看到它正在处理 我不知道我的代码中有什么问题,我试图在服务器上联机运行,但仍然不起作用 <div class="alert textGradient fixed-bottom" role="alert"> <strong></strong> </div> <div class="containe

我试图输入URL并按下提交按钮,但数据库没有在wamp64中更新, 在上面这张照片中,你可以看到它正在处理 我不知道我的代码中有什么问题,我试图在服务器上联机运行,但仍然不起作用

<div class="alert textGradient fixed-bottom" role="alert">
    <strong></strong>
</div>
<div class="container">
    <div class="row">
        <div class="col-md-4">
            <div class="card text-light">
                <a href="/"><img class="card-img-top" src="assets/images/mrfoxie.png" alt="logo" /></a>
                <form method="post" id="formSubmitUrl">
                    <div class="card-body">
                        <div class="input-group mb-3">
                            <div class="input-group-prepend"><span class="input-group-text" id="basic-addon1" style="color: #f42b03;">@</span></div>
                            <input type="url" class="form-control" name="url" placeholder="Submit URL here..." required aria-label="Search" aria-describedby="basic-addon1" name="url" required />
                        </div>
                        <input style="width: 100%;" id="buttonSubmit" class="btn btn-lg" type="submit" value="Submit" />
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
<script>
    $(document).ready(function() {
        $("#formSubmitUrl").submit(function(e) {
            e.preventDefault();
            $(".textGradient").text("Processing Please wait...");
            $("#buttonSubmit").prop('disabled', true);
            $.ajax({
                type: 'post',
                url: 'crawl.php',
                data: $('form').serialize(),
                success: function() {
                    $("#buttonSubmit").text('disabled', false);
                    $(".textGradient").html("The system has received the url");
                }
            });
        })
    })
</script>


@
$(文档).ready(函数(){
$(“#formsubmitur”).submit(函数(e){
e、 预防默认值();
$(“.textGradient”).text(“正在处理,请稍候…”);
$(“#按钮提交”).prop('disabled',true);
$.ajax({
键入:“post”,
url:'crawl.php',
数据:$('form')。序列化(),
成功:函数(){
$(“#按钮提交”).text('disabled',false);
$(“.textGradient”).html(“系统已收到url”);
}
});
})
})
以下是crawl.php未更新的数据库截图

控制台中是否有javascript错误?您的php脚本实际接收到什么数据?不,我没有检查控制台,它只是在使用wamp64到localhost时接收url、说明和标题。您在控制台中有任何javascript错误吗?您的php脚本实际接收什么数据?不,我没有检查控制台,它只是在使用wamp64本地托管时接收url、说明和标题