Capturing the Moment

Error thrown

Call to undefined method DOMText::setAttribute()