输入类型文本框中的C:\ afakepath\image.jpg [英] C:\fakepath\image.jpg in input type textbox

查看:186
本文介绍了输入类型文本框中的C:\ afakepath\image.jpg的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

< img src =images / avartarB.jpgwidth =180height =180alt =image/>





< input type =fileid =pathclass =fileupload/>(这是一个文本框)





i有一个带有按钮眉毛的文本框来选择一个图像,问题是当我选择一个图像时,文本框没有显示它的真实路径,如C:\ fakepath \ image.jpg我正在尝试显示一个真实的路径...帮助我

<img src="images/avartarB.jpg" width="180" height="180" alt="image" />


<input type="file" id="path" class="fileupload" />(this is a textbox)


i have a textbox with button browes to select a image and the problem is when i select an image textbox did not show the real paths its showes like C:\fakepath\image.jpg i am trying to show a real path ... help me

推荐答案

这是因为浏览器的安全性。您无法访问用户的计算机,因此浏览器会这样做。反正你也不需要这条路。该文件将被发送到您的服务器,然后您将其保存在服务器上的某个位置。
This is because of browser security. You can''t access the user''s computer so browsers do that. You don''t need the path anyway. The file will be sent to your server and then you''ll save it somewhere on your server.


这篇关于输入类型文本框中的C:\ afakepath\image.jpg的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆