DEDECMS中,如何把field.title传给IFRAME中的“name”这个表格中?

iByte 生活常识评论191字数 588阅读模式

用参数传递

IFRAME src="a.html?title={dede:field.title /}" /iframe文章源自玩技e族-https://www.playezu.com/138976.html

然后在iframe接到这个参数title赋值给name表的value文章源自玩技e族-https://www.playezu.com/138976.html

可以js获取文章源自玩技e族-https://www.playezu.com/138976.html

获取指定的URL参数值文章源自玩技e族-https://www.playezu.com/138976.html

URL:文章源自玩技e族-https://www.playezu.com/138976.html

参数:paramName URL参数文章源自玩技e族-https://www.playezu.com/138976.html

调用方法:getParam("name")文章源自玩技e族-https://www.playezu.com/138976.html

返回值:bainian文章源自玩技e族-https://www.playezu.com/138976.html

//1.文章源自玩技e族-https://www.playezu.com/138976.html

function getParam(paramName)文章源自玩技e族-https://www.playezu.com/138976.html

paramValue = "";

isFound = false;

if (this.location.search.indexOf("?") == 0 this.location.search.indexOf("=")1)

arrSource = unescape(this.location.search).substring(1,this.location.search.length).split("");

i = 0;

while (i arrSource.length !isFound)

if (arrSource[i].indexOf("=") 0)

if (arrSource[i].split("=")[0].toLowerCase==paramName.toLowerCase)

paramValue = arrSource[i].split("=")[1];

isFound = true;

i++;

return paramValue;

玩技站长微信
添加好友自动发送入群邀请
weinxin
rainbow-shownow
玩技官方公众号
官方微信公众号
weinxin
PLAYEZU
 
  • 版权提示:本站仅供存储任何法律责任由作者承担▷诈骗举报◁▷新闻不符◁▷我要投稿◁
    风险通知:非原创文章均为网络投稿真实性无法判断,侵权联系2523030730
    免责声明:内容来自用户上传发布或新闻客户端自媒体,切勿!切勿!切勿!添加联系方式以免受骗。
  • 原创转载:https://www.playezu.com/138976.html
    转载说明: 点我前往阅读>>>
匿名

发表评论

匿名网友
确定