如何使用链接的ID值调用管理员创建的动态链接 [英] how to call a dynamic link created by the admin using the id value of the link

查看:73
本文介绍了如何使用链接的ID值调用管理员创建的动态链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我正在建立一个论坛,希望管理员可以为该论坛的主页创建一个链接,并且用户可以通过单击此链接来提出问题,并对问题或答案发表评论.当管理员创建链接时,它会显示在论坛主页上以及如何打开该链接..以便用户可以单击并打开该链接的问题,以及如何向该链接添加控件,从而打开相应的问题.我认为这是通过添加带有链接admin的自动id值,然后如何使用自动生成的id值调用该链接来完成的..

谢谢.
删除了预标记和邮件ID [/编辑]

Hi,
I am making a forum and want that admin can create a link for the forum home page and user can ask question by clicking this link and comment on the questions or answers. When admin create the link then it is show on the forum home page and how to open that link.. So that user can click and open the question of that link how to add control to that link so that it open the respective question. I think this is done by adding a auto id value with link which admin and then how to call that link using auto generated id value..

Thank you.
REMOVED PRE TAG & MAIL ID [/Edit]

推荐答案

据我所知,您想找到动态创建的链接的ID.如果是这样,您可以添加一个LinkBut​​ton控件并使用其CommandArgument属性来分配ID.

单击链接"后,在服务器端您可以获取链接的相应ID.

As far I understood you want to find the ID of the dynamically created link. If so you may add a LinkButton Control and use its CommandArgument property to assign the ID.

When Link is clicked, at server side you may get the corresponding ID of the link.

<asp:linkbutton id="lnkBtn" runat="server" commandname="QuestionClick" commandargument=''<%# Bind("ID")%>''>


这篇关于如何使用链接的ID值调用管理员创建的动态链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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