better solution to handle a tag without site reloading