使用jquery的uploadify,无法显示文件上传控件,请帮忙看是什么原因?
运行后,连我的上传文件的控件都显示不出来,搞了好久不知道什么原因。我把相关代码贴出来,大家帮忙看下,谢谢了===========div层页面:==============...
运行后,连我的上传文件的控件都显示不出来,搞了好久不知道什么原因。我把相关代码贴出来,大家帮忙看下,谢谢了
===========div层页面:=================
<!-- 插入图片效果层 -->
<div class="clear"></div>
<div class="tupianwz" style="display:none;" id="addpic">
<div class="tupianwz_con">
<p class="black">
<strong>插入图片</strong>
</p>
<p>
<input type="file" id="uploadify" name="uploadify" />
</p>
<p>
<input id="picname" name="picname" type="hidden" value="" />
<input id="checkpic" name="checkpic" type="hidden" value="-1" />
</p>
<p class="leixing">图片文件不超过1M,并且为.jpg、.png或.bmp格式。</p>
<input type="image" value="确定" id="" name=""
onmouseover="this.src='skins/default/s_images/submit_bg_on.gif'"
onmouseout="this.src='skins/default/s_images/submit_bg_off.gif'"
onclick="javascript:submitUpload()"
src="skins/default/s_images/submit_bg_off.gif" class="sub_res" />
<input type="image" value="取消" id="" name=""
onmouseover="this.src='skins/default/s_images/reset_bg_on.gif'"
onmouseout="this.src='skins/default/s_images/reset_bg_off.gif'"
onclick="javascript:cancelUpload()"
src="skins/default/s_images/reset_bg_off.gif" />
</div>
</div>
=============jquery uploadify操作代码:================
$("#uploadify").uploadify({
'uploader' : '<%=basePath%>skins/default/s_flash/uploadify.swf',
'script' : 'question.do?action=upload',
'cancelImg' : '<%=basePath%>skins/default/s_images/cancel.png',
'queueID' : 'fileQueue',
'auto' : false,
'multi' : false,
'buttonImg' : '<%=basePath%>skins/default/s_images/sel_img_bg_off.gif',
'width' : 100,
'height' : 30,
'onComplete' : function(event, queueID, fileObj, response, data) {
$("#facepic").attr("src","skins/default/s_temppic/"+response);
$("#picname").val(response);
$("#checkpic").val(0);
}
});
咋还没人来帮忙捏,代码虽然多了点,但关键的地方就一小点呀。。
就是 <input type="file" id="uploadify" name="uploadify" /> 这个栏位不显示。。。。。。
谢谢回答,是我的浏览器有问题,显示不出来。。我改用其他文件上传控件了。 展开
===========div层页面:=================
<!-- 插入图片效果层 -->
<div class="clear"></div>
<div class="tupianwz" style="display:none;" id="addpic">
<div class="tupianwz_con">
<p class="black">
<strong>插入图片</strong>
</p>
<p>
<input type="file" id="uploadify" name="uploadify" />
</p>
<p>
<input id="picname" name="picname" type="hidden" value="" />
<input id="checkpic" name="checkpic" type="hidden" value="-1" />
</p>
<p class="leixing">图片文件不超过1M,并且为.jpg、.png或.bmp格式。</p>
<input type="image" value="确定" id="" name=""
onmouseover="this.src='skins/default/s_images/submit_bg_on.gif'"
onmouseout="this.src='skins/default/s_images/submit_bg_off.gif'"
onclick="javascript:submitUpload()"
src="skins/default/s_images/submit_bg_off.gif" class="sub_res" />
<input type="image" value="取消" id="" name=""
onmouseover="this.src='skins/default/s_images/reset_bg_on.gif'"
onmouseout="this.src='skins/default/s_images/reset_bg_off.gif'"
onclick="javascript:cancelUpload()"
src="skins/default/s_images/reset_bg_off.gif" />
</div>
</div>
=============jquery uploadify操作代码:================
$("#uploadify").uploadify({
'uploader' : '<%=basePath%>skins/default/s_flash/uploadify.swf',
'script' : 'question.do?action=upload',
'cancelImg' : '<%=basePath%>skins/default/s_images/cancel.png',
'queueID' : 'fileQueue',
'auto' : false,
'multi' : false,
'buttonImg' : '<%=basePath%>skins/default/s_images/sel_img_bg_off.gif',
'width' : 100,
'height' : 30,
'onComplete' : function(event, queueID, fileObj, response, data) {
$("#facepic").attr("src","skins/default/s_temppic/"+response);
$("#picname").val(response);
$("#checkpic").val(0);
}
});
咋还没人来帮忙捏,代码虽然多了点,但关键的地方就一小点呀。。
就是 <input type="file" id="uploadify" name="uploadify" /> 这个栏位不显示。。。。。。
谢谢回答,是我的浏览器有问题,显示不出来。。我改用其他文件上传控件了。 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询