为啥上传不了图片。可以出来上传但之后控制台报错,图片也没在页面显示出来
<!--操作按钮-->
<div class="cart_operating clearfix">
<div class="cart_operating_style">
<div class="cart_price">商品总价:(不含运费)<b>¥0.00</b></div>
<div class="cart_btn">
<a href="javascript:void(0);" class="payment_btn">
<div class="paymentAllowed">马上付款</div></a>
<a href="#" class="continue_btn"></a>
</div>
</div>
</div>
<!-- 浮现栏 -->
<div class="floatTitle" style="border: 1px gainsboro solid;height: 50px;line-height: 50px;display: none;width: 1000px;">
<div style="font-size: 17px;display:inline;float: left">
已选商品
<span style="color: red;" id="float_count">0</span> 件
</div>
<div class="cart_price" style="display:inline;font-size: 17px;float: left;padding-left: 150px;padding-right: 180px;">
商品总价:(不含运费)<b style="color: red">¥0.00</b>
</div>
<div class="cart_btn" style="display:inline; ">
<a href="javascript:void(0);" class="payment_btn">
<div class="paymentAllowed">马上付款</div>
</a>
<a href="#" class="continue_btn"></a>
</div>
</div>
<script type="text/javascript">
$(function() {
$(window).scroll(function () {//鼠标滑动事件
var height = $(".cart_btn").offset().top;//计算该框离浏览器顶部的距离
if (height >= $(window).scrollTop() && height < ($(window).scrollTop() + $(window).height())) {
$(".floatTitle").hide();
}else {
$(".floatTitle").show();
}
});
//跳转到购物车页面加载时候
var height = $(".cart_btn").offset().top;//计算该框离浏览器顶部的距离
if (height >= $(window).scrollTop() && height < ($(window).scrollTop() + $(window).height())) {
$(".floatTitle").hide();
}else {
$(".floatTitle").show();
}
});
</script>
根据您提供的错误信息,可以看到 "TypeError: Cannot read property 'setDat截图'",这表示在某个对象的属性中无法找到 "setDat截图" 方法。另外,控制台还报了 "success" 方法的错误。
this指向有问题