I have a recruitment portal that people can use to advertise and search for jobs.
I would like the recruiters to be able to add a small javascript snippet to their personal websites, that will l开发者_如何学Goist jobs on my site.
how can i go about this?
I have webservices set up so the javascript can just call that, but i also need the result to be formatted and placed inline.
This should work in a simular way to google adsense.
I would really appreciate a small example
The easies way to do this is to have a piece of javascript that includes an iframe
pointing to a custom page on your server.
document.write("%3Ciframe src='http://foo.com/page/' style='border:0px'%3E%3C/iframe%3E");
If you want to inject the content directly into the document then you must deal with retrieving the data, and with the manipulation of the DOM.
The fact that you are posting this questions leads me to believe that the first option is the correct one for you.
精彩评论