string splitting and matching checks