CMS Development

jzimmermann
Participant

Adding Job Feed API to HubSpot Template

Hello, 

 

I have a job feed API that I'm looking to add to a HubSpot page. I've never actually done this before so I truely don't even know where to start. 

 

Any instructions on how to get started would be greatly appreciated. 

 

Thanks! 

0 Upvotes
3 Replies 3
TRooInbound
Key Advisor

Adding Job Feed API to HubSpot Template

Hi @jzimmermann, I think you get data from the mentioned API url as per below method

 

<script>
$.get('your url', function (data) {
	var rootWith = '<Books>' + data.documentElement.innerHTML + '</Books>'
	var xmlDoc = $.parseXML(rootWith);
	var $xml = $(xmlDoc);
	var $bookItem = $xml.find('book');
	$bookItem.each(function () {
		//here is your code to display data as you want
	});
}
</script>

Here is my sample xml data :

<?xml version="1.0" encoding="UTF-8"?>
<bookstore>
  <book category="web">
    <title lang="en">Learning XML</title>
    <author>Erik T. Ray</author>
    <year>2003</year>
    <price>39.95</price>
  </book>
</bookstore>

NOTE: please replace 'your url' with mentioned API url, and xml tags as per your requirement.

 

 

TRooInbound Team!

0 Upvotes
jzimmermann
Participant

Adding Job Feed API to HubSpot Template

Thanks for the response @TRooInbound

 

I'm really not experience at doing this so I'm not really sure where to start. Got a custom html module inserted into the page and started adding the code you suggested but not really sure what to manipulate in the code to pull what I need. 

 

Can you help with some more specifics? I'm not really seeing what you're suggesting matching up with the doc that was provided to me. 

0 Upvotes
TRooInbound
Key Advisor

Adding Job Feed API to HubSpot Template

Hi @jzimmermann,

 

Sure, we can. Can you please email me at hello@trooinbound.com ?

 

Team Trooinbound

0 Upvotes