Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6730981
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:28:25+00:00 2026-05-26T10:28:25+00:00

Using jQuery plugin jEditable. Problem I’m having is that I want whatever is editable

  • 0

Using jQuery plugin jEditable. Problem I’m having is that I want whatever is editable to display the text instead of the html after I trigger the jEditable event.

For example if I have an element <span class="editable">Jack & Jill</span>, when I click it, I get Jack &amp; Jill, but what I want is Jack & Jill as my value in the input so that the user doesn’t see HTML.

There must be something I can do with the data setting [perhaps a value.replace(); or something]. Right now I just have it returning the the value.

CODE

$('.editable').each(function() {
      $(this).editable('url', {
                data: function(value, settings) {
                      var retval = value;
                      return retval;
                }

      });
});
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T10:28:26+00:00Added an answer on May 26, 2026 at 10:28 am

    When you render the page with php, it looks like you are using htmlspecialchars() or similar to translate & into its html entity equivalent &amp;.

    So when you edit it, instead of loading the information from the item on the page, you need to load it from an ajax call to your server (which will return the actual html, without running it through htmlspecialchars() or anything else).

    Jeditable gives you a nice option for this, so try something like:

    $('.editable').each(function() {
          $(this).editable('url', {
                    loadurl  : 'http://www.example.com/returnUntouchedhtml.php',
                    data: function(value, settings) {
                          var retval = value;
                          return retval;
                    }
    
          });
    
    });
    

    You can find more examples/information on this page: http://www.appelsiini.net/projects/jeditable

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm submitting data using the jQuery plugin 'Jeditable' and that part is working fine.
I am using jquery lightbox plugin colorbox ( http://colorpowered.com/colorbox/ ) and i want to
I am using Jquery Cycle Plugin and it has a side panel that highlights
i m using jQuery tablsorter plugin, it's working perfect,but now problem is ... i
I was using Jquery Numeric plugin but I found that is not working on
i am using jquery plugin and i got stuck in how to display the
I'm using Jquery plugin DropShadow: web site And I want to set drop shadow
I have been using the JEditable plugin for JQuery and I would like to
I am using Jquery TipTip plugin. If you know better plugin that way easy
I am using the dropShadow plugin, and I have a problem with the JQuery

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.