php - 在 iFrame 中加载服务器端而不是 URL
问题描述
是否有可能iframe
来自服务器的源文件而不是URL
含义而不是
---> Instead of
<iframe width='100%' height='100%' src='http://example.com/file.php' allowTransparency='yes' frameborder='no' scrolling='no' id='adminheader' > </iframe>
---> Load Server Side File
<iframe width='100%' height='100%' src='/home/username/public_html/header.php' allowTransparency='yes' frameborder='no' scrolling='no' id='adminheader' > </iframe>
目的是仅按原样加载标题,并在可能的情况下间接应用某些样式和脚本来访问它。
解决方案
不,因为 iframe 是在客户端呈现的。但我不明白为什么你不能用 URL 加载它们。
<iframe src='http://example.com/header.php'>
推荐阅读
- material-ui - @material-ui/lab 的官方版本是什么?
- stm32 - 解释寄存器的输出。AT90E32 + stm32
- testing - ENT - 一个伪随机数列测试程序
- php - 复选框 HTML 数组语法在 CakePHP 4 中不起作用
- reactjs - Application Insights React 插件
- elixir - 嵌套关联的 Ecto 限制
- java - 如何在java中解析嵌套的json
- elasticsearch - 用于检查所有数组元素是否存在的弹性搜索查询
- c# - 如何获取与绑定对象关联的“组合框”或“按钮”对象?
- rust - 如何为 Cargo 设置默认并行作业的数量 [-j 4]?