(added) - added logic for extrating content from mark in constructMarkupObject