Ignore a link with an href which doesn't work
Try to use main element first if data-main-item is missing