XTRUST.ORG
XTRUST.ORG

Reputation: 3402

mootools | how to load and execute JSON string

I'm using a mootools javascript library and would like to load JSON string with script. After loading I would like to execute this script. Is it possible using great mootools framework?

Upvotes: 1

Views: 54

Answers (1)

XTRUST.ORG
XTRUST.ORG

Reputation: 3402

new Element('script',{'type': 'text/javascript', 'html': json.response}).inject(document.body, 'bottom');

Upvotes: 2

Related Questions