标头位置(PHP)和查询重定向或刷新页面不起作用

时间:2016-07-08 07:38:36

标签: php jquery ajax redirect header

使用.htacess文件我重写了url。工作正常 会话过期问题。我使用ajax检查会话是否到期。如果在登录页面上过期重定向。     我用了c = array[0]; //read: the first row of the array for(var i = 1; i < m; ++i) { //iterate all rows var c_modified = []; for(var j = 0; j < n; ++j) { //iterate all row entries for(var k = 0; k < c.length; ++k) { //iterate all entries of c add c[k].array[i, j] to c_modified; // . represents concatenation } } c = c_modified; }     也试试`

<?php header('location: login.php'); die; ?>

1 个答案:

答案 0 :(得分:0)

试试这个

Cursor c = database.rawQuery(
    "select count(*) as TotalCount, tDate, " +
        "sum(case when type = '1' then Amount else 0 end) \"Income\", " +
        "sum(case when type = '2' then Amount else 0 end) \"Expenses\", " +
        "(sum(case when type = '1' then Amount else 0 end) - sum(case when type = '2' then Amount else 0 end)) \"Profit\", " +
        "strftime('%d', tDate) as DayPart, " +
        "strftime('%m', tDate) as MonthPart, " +
        "strftime('%Y', tDate) as YearPart " +
        "from library " +
        "group by MonthPart, YearPart Order by YearPart,MonthPart DESC", 
    null
);