修改了review视图中 在IE里Json.length方法失效的问题
This commit is contained in:
parent
1768ed5889
commit
3fe036d10b
|
@ -7,8 +7,8 @@
|
||||||
$this->headLink()->appendStylesheet('/static/js/uploadify/uploadify.css');
|
$this->headLink()->appendStylesheet('/static/js/uploadify/uploadify.css');
|
||||||
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
$this->headScript()->appendFile('/js/jquery-1.7.min.js');
|
||||||
$this->headScript()->appendFile('/static/js/uploadify/swfobject.js');
|
$this->headScript()->appendFile('/static/js/uploadify/swfobject.js');
|
||||||
$this->headScript()->appendFile('/static/js/uploadify/jquery.uploadify.v2.1.4.min.js');
|
$this->headScript()->appendFile('/static/js/uploadify/jquery.uploadify.v2.1.4.min.js');
|
||||||
$this->headScript()->appendFile('/js/jquery.colorbox-min.js');
|
$this->headScript()->appendFile('/js/jquery.colorbox-min.js');
|
||||||
$this->headLink()->appendStylesheet('/css/colorbox.css');
|
$this->headLink()->appendStylesheet('/css/colorbox.css');
|
||||||
$this->breadcrumb('<a href="/">首页</a>');
|
$this->breadcrumb('<a href="/">首页</a>');
|
||||||
$this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
|
$this->breadcrumb('<a href="/review">'.$this->config->title->review.'</a>');
|
||||||
|
@ -22,9 +22,9 @@
|
||||||
</h1>
|
</h1>
|
||||||
<div id="left">
|
<div id="left">
|
||||||
<div id="abstract">
|
<div id="abstract">
|
||||||
<p>
|
<p>
|
||||||
<a class="colorbox" href="/service/bigthumb/id/<?php echo $md['id'];?>" title="<?php echo $md['title'];?>">
|
<a class="colorbox" href="/service/bigthumb/id/<?php echo $md['id'];?>" title="<?php echo $md['title'];?>">
|
||||||
<img src="/service/thumb/id/<?php echo $md['id'];?>" class="thumb" />
|
<img src="/service/thumb/id/<?php echo $md['id'];?>" class="thumb" />
|
||||||
</a>
|
</a>
|
||||||
<?php echo str_replace(array("\r\n", "\n", "\r"),'</p><p>',$md['description']);?>
|
<?php echo str_replace(array("\r\n", "\n", "\r"),'</p><p>',$md['description']);?>
|
||||||
</p>
|
</p>
|
||||||
|
@ -145,20 +145,29 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
loadmdcomment(1);
|
loadmdcomment(1);
|
||||||
function loadmdcomment(page){var url="/review/allreview/uuid/<?php echo $md['uuid'];?>/";if(page!=''){url+='page/'+page;}
|
function loadmdcomment(page){
|
||||||
$.ajax({type:"POST",url:url,data:'',success:function(html){$('#allcomments').html(html);},beforeSend:function(){$('#allcomments').html('<img src="/images/loading.gif" />正在加载...');}});}
|
var url="/review/allreview/uuid/<?php echo $md['uuid'];?>/";
|
||||||
|
if(page!=''){url+='page/'+page;}
|
||||||
|
$.ajax({
|
||||||
|
'type':"POST",
|
||||||
|
'url':url,
|
||||||
|
'data':'',
|
||||||
|
'success':function(html){$('#allcomments').html(html);},
|
||||||
|
'beforeSend':function(){$('#allcomments').html('<img src="/images/loading.gif" />正在加载...');}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
function checkfiles(rid){
|
function checkfiles(rid){
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type:"POST",
|
'type':"POST",
|
||||||
url:"/review/attlist/id/"+rid,
|
'url':"/review/attlist/id/"+rid,
|
||||||
data:'',
|
'data':'',
|
||||||
success:function(html){
|
'success':function(html){
|
||||||
$('#filelist_'+rid).html(html);
|
$('#filelist_'+rid).html(html);
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
'beforeSend':function(){
|
||||||
$('#filelist_'+rid).html('<img src="/images/11887177066.gif" />正在加载...');
|
$('#filelist_'+rid).html('<img src="/images/11887177066.gif" />正在加载...');
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -189,16 +198,16 @@ $(document).ready(function() {
|
||||||
}
|
}
|
||||||
var date = $('#postcomment').serialize();
|
var date = $('#postcomment').serialize();
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type:"POST",
|
'type':"POST",
|
||||||
url:url,
|
'url':url,
|
||||||
data:date,
|
'data':date,
|
||||||
success:function(html){
|
'success':function(html){
|
||||||
$('#infobox').html(html);
|
$('#infobox').html(html);
|
||||||
$('#save').html('存草稿');
|
$('#save').html('存草稿');
|
||||||
setTimeout("$('#save').removeAttr('disabled');$('.box').remove();",3000);
|
setTimeout("$('#save').removeAttr('disabled');$('.box').remove();",3000);
|
||||||
loadmdcomment(1);
|
loadmdcomment(1);
|
||||||
},
|
},
|
||||||
beforeSend:function(){
|
'beforeSend':function(){
|
||||||
$('#save').attr('disabled','disabled');
|
$('#save').attr('disabled','disabled');
|
||||||
$('#save').html('<img src="/images/11887177066.gif" />正在保存...');
|
$('#save').html('<img src="/images/11887177066.gif" />正在保存...');
|
||||||
}
|
}
|
||||||
|
@ -251,7 +260,7 @@ $(document).ready(function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
$.getJSON("/upload/getatts/id/<?php echo $this->review['id'];?>", function(data) {
|
$.getJSON("/upload/getatts/id/<?php echo $this->review['id'];?>", function(data) {
|
||||||
if(data.length>0)
|
if(data)
|
||||||
{
|
{
|
||||||
$.each(data, function(key, val) {
|
$.each(data, function(key, val) {
|
||||||
$('<li/>', {
|
$('<li/>', {
|
||||||
|
@ -266,7 +275,7 @@ $(document).ready(function() {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
$(document).ready(function(){$(".colorbox").colorbox({photo:"true"});});
|
$(document).ready(function(){$(".colorbox").colorbox({photo:"true"});});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue