修改以下文件/source/include/space/space_album.php,找到以下一段代码- if($endkey>4) {
- $newkeys = array($nowkey-2, $nowkey-1, $nowkey, $nowkey+1, $nowkey+2);
- if($newkeys[1] < 0) {
- $newkeys[0] = $endkey-1;
- $newkeys[1] = $endkey;
- } elseif($newkeys[0] < 0) {
- $newkeys[0] = $endkey;
- }
- if($newkeys[3] > $endkey) {
- $newkeys[3] = 0;
- $newkeys[4] = 1;
- } elseif($newkeys[4] > $endkey) {
- $newkeys[4] = 0;
- }
- $upid = $list[$newkeys[1]]['picid'];
- $nextid = $list[$newkeys[3]]['picid'];
- foreach ($newkeys as $nkey) {
- $piclist[$nkey] = $list[$nkey];
- }
- } else {
- $newkeys = array($nowkey-1, $nowkey, $nowkey+1);
- if($newkeys[0] < 0) {
- $newkeys[0] = $endkey;
- }
- if($newkeys[2] > $endkey) {
- $newkeys[2] = 0;
- }
- $upid = $list[$newkeys[0]]['picid'];
- $nextid = $list[$newkeys[2]]['picid'];
- $piclist = $list;
- }
复制代码 替换为以下代码就可以了。- if($endkey>6) {
- $newkeys = array($nowkey-3,$nowkey-2, $nowkey-1, $nowkey, $nowkey+1, $nowkey+2,$nowkey+3);
- if($newkeys[2] < 0) {
- $newkeys[0] = $endkey-2;
- $newkeys[1] = $endkey-1;
- $newkeys[2] = $endkey;
- } elseif($newkeys[1] < 0) {
- $newkeys[0] = $endkey-1;
- $newkeys[1] = $endkey;
- } elseif($newkeys[0] < 0) {
- $newkeys[0] = $endkey;
- }
- if($newkeys[4] > $endkey) {
- $newkeys[4] = 0;
- $newkeys[5] = 1;
- $newkeys[6] = 2;
- } elseif($newkeys[5] > $endkey) {
- $newkeys[5] = 0;
- $newkeys[6] = 1;
- } elseif($newkeys[6] > $endkey) {
- $newkeys[6] = 0;
- }
- $upid = $list[$newkeys[2]]['picid'];
- $nextid = $list[$newkeys[4]]['picid'];
- foreach ($newkeys as $nkey) {
- $piclist[$nkey] = $list[$nkey];
- }
- } else {
- $newkeys = array($nowkey-2, $nowkey-1, $nowkey, $nowkey+1, $nowkey+2);
- if($newkeys[1] < 0) {
- $newkeys[0] = $endkey-1;
- $newkeys[1] = $endkey;
- } elseif($newkeys[0] < 0) {
- $newkeys[0] = $endkey;
- }
- if($newkeys[3] > $endkey) {
- $newkeys[3] = 0;
- $newkeys[4] = 1;
- } elseif($newkeys[4] > $endkey) {
- $newkeys[4] = 0;
- }
- $upid = $list[$newkeys[1]]['picid'];
- $nextid = $list[$newkeys[3]]['picid'];
- $piclist = $list;
- }
复制代码 |