You are viewing limited content. For full access, please sign in.

Question

Question

"ADDRESS" field label display none

asked on July 27, 2018

I'm trying to adjust this code someone gave me so that the ADDRESS (the very first label) is hidden.  See below.  The second line I added myself, but it does not work.  Everything else does.  I've tried CSS, but I think the JavaScript overrides it.  Can you help?

$(document).ready (function () {
$("#Field90_Label").siblings().css('display', 'none');  
$("#Field90_DSG5").parent().children().val("Canada"); 
$("#Field90_DSG5").parent().children().css('display', 'none');  
})

$(document).ready (function () {
$("#Field90_DSG4").siblings().text('Postal Code'); 
})

$(document).ready (function () {
$("#Field90_DSG3").siblings().text('Province'); 
})

$(document).ready (function () {
$("#Field90_DSG1").siblings().text('Mailing Address'); 
$(".Country").parent().children().css('display', 'Mailing Address'); 
})

It's that very first label that I want removed:

0 0

Answer

SELECTED ANSWER
replied on July 27, 2018 Show version history

First, go into your address field and add a custom CSS class called "hideLabel"

Next, go into the form CSS and add the following

.hideLabel .cf-label {
  display:none;
}

The end result would be something like this

0 0
replied on July 27, 2018

This works!  Thanks, guys!

0 0

Replies

replied on July 27, 2018 Show version history

For removing the Street Address label from all address fields, try this CSS:

label.cf-helptext[for*=DSG0] {
    display: none;
}

For removing the bolded Address field label from all address fields, try this CSS:

label.cf-label[for*=DSG0] {
    display: none;
}

For removing the Address field label from one address field specifically, try this CSS, where the number 31 should be replaced by the number of your field:

#q31 .cf-label {
    display: none;
}

 

0 0
replied on July 27, 2018

Karina, I am able to remove the street address label.  It is the very first Address word, shown to the far left, that I'm hoping to remove.  Thanks!

0 0
replied on July 27, 2018

Have you tried the second and third pieces of code above? Do they work for you?

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.