From: William James Date: 2006-12-03T13:55:08+09:00 Subject: Re: search and replace ishamid wrote: > Hi Paul, > > On Dec 2, 10:56 am, Paul Lutus wrote: > > If you will post a short, complete data example, even just one record > as it > > appears in your database, so we don't have to try to read between the > > lines, someone here will be happy to produce a way to filter the data in > > the way you want. > > Ok, here are 4 bibliography entries. I just did a follow-up posting > with more detail (including the full script I'm trying to modify) so > you may prefer to respond to that one. Thank you very much for your > help!. > > ====================== > [ text:name="AutoNr" text:formula="ooow:AutoNr+1" > style:num-format="1">1 > 'Abd al-R��ziq, Ahmad > text:style-name="T3">Die al-Azhar-Moschee text:style-name="T4">., in, text:style-name="T3">"Sch��tze der Kalifen: Islamische Kunst zur > Fatimidenzeit.", > Herausgegeben von W. Seipel, Vienna: Kunsthistorisches Museum Wien; > Milan: Skira, 1998, pp. 144-147 > > > text:style-name="T5">[ text:ref-name="refAutoNr1" text:name="AutoNr" > text:formula="ooow:AutoNr+1" > style:num-format="1">2 > 'Abd al-R��ziq, Ahmad > text:style-name="T6">La mosqu��e al-Azhar text:style-name="T7">., in, text:style-name="T6">"Tr��sors fatimides du Caire. Exposition > pr��sent��e � l'Institut du Monde Arabe ... > text:style-name="T8">1998." text:style-name="T9">, Paris: Institut du Monde Arabe, 1998, pp. > 147-149 > > > [ text:ref-name="refAutoNr2" text:name="AutoNr" > text:formula="ooow:AutoNr+1" > style:num-format="1">3 > 'Amri, Husay > 'Abdallah > text:style-name="T10">The Text of an Unpublished Fatwa of the Scholar > al-Maqbali (d. 1108/1728) Concerning the Legal Position of the > Batiniyyah (Isma'iliyyah) of the People of Hamdan., > Translated by A.B.D.R. Eagle, New > Arabian Studies, 2 (1994), pp. 165-174. > > > [ text:ref-name="refAutoNr3" text:name="AutoNr" > text:formula="ooow:AutoNr+1" > style:num-format="1">4 > Abarahamov, Binyamin > text:style-name="T10">An Isma'ili Epistemology: The Case of > Al-Da'i al-Mutlaq 'Ali b. Muhammad b. al-Walid., > Journal of Semitic > Studies, 41ii (1996), pp. 263-273. > > > > ====================== puts DATA.read.gsub( %r{<(text:sequence)\s[^>]*>(.*?)}i, "\\starttext\n\\2\n\\stoptext" ) --- output ----- [\starttext 1 \stoptext 'Abd al-R\xC3\xA2ziq, Ahmad Die al-Azhar-Moschee., in, "Sch\xC3\xA4tze der Kalifen: Islamische Kunst zur Fatimidenzeit.", Herausgegeben von W. Seipel, Vienna: Kunsthistorisches Museum Wien; Milan: Skira, 1998, pp. 144-147 [\starttext 2 \stoptext 'Abd al-R\xC3\xA2ziq, Ahmad La mosqu\xC3(C)e al-Azhar., in, "Tr\xC3(C)sors fatimides du Caire. Exposition pr\xC3(C)sent\xC3(C)e \xC3 l'Institut du Monde Arabe ... 1998.", Paris: Institut du Monde Arabe, 1998, pp. 147-149 [\starttext 3 \stoptext 'Amri, Husay 'Abdallah The Text of an Unpublished Fatwa of the Scholar al-Maqbali (d. 1108/1728) Concerning the Legal Position of the Batiniyyah (Isma'iliyyah) of the People of Hamdan., Translated by A.B.D.R. Eagle, New Arabian Studies, 2 (1994), pp. 165-174. [\starttext 4 \stoptext Abarahamov, Binyamin An Isma'ili Epistemology: The Case of Al-Da'i al-Mutlaq 'Ali b. Muhammad b. al-Walid., Journal of Semitic Studies, 41ii (1996), pp. 263-273.