Monday, February 21, 2011

inline editing with jquery

Hi,

Are there any guidelines on doing 'inline' editing with jqeury?

I know I am not using the correct term here, but basically you click on a some text and dynamically the area changes to an editable input box with a submit button.

Is there any built in capabilities with jquery?

From stackoverflow
  • jQuery has nothing built-in as far as I know, but check out Jeditable, which is a jQuery plugin.

  • You can do something like this:

    <input type="text" value="someText" id="editableText" class="hideBorder"/>
    
    $('#editableText').toggle(function() {
                 $(this).removeClass('hideBorder');
              }, function() {
                 $(this).addClass('hideBorder');
              });
    
    .hideBorder {
     border: 0;
    }
    

0 comments:

Post a Comment