发表评论,然后使用ajax和jquery显示评论 [英] Post comment and then display the comments using ajax and jquery
本文介绍了发表评论,然后使用ajax和jquery显示评论的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在开发一个asp.net应用程序,我想在其中实现讨论面板.我现在可以发布和显示问题,我想发表关于该问题的评论.我的要求是,当我单击评论框的提交按钮时,该评论将显示,并且该评论框将向下滑动,类似于Stackoverflow注释.我知道这可以通过使用jquery和ajax来实现,但是怎么办呢?我不知道.
I am developing an asp.net application in which I want to implement the discussion panel. I am able to post and display problem now I want to post comments on the problem. My requirement is when I click on the submit button of comment box then the comment will display and the comment box will be slide down similar to Stackoverflow comments. I know this is possible by using jquery and ajax but how? I don't know.
推荐答案
<div id="commentTag">Comments</div>
<div id="txtArea">
<textarea></textarea>
</div>
和jquery部分
$("#commentTag").on("click",function(){
$("#txtArea").slideToggle();
});
这篇关于发表评论,然后使用ajax和jquery显示评论的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文