$no==1?json_encode($Home_Json[$no-1]['Title']):$Home_Jso"/> $no==1?json_encode($Home_Json[$no-1]['Title']):$Home_Jso">

未定义的偏移量1-Undefined offset: 1错误该怎样解决

WBOY
Release: 2016-06-02 11:28:43
Original
4751 people have browsed it

未定义的偏移量1php

错误事件:E_NOTICE Run-time 通知。脚本发现可能有错误发生,但也可能在脚本正常运行时发生。
C:\WWW\weixin\member\shop\skin\23.php错误行数:第8行
错误原因:Undefined offset: 1

源代码:
$Dwidth = array('640','640','203','203','203','609','640','608','640','608');
$DHeight = array('320','63','121','121','121','93','63','187','63','187');
$Home_Json=json_decode($rsSkin['Home_Json'],true);
for($no=1;$no $json[$no-1]=array(
"ContentsType"=>$no==1?"1":"0",
"Title"=>$no==1?json_encode($Home_Json[$no-1]['Title']):$Home_Json[$no-1]['Title'],
"ImgPath"=>$no==1?json_encode($Home_Json[$no-1]['ImgPath']):$Home_Json[$no-1]['ImgPath'],
"Url"=>$no==1?json_encode($Home_Json[$no-1]['Url']):$Home_Json[$no-1]['Url'],
"Postion"=>$no>9 ? "t".$no : "t0".$no,
"Width"=>$Dwidth[$no-1],
"Height"=>$DHeight[$no-1],
"NeedLink"=>"1"
);
}

出现这个问题不知道咋解决。。。。求助各位

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!