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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T03:29:24+00:00 2026-05-23T03:29:24+00:00

In my HTML code i want to check the following HTML code and automatically

  • 0

In my HTML code i want to check the following HTML code and automatically delete it on page load, how do i do it in JQuery ?

First Code that needs to be deleted

<table cellspacing="0" cellpadding="0" width="100%"><tbody><tr class="yellow"><td width="64%" valign="top">

Second Code that needs to be deleted

</td></tr></tbody></table>
  • 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-23T03:29:24+00:00Added an answer on May 23, 2026 at 3:29 am

    I dont want to remove whole table, want to just remove the tags

    You can’t remove ‘tags’ from a live HTML document. A document living in a web browser is a tree of DOM ‘nodes’. The nodes maintain the current state of the document, and were originally parsed from the tags in the HTML source. But that markup is now gone and cannot be recovered(*) or edited in the browser.

    So you have a node representing the table element, containing nodes for all the content between the <table> start-tag and the corresponding </table> end-tag. In this case that’s one tbody element node, which contains one tr element node, which contains one td element node.

    To ‘unwrap’ the inner content you will need to take it out of the table and drop it in the place the table is. You can do this in jQuery using:

    $('#mytableid td').eq(0).contents().replaceAll('#mytableid');
    

    That is, replace the table with everything in its first cell.

    (*: you can read innerHTML to get a string of markup from a DOM element node, but this serialisation is newly-generated markup and won’t typically be exactly the same as what you put in.)

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

Sidebar

Related Questions

I want to show first element that is hidden by jquery. my html code
I have a HTML dropdown control. I want to check that if the text
I want to access a MySQL database directly from JavaScript code in an HTML
Quick question, If I want to document some code on a basic HTML and
I have the following html code: <h3 id=headerid><span onclick=expandCollapse('headerid')>&uArr;</span>Header title</h3> I would like to
I have html code that looks roughly like this: <div id=id1> <div id=id2> <p>some
The following html code works in Firefox, but for some reason fails in IE
I've got HTML code that roughly looks like this: <li id=someid-11> <img src=... alt=alt
I have got a HTML table which contain a check box in <TH> and
I am trying to load a html page through UIWebview.I need to disable all

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.