2012-01-25 84 views
0

我正在开发一个asp.net应用程序,我想在其中实现讨论面板。我现在可以发布并显示问题,我想发布有关该问题的评论。我的要求是当我点击评论框的提交按钮时,评论将显示,并且评论框将被下滑,类似于Stackoverflow评论。我知道这是可能的通过使用jQuery和Ajax,但如何?我不知道。发表评论,然后使用ajax和jquery显示评论

+0

你去那里:http://tutorialzine.com/2010/06/simple-ajax-commenting-system/它使用PHP的,但应该很容易转换成asp。 –

回答

0
<div id="commentTag">Comments</div> 
<div id="txtArea"> 
    <textarea></textarea> 
</div> 

和jQuery的部分

$("#commentTag").on("click",function(){ 

    $("#txtArea").slideToggle(); 
}); 

http://jsfiddle.net/bVhzj/1/