【问题标题】:Iframe content is a formiframe 内容是一种形式
【发布时间】:2017-06-20 07:57:09
【问题描述】:

我在 iframe 中有一个这样的表单

<iframe id="iframeid" style="display: none;height: 46px;width: 100px;" srcdoc="<html><body>
    <form action='https://localhost/lms/public/user/edit' method='POST'>
        <input type='hidden' name='Username' id='Username' value='tese@gmail.com' />
        <input type='submit' value='Edit Profile' /><
    </form></body></html>"></iframe>

但是在表单提交时,它不会重定向到我的表单提交所在的服务器。在 iframe 中可以吗?

【问题讨论】:

  • 为什么要在 iframe 中创建表单,它存在跨域问题?要求是什么?
  • 客户端要求我执行此操作“您可能可以 iFrame 编辑配置文件按钮,并使用 jquery 仅显示弹出警报以附加图像。”
  • 标题不是问题...只是一个模糊的陈述

标签: html css iframe


【解决方案1】:

我建议不要将 iframe 用于表单。如果客户要求这样做,请建议他们不要这样做。这么多不好的原因。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2010-10-06
    • 2013-12-24
    • 1970-01-01
    • 2011-03-09
    • 1970-01-01
    • 2017-07-26
    • 1970-01-01
    相关资源
    最近更新 更多