Guest Posted November 17, 2021 Share Posted November 17, 2021 On 2/1/2020 at 3:02 AM, tuanphan said: window.Squarespace.onInitialize(Y, function(){ sfSeconds = document.querySelector('.last-name input'); sfSeconds.value = "NA"; sfSecondsField = document.querySelector('.last-name'); sfSecondsField.style.display = "none"; }); Hi everyone, I´m having the same issue and Im not being able to solve it. Ive tried different things and nothing is working. My site: https://redbow.org.nz/coming-soon-v02 Thanks! Link to comment
tuanphan Posted November 20, 2021 Share Posted November 20, 2021 On 11/17/2021 at 7:45 PM, Candelabra said: Hi everyone, I´m having the same issue and Im not being able to solve it. Ive tried different things and nothing is working. My site: https://redbow.org.nz/coming-soon-v02 Thanks! It looks like you figured it out? Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
BUROM Posted August 21, 2023 Share Posted August 21, 2023 Hi there, I added the below code as footer code injection, but it still shows the last name "field" in my footer. What am I doing wrong? Website https://shallot-octahedron-m3zj.squarespace.com/home <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> <script> const lnames = document.querySelectorAll('.last-name input') const lnameFields = document.querySelectorAll('.last-name') $(document).ready(function(){ lnames.forEach(lname => { lname.value = "-" }) lnameFields.forEach(lnameField => { lnameField.style.display = "none" }) }); </script> Link to comment
tuanphan Posted August 23, 2023 Share Posted August 23, 2023 On 8/21/2023 at 11:41 AM, BUROM said: Hi there, I added the below code as footer code injection, but it still shows the last name "field" in my footer. What am I doing wrong? Website https://shallot-octahedron-m3zj.squarespace.com/home <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> <script> const lnames = document.querySelectorAll('.last-name input') const lnameFields = document.querySelectorAll('.last-name') $(document).ready(function(){ lnames.forEach(lname => { lname.value = "-" }) lnameFields.forEach(lnameField => { lnameField.style.display = "none" }) }); </script> Use this new code <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).ready(function(){ $('.last-name input').attr('value','NA'); $('.last-name').attr('style','display:none;'); }); </script> Mengified and Sarahlynn 2 Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
BUROM Posted August 23, 2023 Share Posted August 23, 2023 @tuanphan unfortunately now the last name field shows up as NA. Link to comment
tuanphan Posted August 24, 2023 Share Posted August 24, 2023 1 hour ago, BUROM said: @tuanphan unfortunately now the last name field shows up as NA. Use this new code <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).ready(function(){ $('.last-name input').attr('value','NA'); $('.last-name').attr('style','display:none !important;'); }); </script> <style> .newsletter-form-field-wrapper, .newsletter-block .newsletter-form-wrapper--layoutStack div.last-name { display: none !important; } </style> Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
BUROM Posted August 24, 2023 Share Posted August 24, 2023 @tuanphan amazing that worked! Thank you so much! You're the best! tuanphan 1 Link to comment
definingability Posted October 18, 2023 Share Posted October 18, 2023 Same problem here I've tried injecting every code in this thread and none of them have had any effect. Link to comment
tuanphan Posted October 21, 2023 Share Posted October 21, 2023 On 10/18/2023 at 10:37 AM, definingability said: Same problem here I've tried injecting every code in this thread and none of them have had any effect. Try this code, if it doesn't work, please share link to your site <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).ready(function(){ $('.last-name input').attr('value','NA'); $('.last-name').attr('style','display:none !important;'); }); </script> <style> .newsletter-form-field-wrapper, .newsletter-block .newsletter-form-wrapper--layoutStack div.last-name { display: none !important; } </style> Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Mengified Posted November 30, 2023 Share Posted November 30, 2023 (edited) On 8/23/2023 at 4:41 PM, tuanphan said: Use this new code <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).ready(function(){ $('.last-name input').attr('value','NA'); $('.last-name').attr('style','display:none;'); }); </script> Wow! This worked for me! Thank you 🙂 You're amazing! Edited November 30, 2023 by Mengified Link to comment
findingmyway Posted March 28 Share Posted March 28 Hi @tuanphan ive tried both codes in the footer (and header) and neither remove the last name field https://divinelyfeminine.nz/ Link to comment
tuanphan Posted March 31 Share Posted March 31 On 3/28/2024 at 4:08 PM, findingmyway said: Hi @tuanphan ive tried both codes in the footer (and header) and neither remove the last name field https://divinelyfeminine.nz/ Which page are you referring to? Or you mean this newsletter popup? Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
findingmyway Posted April 1 Share Posted April 1 On 3/31/2024 at 5:33 PM, tuanphan said: Which page are you referring to? Or you mean this newsletter popup? Yeah I its the newsletter sign up pop-up I want to remove last name from Link to comment
findingmyway Posted April 3 Share Posted April 3 On 3/31/2024 at 5:33 PM, tuanphan said: Which page are you referring to? Or you mean this newsletter popup? Is it possbile to be done - to remove the last name here? but still need to maintain last name for future sign ups on other pages i.e the store & checkout Link to comment
tuanphan Posted April 3 Share Posted April 3 1 minute ago, findingmyway said: Is it possbile to be done - to remove the last name here? but still need to maintain last name for future sign ups on other pages i.e the store & checkout This will require to use JavaScript code. Which template do you use? I will test it on my test site Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
findingmyway Posted April 4 Share Posted April 4 On 4/3/2024 at 5:47 PM, tuanphan said: This will require to use JavaScript code. Which template do you use? I will test it on my test site Camino LIVE Link to comment
tuanphan Posted April 7 Share Posted April 7 On 4/4/2024 at 6:12 PM, findingmyway said: Camino LIVE This template? https://camino-demo.squarespace.com/ Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment