简体   繁体   English

将joomla商品ID传递给模式iframe形式

[英]pass joomla article id to modal iframe form

I have a view in my joomla 2.5 component and a form at this. 我在joomla 2.5组件中有一个视图,并在此有一个表格。 now I'm show this form pop up in my article by this code by use joomla modal and it's work 现在,我将通过使用joomla modal通过此代码在我的文章中显示此表单,它的工作原理

<a class="modal"  rel="{handler: \'iframe\', size: {x: 600, y: 375}}" href='.$formlink.'>my text</a>

now how can I send my article id to this form for insert it to my database? 现在如何将文章ID发送到此表单,以将其插入数据库? I want pass my article id to iframe form. 我想将我的文章ID传递给iframe表单。

i found how can do it. 我发现该怎么办。 we can do it use this code: 我们可以使用以下代码来做到这一点:

$id = $article->id; $formlink = JRoute::_("index.php?option=com_mycomponent&view=myview&tmpl=component&id=$id")

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM