完整项目代码见阿里云盘,稍后上传
debug
1 ajax前台表单如何传参给后台php
不需要 action=…
而是button type=“submit” οnclick="showSite(litter.value),showsite是ajax函数
这里外边如果套form表单标签会出错,fom
<fom id="demo1" class="tr-slider-form wow fadeInUp" data-wow-duration="1.5s" data-wow-delay=".4s">
<div class="form-group position-relative mb-0">
<input id="litter" type="text" class="form-control trform-control"
placeholder="搜索你需要的工具">
<button type="submit" onclick="showSite(litter.value)" class="btn btn-primary tr-form-button" >搜索</button>
</div>
</form>
使用phpstudy将项目部署在腾讯云服务器 出错
在云服务器中安装phpstudy,将项目复制到www文件夹下,公网访问不到项目
phpstudy部署在服务器 ,phpstudy的端口号8848不行,8080可以但是要重启很多次才成功从公网访问到,原因未知
php代码无效了显示的是代码,在phpstudy新建网站就行了
好不容易访问到了项目的html,但是php代码失效,访问php直接显示代码
解决:在phpstudy新建网站接解决
网址
http://81.70.175.47:8080/docu/index.html