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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T04:51:07+00:00 2026-05-23T04:51:07+00:00

Using jQuery and the HTML below, can someone please suggest what’s the best (ie.

  • 0

Using jQuery and the HTML below, can someone please suggest what’s the best (ie. most efficient) way to retrieve span.street_address_display from $(“input”). Thanks.

<tr>
<th class="address_name" scope="row">Work</th>
<td class="address_entry">
  <span class="street_address_display">123456 ABC Street</span> 
  <span class="city_display">Vancouver</span>,  
  <span class="state_province_display">British Columbia</span>  
  <span class="country_display">Canada</span>   
  <span class="post_code_display">V1A2B3</span> 
</td>
<td class="address_select"><input value="address_2" name="address_select" type="radio" /></td>
</tr>
  • 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-23T04:51:07+00:00Added an answer on May 23, 2026 at 4:51 am

    If you’re calling it within a function that has this being scoped to the input (otherwise you need to replace this with something that grabs the input), something like

    $(this).parent().prev().children('span.street_address_display')

    should take you to the span. As far as efficiency, I’d say the biggest place you’ll notice differences will be something like IE, or places that can’t grab by Tag or Class.

    Mind you, this is doing direct lookups, so one level up with .parent() rather than going up until you find a td, the previous td and then only direct children of that td that are span and have the class street_address_display. This won’t scrape deeply, so you’re losing flexibility, but less look ups translates to faster. It’s up to you if it’s worth it.

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

Sidebar

Related Questions

I am using jQuery. I call a JavaScript function with next html: <li><span><a href=javascript:uncheckEl('tagVO-$id')>$tagname</a></span></li>
I have a simple html block like: <span id=replies>8</span> Using jquery I'm trying to
I am using Jquery. I have got below links in my html <a class=load-fragment
In the example below, the text is selected using jQuery. How can we isolate
I am using jQuery and Django. I have the html below <input name =
Using jQuery/jQueryUI I want to populate a form using this HTML/JS show below. The
I would like to manipulate the HTML inside an iframe using jQuery. I thought
I am using jQuery and Ajax. My MainFile has the following code: <html> <head>
I have a simple html page with a div. I am using jQuery to
I'm using the jquery library to load the content of an html file. Something

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.