views:

32

answers:

1

I need to allow other people to embed some of my HTML and Javascript code. The HTML code itself is too much to be copy&pasted.

Should I use Iframes or script-tags for embeding it?

The script tags and iframes are used for example by Stackoverflow on Flair page How does those even exactly work? Aren't those a security risk?

What method would you prefer?

A: 

Make a file such as content.html and paste the html source there. Then you can include this file in the place you want to appear. For example, using php you can use

include 'path/to/content.html'; 

at the place you want to embed the html

poscaman
Hups, I think my question was a bit unclear. I need to allow other people to embed my content.
Epeli