CMS Development

kathrynellis
Member

Java not pulling through into a form using a custom module

I am trying to add a custom module with a form to a landing page but the form isn't displaying. 

The form is a custom module because the details from the form need to plug into a HR system, they have given me some Javascript to add to the page to display the form they need to capture the details they need. We don't need the contact details in HubSpot. I have put Javascript in the custom module and I can see it render correctly here in the preview: https://app.hubspot.com/design-previewer/534480/modules/25661916242 But it doesn't seem to pull through onto the page.

 

Any ideas? 

0 Upvotes
7 Replies 7
prosa
Top Contributor

Java not pulling through into a form using a custom module

we can't see that url you are sharing. if you are posting to a different url you can use AJAX to handle the POST/ response from their server on the landing page you are creating. 

If this post helped you resolve your issue, please consider marking it as the solution. Thank you for supporting our HubSpot community.
0 Upvotes
alyssamwilie
Recognized Expert | Elite Partner
Recognized Expert | Elite Partner

Java not pulling through into a form using a custom module

Hi @kathrynellis ,

We don't have access to your portal so can't view the link you've provided. Would it be possible for you to link us to a preview of the page you've put the template on so we can try to determine why it's not showing?

If this answer solved your question, please mark it as the solution.

Alyssa Wilie Profile Image

Alyssa Wilie

Web Developerat Lynton

Learn HubL | Get Marketing Insights

HubSpot Elite Solutions Partner
Lynton's HubSpot theme Rubric now available. Click to download.
0 Upvotes
kathrynellis
Member

Java not pulling through into a form using a custom module

0 Upvotes
alyssamwilie
Recognized Expert | Elite Partner
Recognized Expert | Elite Partner

Java not pulling through into a form using a custom module

Weird, I can see the inrecruiting_form div on the page, but the script doesn't seem to be getting added for some reason. If you replace the script in the module with just 

 

$('#inrecruiting_form').html('Testing');

do you see 'Testing' added into the page?

If this answer solved your question, please mark it as the solution.

Alyssa Wilie Profile Image

Alyssa Wilie

Web Developerat Lynton

Learn HubL | Get Marketing Insights

HubSpot Elite Solutions Partner
Lynton's HubSpot theme Rubric now available. Click to download.
0 Upvotes
Matt1986
Participant

Java not pulling through into a form using a custom module

Hi, 

 

Adding $('#inrecruiting_form').html('Testing'); did work and now testing is displayed on the page. 

Do you know what the problem is now?

 

Thanks

 

Matt

0 Upvotes
alyssamwilie
Recognized Expert | Elite Partner
Recognized Expert | Elite Partner

Java not pulling through into a form using a custom module

Sorry, nope, just now know it's not an issue with the module itself. Maybe you could try putting the code into a .js file and adding it to the module as a linked file?

If this answer solved your question, please mark it as the solution.

Alyssa Wilie Profile Image

Alyssa Wilie

Web Developerat Lynton

Learn HubL | Get Marketing Insights

HubSpot Elite Solutions Partner
Lynton's HubSpot theme Rubric now available. Click to download.
0 Upvotes
Kevin-C
Recognized Expert | Partner
Recognized Expert | Partner

Java not pulling through into a form using a custom module

@alyssamwilie Yeah thats a weird one. using ".html("testing") or ".text(…" returns the object rather than modifying the dom.

Kevin Cornett - Sr. Solutions Architect @ BridgeRev
0 Upvotes