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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T07:38:58+00:00 2026-05-16T07:38:58+00:00

Okay, I might confuse some people who might be able to answer this question,

  • 0

Okay, I might confuse some people who might be able to answer this question, I’ll set this in the manner that I understand. Please bear with me.

Let’s say I have an array of divs in this manner:

<div id="par1"><span>Text 1</span></div>
<div id="par2"><span>Text 1</span></div>
<div id="par3"><span>Text 1</span></div>
<div id="par4"><span>Text 1</span></div>

Then, I have a hidden div with a textbox that acts like an editor:

<div id="editor" style="display: hidden"><input id="uniqueID$textbox" type="text" /></div>

What I want to achieve in jQuery is to visually display the #editor div within the divs above when i click each div somewhat an editor. Instead of having seperate input boxes within those divs and displaying them when needed, I intend to just use one textbox for each.

I hope I explained my problem well and hope you guys can help

  • 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-16T07:38:59+00:00Added an answer on May 16, 2026 at 7:38 am

    You might want to replace the <span> with an <input> element on click, like

    $(function(){
      $('span').bind('click', function(){
         $(this).replaceWith($('<input/>', {
            id:       'newinp',
            type:     'text',
            focusout: function(){
               $(this).replaceWith('<span>' + $(this).val() + '</span>');
            }
         }));       
         $('#newinp').focus();
      });
    });​
    

    Working example: http://www.jsfiddle.net/qbDKN/

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

Sidebar

Related Questions

Okay, I kinda asked this question already, but noticed that i might have not
okay, this might be a silly question. So I have some tuples of size
Okay, this question comes through a friend so it might be lost in translation...
This might be a n00bish question, but whatever. Is okay to use exceptions for
Okay, so the answer to my question might not be the problem but here's
Okay, this might be a very silly beginner question, but: I've got an ClassA,
okay this might be a pretty lame and basic question but its stuck in
Okay, this might be a basic question. Here is my code: <?php $pageid =
Okay, so this might be a dangerous question to ask. I have been doing
Okay, this might seem like a weird question, but bear with me. So I

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.