So I have this index that i am working on but i really find it a hassle to go in by hand and cross-link everything. I know a little bit about regexps and a little perl. here is what the html looks like
cf. <i>Penitencia y Reconciliación</i>
but sometimes there is an instance of this
cf. <i>Advenimiento, Consumación, Expectación</i>;
I ran this regex on it:
cf\. <i>([^,]+,)</i>
but my goal is to be able to run a regex that will wrap around one or multiple words and then copy the inner Html of the "phrase" and paste it inside a anchor tag something like this
cf. <i><a href="#Penitencia y Reconciliación">Penitencia y Reconciliación</a></i>
which i was able to accomplish with the regex above; but the problem is that my regex is does not take into consideration that there might be two "phrases" that it needs to wrap itself around. So my whole goal is to end up with this:
cf. <i><a href="#Advenimiento">Advenimiento</a>, <a href="#Consumación">Consumación</a>, <a href="#Expectación">Expectación</a></i>;
any help would be really appreciated