# How to safely test adding a partner to javascript (in custom module)

**URL:** <https://community.hubspot.com/t/how-to-safely-test-adding-a-partner-to-javascript-in-custom-module/82887>\
**Category:** CMS Development\
**Tags:** javascript\
**Created:** [June 7, 2023, 5:16pm UTC](https://community.hubspot.com/t/how-to-safely-test-adding-a-partner-to-javascript-in-custom-module/82887 "2023-06-07T17:16:15Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Chappers](https://avatars.discourse-cdn.com/v4/letter/c/f9ae1b/32.png) [@Chappers](https://community.hubspot.com/u/Chappers)\
**Post date:** [June 7, 2023, 5:16pm UTC](https://community.hubspot.com/t/how-to-safely-test-adding-a-partner-to-javascript-in-custom-module/82887/1 "2023-06-07T17:16:15Z")

</div>

There’s a portion of .js we’re wanting to add a couple more partners to. I’m just wondering how to test adding the partners to the list below and then checking it works with our Calculator here \> [Home for Life Plan Quick Calculator | Homewise](https://www.homewise.co.uk/calculator)  
The code below picks up domain from UTM parameters and then displays the partner name into 1st line of text on 1st page of calculator (see link above). It seems straightforward but don’t want to mess it up!  
\n\n\n\n\n\n\n\n\nvar partnerLookup = [{\n url: ‘[[https://www.rightmove.co.uk](https://www.rightmove.co.uk)’,\]([https://www.rightmove.co.uk](https://www.rightmove.co.uk)’,)n name: ‘Rightmove’\n}, {\n url: ‘[[https://www.prospect.co.uk](https://www.prospect.co.uk)’,\]([https://www.prospect.co.uk](https://www.prospect.co.uk)’,)n name: ‘Prospect’\n}, {\n url: ‘[[https://www.wardsofkent.co.uk](https://www.wardsofkent.co.uk)’,\]([https://www.wardsofkent.co.uk](https://www.wardsofkent.co.uk)’,)n name: ‘Wards’\n}, {\n url: ‘[[https://www.pittis.co.uk](https://www.pittis.co.uk)’,\]([https://www.pittis.co.uk](https://www.pittis.co.uk)’,)n name: ‘Pittis’\n}, {\n url: ‘[[https://www.douglasallen.co.uk](https://www.douglasallen.co.uk)’,\]([https://www.douglasallen.co.uk](https://www.douglasallen.co.uk)’,)n name: ‘Douglas Allen’\n}, {\n url: ‘[[https://www.cubittandwest.co.uk](https://www.cubittandwest.co.uk)’,\]([https://www.cubittandwest.co.uk](https://www.cubittandwest.co.uk)’,)n name: ‘Cubitt & West’\n}, {\n url: ‘[[https://www.bradleys-estate-agents.co.uk](https://www.bradleys-estate-agents.co.uk)’,\]([https://www.bradleys-estate-agents.co.uk](https://www.bradleys-estate-agents.co.uk)’,)n name: ‘Bradleys’\n}, {\n url: ‘[[https://www.andrewsonline.co.uk](https://www.andrewsonline.co.uk)’,\]([https://www.andrewsonline.co.uk](https://www.andrewsonline.co.uk)’,)n name: ‘Andrews’\n}, {\n url: ‘[[https://www.connells.co.uk](https://www.connells.co.uk)’,\]([https://www.connells.co.uk](https://www.connells.co.uk)’,)n name: ‘Connells’\n}, {\n url: ‘[[https://rightmove.co.uk](https://rightmove.co.uk)’,\]([https://rightmove.co.uk](https://rightmove.co.uk)’,)n name: ‘Rightmove’\n}, {\n url: ‘[[https://prospect.co.uk](https://prospect.co.uk)’,\]([https://prospect.co.uk](https://prospect.co.uk)’,)n name: ‘Prospect’\n}, {\n url: ‘[[https://wardsofkent.co.uk](https://wardsofkent.co.uk)’,\]([https://wardsofkent.co.uk](https://wardsofkent.co.uk)’,)n name: ‘Wards’\n}, {\n url: ‘[[https://pittis.co.uk](https://pittis.co.uk)’,\]([https://pittis.co.uk](https://pittis.co.uk)’,)n name: ‘Pittis’\n}, {\n url: ‘[[https://douglasallen.co.uk](https://douglasallen.co.uk)’,\]([https://douglasallen.co.uk](https://douglasallen.co.uk)’,)n name: ‘Douglas Allen’\n}, {\n url: ‘[[https://cubittandwest.co.uk](https://cubittandwest.co.uk)’,\]([https://cubittandwest.co.uk](https://cubittandwest.co.uk)’,)n name: ‘Cubitt & West’\n}, {\n url: ‘[[https://bradleys-estate-agents.co.uk](https://bradleys-estate-agents.co.uk)’,\]([https://bradleys-estate-agents.co.uk](https://bradleys-estate-agents.co.uk)’,)n name: ‘Bradleys’\n}, {\n url: ‘[[https://andrewsonline.co.uk](https://andrewsonline.co.uk)’,\]([https://andrewsonline.co.uk](https://andrewsonline.co.uk)’,)n name: ‘Andrews’\n}, {\n url: ‘[[https://connells.co.uk](https://connells.co.uk)’,\]([https://connells.co.uk](https://connells.co.uk)’,)n name: ‘Connells’\n}];

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [June 8, 2023, 5:06pm UTC](https://community.hubspot.com/t/how-to-safely-test-adding-a-partner-to-javascript-in-custom-module/82887/2 "2023-06-08T17:06:15Z")

</div>

Hi, @Chappers 👋 Thanks for the question and for including your code example. I’d like to invite some of our community members to the converstaion — hey [@Mike\_Eastwood](https://community.hubspot.com/t5/user/viewprofilepage/user-id/9259) @albertsg @alyssamwilie @Indra, can you share how you might go about testing something similar to what @Chappers is describing?

Thank you! — Jaycee

---

<div class="post-metadata">

**Author:** ![Mike\_Eastwood](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/mike_eastwood/32/70075_2.png) [@Mike\_Eastwood](https://community.hubspot.com/u/Mike_Eastwood)\
**Post date:** [June 10, 2023, 12:31am UTC](https://community.hubspot.com/t/how-to-safely-test-adding-a-partner-to-javascript-in-custom-module/82887/3 "2023-06-10T00:31:35Z")

</div>

Hi @Chappers

Not sure if I fully understand what you want, so here’s a guess:

You could prepopulate a form - no javascript required - if you use a GET parameter.

For example [https://www.homewise.co.uk/calculator/\*\*?partner=righmove](https://www.homewise.co.uk/calculator/**?partner=righmove)\*\* would set the value of a form field named “partner” in a Hubspot Form.

Feel free to expand on your question.

Mike

p.s. thanks for the mention [@Jaycee\_Lewis](https://community.hubspot.com/t5/user/viewprofilepage/user-id/127074)

---

<div class="post-metadata">

**Author:** ![Chappers](https://avatars.discourse-cdn.com/v4/letter/c/f9ae1b/32.png) [@Chappers](https://community.hubspot.com/u/Chappers)\
**Post date:** [June 13, 2023, 4:51pm UTC](https://community.hubspot.com/t/how-to-safely-test-adding-a-partner-to-javascript-in-custom-module/82887/4 "2023-06-13T16:51:34Z")

</div>

Thanks [@Mike\_Eastwood](https://community.hubspot.com/t5/user/viewprofilepage/user-id/9259) - I’ve worked this out now. Turns out a space had crept in just before the word budget (i.e. in the line starting \> type: ’ budget…'). That space stopped it displaying on a Hubspot page. Simple as that!

On a wider question that maybe yourself, [@Jaycee\_Lewis](https://community.hubspot.com/t5/user/viewprofilepage/user-id/127074) , @albertsg , @alyssamwilie , @Indra could also help with.  
Could any of you summarise the likely developer resource that you’d anticpate a website like ours might need? I’m trying to put together a ‘straw man’ of developer time and resource our site may need going forward.
