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 6009295
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T01:57:01+00:00 2026-05-23T01:57:01+00:00

I am not talking about $(#demo1).jstree(rename,node) which makes the node editable for the user.

  • 0

I am not talking about $("#demo1").jstree("rename",node) which makes the node editable for the user. I am talking about the name being changed within the code. For example my nodes are all prefixed with a 2 digit number “[01]” so before I call $("#demo1").jstree("rename",node) I want to strip out the prefix, and put it back in once the user has finished editing. I have tried selecting “#nodeid a” but inside the hyperlink there is an ins tag and this gets replaced if i replace the URL contents. The documentation hasn’t been helpful and I havent had much luck looking through the libraries code, can any help me? Chris

  • 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-23T01:57:02+00:00Added an answer on May 23, 2026 at 1:57 am

    The recommended method is to use rename_node

    $("#demo1").jstree('rename_node', node , text );
    

    Please keep in mind that by default all modifications to the tree are
    prevented
    (create, rename, move, delete). To enable them set
    core.check_callback to true

    $('#demo1').jstree({
        'core': {
            'check_callback': true,
            /// rest of the options...
        }
    });
    

    Rename your node (alternative, not recommended)

    $("#demo1").jstree('set_text', node , text );
    

    Debugging

    If you still encounter trouble, you can use this method to get the last error.

    $('#demo1').jstree(true).last_error()
    

    For older versions (v1.*)

    $("#demo1").jstree('rename_node', [node , text] ); 
    $("#demo1").jstree('set_text', [node , text] ); 
    

    See also:

    • this jsfiddle for the comparison and example of both methods.
    • Interaction with jsTree (how to call API methods)
    • API documentation of rename_node
    • API documentation of set_text
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm not talking about asp.net membership. For each logged user I want to cache
I'm not talking about if user has visited the website before, but in general
I'm not talking about JSON. I've got a program with the input being a
I am not talking about performance or price. I am talking about popularity. Which
I'm obviously not talking about a full solution, but just a good starting point
I'm not talking about bug tracking software (like Bugzilla or Jira). I'm looking for
I'm not talking about tools that let one view a page in combinations of
I'm not talking about the kind you get in college, but rather implementing progress
I'm not talking about a post build event for a project. Rather, I want
I'm not talking about a pointer to an instance, I want a pointer to

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.