fixed error when a textnode is null by using attribute exception handling. still regular expresssions are not read from xml file