开发者

jquery edit inplace

Hello all im new to jquery and im trying to make a edit inplace (simple)

but i dont know how to check if the users click on the edit submit bottom :b.

do you know a simple tutorial how to make a edit system :)?.

i have this now

$(function() {
    $('#forum_dato a').click(function()
    {
        //var data = $('#data').text();
        $('#data').html('<form action="..." method="post"><textarea name="data">' + 
                  $('#data').text() + 
                  '</textarea><input type="submit" value="Edit"></form>');
        return false;
    })
})

do i need to use some ajax 开发者_高级运维or what is best :)?


Why not use the code someone else has already written? There are tons of libraries that already do this for you. Two really good ones:

  • TinyMCE (yes, there's a jQuery plugin for it)
  • markItUp!

Save yourself the time and go write meaningful (read: value-added) code.


This question already has been asked, and have decent answers IMO, https://stackoverflow.com/questions/708801/whats-the-best-edit-in-place-plugin-for-jquery

If it doesn't fit you need or have any other question, feel free to ask. :)



here you can find a nice plugin, maybe you can find some useful hints

demosite
doku

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜