Prefill Checkout Form Fields (Billing Address Info)

Hi I’ve taken a look at this forum: How to populate input fields at checkout (SOLVED)

And it seems like this should be super easy! But, I just can’t get it to work. I’ve copied the script exactly. I’ve matched the field ID’s. It seems so simple, I don’t even know what else to check. But as you can see here: Districtt Web App it definitely doesn’t work

Any thoughts on how to troubleshoot?


Here is my site Read-Only: https://preview.webflow.com/preview/districtt-web-app?utm_medium=preview_link&utm_source=designer&utm_content=districtt-web-app&preview=356b87b2ff5c483c9aaa77bdf719096b&pageId=5e974bcc9c9fb0516296284f&mode=preview
(how to share your site Read-Only link)

Hi @TreyWilliams - When I look at your site, it seems like the IDs in your code may not match the IDs on your page.

For example, the code is using getElementById and searching for the IDs FullName2 and StreetAddress.

I don’t see elements with these IDs on your page. You do seem to have elements that have classes that match these names, but getElementById won’t find an element based on its class. To set the ID for an element, flip to Element Settings (the gear/cog) and enter it’s ID there.

Let me know if I’m just not looking in the right place for these IDs.