Javascript 使用settimeout,我只能加载页面中的单个部分,但在此过程中页面布局会被破坏
我只想在laravel的标题部分加载div部分 但是当我使用javascript的setTimeout函数加载时 设置inerval后,我的页面布局混乱 我尝试过settimeout和setinterval函数,但同样的问题再次发生 一次又一次 标题部分Javascript 使用settimeout,我只能加载页面中的单个部分,但在此过程中页面布局会被破坏,javascript,ajax,settimeout,Javascript,Ajax,Settimeout,我只想在laravel的标题部分加载div部分 但是当我使用javascript的setTimeout函数加载时 设置inerval后,我的页面布局混乱 我尝试过settimeout和setinterval函数,但同样的问题再次发生 一次又一次 标题部分 <li class="dropdown dropdown-notification nav-item" > <div id="reload1"> <a class="nav-link nav
<li class="dropdown dropdown-notification nav-item" >
<div id="reload1">
<a class="nav-link nav-link-label" href="#" data-toggle="dropdown"><i class="ficon ft-bell"></i>
<span class="badge badge-pill badge-default badge-danger badge-default badge-up badge-glow">{{$countNot}}</span>
</a>
<ul class="dropdown-menu dropdown-menu-media dropdown-menu right">
<li class="dropdown-menu-header">
<h6 class="dropdown-header m-0">
<span class="grey darken-2">Notifications</span>
</h6>
<span class="notification-tag badge badge-default badge-danger float-right m-0">{{$countNot}} New</span>
</li>
<li class="scrollable-container media-list w-100" >
@foreach($userAll as $user)
@if($user->notifications)
@foreach ($user->notifications as $notification)
@if(!$notification->read_at)
<a href="{{route('show.order')}}">
<div class="media">
<div class="media-left align-self-center"><i class="ft-plus-square icon-bg-circle bg-cyan"></i></div>
<div class="media-body">
<h6 class="media-heading">You have new order!</h6>
<p class="notification-text font-small-3 text-muted">Order number is {{$notification->data['show']}}</p>
</div>
</div>
</a>
@endif
@endforeach
@endif
@endforeach
</li>
<li class="dropdown-menu-footer"><a class="dropdown-item text-muted text-center" href="javascript:void(0)">Read all
notifications</a>
</li>
</ul>
</div>
</li>
主线程上的[Deprection]同步XMLHttpRequest为
不推荐使用,因为它会对最终用户的
经验如需更多帮助,请查看。
查询。延迟异常:无法读取未定义的属性“set”
TypeError:无法读取未定义的属性“set”
未捕获的TypeError:无法读取未定义的属性“set”
setTimeout(function(){
$('#reload1').load(location.href); },10000);
end function