每次在我的控制器中使用$ this-> session-> set_userdata()或$ this-> session-> set_flashdata()时,另一个相同的"Set-Cookie:ci_session = ..."被添加到http头中服务器发送.
根据rfc6265,http标头中具有相同cookie名称的多个Set-Cookie字段不合适.
那么有没有一种方法可以使用codeigniter会话而不创建多个相同的"set-cookie:"?
(我用curl来验证http头)
此代码适用于IE8,Crome和Safari,但不适用于Firefox:
<script src="@Url.Content("~/Scripts/jquery-1.5.1.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/modernizr-1.7.min.js")" type="text/javascript"></script>
<script type="text/jscript">
alert("wazzup");
$(document).ready(function () {
$(".MathLink").hover(function () {
$(this).css("color", "#d7d7d7");
}, function () {
$(this).css("color", "#FFFFFF");
});
$("#betyg_textblock").click(function () {
window.open("http://hogrebetyg.se/");
})
$("#roids_textblock").click(function () {
window.open("http://www.kongregate.com/games/irradiance_se/roids?acomplete=roids");
})
$(".servicesDiv").mouseenter(function (event) {
if ($(this).css("height") == "45px") {
$(".servicesDiv").animate({
height: "45px"
}, 300);
$(this).animate({
height: "100px"
}, 300, function () {
$(".servicesDiv").clearQueue();
});
}
});
$(".news").click(function (event) {
if ($(this).css("height") == "53px") {
$(this).animate({
height: "100%"
}, 400, function () {
$(".news").clearQueue();
});
}
else …Run Code Online (Sandbox Code Playgroud) codeigniter ×1
cookies ×1
duplication ×1
firefox ×1
http-headers ×1
javascript ×1
jquery ×1
session ×1