我将要在我的网站上包含一个登录系统,但我不认为使用ajax发送和接收来自名为login.php的外部php脚本的确认并以相同的方式注销是安全的好主意.另一个logout.php任何推荐
我有当前的代码运行
我想做的是让动画进入无限循环怎么办?
我想再次调用相同的功能,或者我不知道是什么
只是动画在完成最后一个元素时反复出现
(function($) {
$.fn.fade = function() {
return this.each(function(index, item) {
var $this = $(this).siblings();
$(item).hide().stop();
if ($(item).index() == $(this).siblings().length - 1) {
$(item).delay(5000 * index).fadeIn('slow').delay(3500).fadeOut('slow', function() {
/* here is the last element finishing */
});
} else {
$(item).delay(5000 * index).fadeIn('slow').delay(3500).fadeOut('slow');
}
});
};
})(jQuery);
$('.tst').fade();
Run Code Online (Sandbox Code Playgroud)
编辑:我离开动画运行,来检查答案,所以我看到一个奇怪的行为
如何解决这个问题
让我们说:
$a = "5,8,0";
$b = "8,0,5";
Run Code Online (Sandbox Code Playgroud)
如何比较它们,而常规比较将失败,逗号分隔符将始终存在,但元素的顺序(id
产品的s,因此它们总是整数)不必相同(顺序).
有关如何在PHP中执行此操作的任何想法?
我有一个控制器,让我们说thingy/stuff
目录
<?php public function index() { /*thingy stuff */ }
public function anotherfunction() {/*other thingy stuff*/} ?>
Run Code Online (Sandbox Code Playgroud)
我看到网址就像 index.php?route=thingy/stuff&var=dd
我想要的是在该控制器内调用$ .post到这个函数
所以它使用另一个模板文件thingy.tpl
并返回html使用
URL应该是什么样的?
我搜索了几个小时,听起来好像没有开放式购物车的开发文档