var _scope = {}; var toparse = ''; String.prototype.replaceAll = function(search, replacement) { var target = this; return target.replace(new RegExp(search, 'g'), replacement); }; var app = angular.module('catholicer', ['ngSanitize', 'angulartics', 'angulartics.google.analytics']) .controller('c-main', ['$scope', 'cService', '$analytics', function($scope, cService, $analytics) { $scope.cService = cService; $scope.rites = { children : [ {name:"icons", data:"icons", title:"byzantine icons", img: "https://www.catholicer.com/liturgia/images/icon-icon.jpg", note: "", children : [{name:"pantocrator", data:"pantocrator", title:"christ pantocrator", img: "https://www.catholicer.com/liturgia/images/icon-pantocrator.jpg", note: "", children : []},{name:"decent-holy-spirit", data:"decent-holy-spirit", title:"decent of holy spirit", img: "https://www.catholicer.com/liturgia/images/icon-decent-holy-spirit.jpg", note: "pentecost", children : []},{name:"entrance-of-theotokos", data:"entrance-of-theotokos", title:"entrance of the theotokos", img: "https://www.catholicer.com/liturgia/images/icon-entrance-of-theotokos.jpg", note: "", children : []},{name:"icon-nativity", data:"icon-nativity", title:"nativity", img: "https://www.catholicer.com/liturgia/images/icon-nativity.jpg", note: "", children : []},{name:"icon-theophany", data:"icon-theophany", title:"theophany", img: "https://www.catholicer.com/liturgia/images/icon-theophany.jpg", note: "", children : []},{name:"icon-theotokos", data:"icon-theotokos", title:"theotokos", img: "https://www.catholicer.com/liturgia/images/icon-theotokos.jpg", note: "", children : []},]},{name:"prayers", data:"prayers", title:"catholic prayers & hymns", img: "https://www.catholicer.com/liturgia/images/icon-other-prayers.jpg", note: "", children : [{name:"actofcontrition", data:"actofcontrition", title:"act of contrition", img: "https://www.catholicer.com/liturgia/images/icon-actofcontrition.jpg", note: "", children : []},{name:"angelus", data:"angelus", title:"angelus", img: "https://www.catholicer.com/liturgia/images/icon-angelus.jpg", note: "", children : []},{name:"anima-christi", data:"anima-christi", title:"anima christi", img: "https://www.catholicer.com/liturgia/images/icon-anima-christi.jpg", note: "", children : []},{name:"apostle-creed", data:"apostle-creed", title:"apostle's creed", img: "https://upload.wikimedia.org/wikipedia/commons/thumb/3/31/Nicaea_icon.jpg/440px-Nicaea_icon.jpg", note: "", children : []},{name:"axion-estin", data:"axion-estin", title:"axion estin", img: "https://upload.wikimedia.org/wikipedia/commons/e/e5/Dostojno_ests.jpg", note: "", children : []},{name:"canticle-zechariah", data:"canticle-zechariah", title:"benedictus (song of zechariah)", img: "https://upload.wikimedia.org/wikipedia/commons/thumb/5/52/Cappella_Tornabuoni,_Zacharias_Writes_Down_the_Name_of_his_Son_02.jpg/250px-Cappella_Tornabuoni,_Zacharias_Writes_Down_the_Name_of_his_Son_02.jpg", note: "", children : []},{name:"st-joseph-byzantine", data:"st-joseph-byzantine", title:"byzantine hymn to st. joseph", img: "https://s-media-cache-ak0.pinimg.com/564x/73/99/43/73994384abd34a80e4c2d642c35b2143.jpg", note: "", children : []},{name:"canticle-mary", data:"canticle-mary", title:"canticle of mary (magnificat)", img: "https://catholicreblog.files.wordpress.com/2015/06/hail-mary-explanation.jpg?w=723", note: "", children : []},{name:"veni-sancte-spiritus", data:"veni-sancte-spiritus", title:"come holy spirit", img: "https://www.catholicer.com/liturgia/images/icon-pentecost.jpg", note: "", children : []},{name:"divinemercy", data:"divinemercy", title:"divine mercy chaplet", img: "https://www.catholicer.com/liturgia/images/icon-divinemercy.jpg", note: "", children : []},{name:"glorybe", data:"glorybe", title:"glory be", img: "https://i1.sndcdn.com/artworks-000104382759-rts8dn-t500x500.jpg", note: "", children : [{name:"glorybe-arabic", data:"glorybe-arabic", title:"arabic version", img: "https://www.catholicer.com/liturgia/images/lang-ar.png", note: "", children : []},{name:"glorybe-english", data:"glorybe-english", title:"english version", img: "https://www.catholicer.com/liturgia/images/lang-en.png", note: "", children : []},{name:"glorybe-greek", data:"glorybe-greek", title:"greek version", img: "https://www.catholicer.com/liturgia/images/lang-el.png", note: "", children : []},{name:"glorybe-mozarabic", data:"glorybe-mozarabic", title:"mozarabic version", img: "https://www.catholicer.com/liturgia/images/icon-mozarabic.jpg", note: "", children : []},{name:"glorybe-roman", data:"glorybe-roman", title:"roman version", img: "https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcRyFiLBsDlOcIopm2dcWcqEcyZmEZ-qwaSWuAz6Cq1Siv_XyyXbKg", note: "", children : []},]},{name:"prayer-guardian-angel", data:"prayer-guardian-angel", title:"guardian angel prayer", img: "https://www.catholicer.com/liturgia/images/icon-angel.jpg", note: "", children : []},{name:"hailmary", data:"hailmary", title:"hail mary", img: "https://www.catholicer.com/liturgia/images/icon-maria-fatima.jpg", note: "", children : [{name:"hailmary-greek", data:"hailmary-greek", title:"greek version", img: "https://www.catholicer.com/liturgia/images/lang-el.png", note: "", children : []},{name:"hailmary-latin", data:"hailmary-latin", title:"latin version", img: "https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcRyFiLBsDlOcIopm2dcWcqEcyZmEZ-qwaSWuAz6Cq1Siv_XyyXbKg", note: "", children : []},{name:"hailmary-slavonic", data:"hailmary-slavonic", title:"slavonic version", img: "https://www.catholicer.com/liturgia/images/lang-sla.png", note: "", children : []},]},{name:"jesus-prayer", data:"jesus-prayer", title:"jesus prayer", img: "https://www.catholicer.com/liturgia/images/icon-jesus-prayer.jpg", note: "", children : []},{name:"kyrie-eleison", data:"kyrie-eleison", title:"kirie eleison", img: "https://www.catholicer.com/liturgia/images/icon-jesus-prayer.jpg", note: "", children : []},{name:"litany-of-humility", data:"litany-of-humility", title:"litany of humility", img: "https://www.catholicer.com/liturgia/images/icon-humility.jpg", note: "", children : []},{name:"litany-of-loretto", data:"litany-of-loretto", title:"litany of loretto", img: "https://catholicreblog.files.wordpress.com/2015/06/hail-mary-explanation.jpg?w=723", note: "", children : []},{name:"ourfather", data:"ourfather", title:"lord's prayer", img: "https://www.catholicer.com/liturgia/images/icon-our-father.jpg", note: "", children : []},{name:"meal-prayer", data:"meal-prayer", title:"mealtime blessings", img: "https://www.catholicer.com/liturgia/images/icon-meals.png", note: "", children : [{name:"meal-prayer-greek", data:"meal-prayer-greek", title:"mealtime blessings in greek tradition", img: "https://www.catholicer.com/liturgia/images/icon-meals.png", note: "", children : []},{name:"meal-prayer-latin", data:"meal-prayer-latin", title:"mealtime blessings in latin tradition", img: "https://www.catholicer.com/liturgia/images/icon-meals.png", note: "", children : []},{name:"meal-prayer-ukraine", data:"meal-prayer-ukraine", title:"mealtime blessings in ukrainian tradition", img: "https://www.catholicer.com/liturgia/images/icon-meals.png", note: "", children : []},]},{name:"nicene-constantinopolitan-creed", data:"nicene-constantinopolitan-creed", title:"nicene creed after council of constantinople", img: "https://upload.wikimedia.org/wikipedia/commons/thumb/3/31/Nicaea_icon.jpg/440px-Nicaea_icon.jpg", note: "", children : []},{name:"o-salutaris-hostia", data:"o-salutaris-hostia", title:"o salutaris hostia", img: "https://www.catholicer.com/liturgia/images/icon-blessed-sacrament.jpg", note: "", children : []},{name:"nicene-creed", data:"nicene-creed", title:"original nicene creed", img: "https://upload.wikimedia.org/wikipedia/commons/thumb/3/31/Nicaea_icon.jpg/440px-Nicaea_icon.jpg", note: "", children : []},{name:"pange-lingua", data:"pange-lingua", title:"pange lingua", img: "https://www.catholicer.com/liturgia/images/icon-blessed-sacrament.jpg", note: "hymn by st. thomas aquinas", children : []},{name:"rosary", data:"rosary", title:"rosary", img: "https://www.catholicer.com/liturgia/images/icon-rosary.jpg", note: "", children : [{name:"rosary-seven-sorrows", data:"rosary-seven-sorrows", title:"seven sorrows rosary", img: "https://www.catholicer.com/liturgia/images/icon-rosary.jpg", note: "", children : []},]},{name:"hail-holy-queen", data:"hail-holy-queen", title:"salve regina", img: "https://www.catholicer.com/liturgia/images/icon-maria-fatima.jpg", note: "", children : []},{name:"st-michael-the-archangel", data:"st-michael-the-archangel", title:"st michael the archangel", img: "https://www.catholicer.com/liturgia/images/icon-archangel-michael.jpg", note: "", children : []},{name:"tantum-ergo", data:"tantum-ergo", title:"tantum ergo sacramentum", img: "https://www.catholicer.com/liturgia/images/icon-blessed-sacrament.jpg", note: "for benediction", children : []},{name:"trisagion", data:"trisagion", title:"trisagion", img: "https://www.catholicer.com/liturgia/images/icon-trisagion.jpg", note: "", children : []},{name:"watch-o-lord", data:"watch-o-lord", title:"watch o lord", img: "https://www.catholicer.com/liturgia/images/icon-st-augustine.jpg", note: "", children : []},]},{name:"letters", data:"letters", title:"letters", img: "https://www.catholicer.com/liturgia/images/icon-letter.jpg", note: "", children : [{name:"doc-early-christian-epistle-barnabas", data:"doc-early-christian-epistle-barnabas", title:"epistle of barnabas", img: "https://www.catholicer.com/liturgia/images/icon-epistle-barnabas.jpg", note: "", children : []},{name:"doc-early-christian-epistle-polycarp", data:"doc-early-christian-epistle-polycarp", title:"epistle of polycarp", img: "https://www.catholicer.com/liturgia/images/icon-polycarp.jpg", note: "", children : []},{name:"doc-early-christian-epistle-on-arianism", data:"doc-early-christian-epistle-on-arianism", title:"epistles on arianism & the deposition of arius (Alexander of Alexandria)", img: "https://www.catholicer.com/liturgia/images/icon-st-alexander-alexandria.jpg", note: "", children : []},{name:"doc-early-christian-ignatius-polycarp", data:"doc-early-christian-ignatius-polycarp", title:"ignatius to polycarp", img: "https://www.catholicer.com/liturgia/images/icon-ignatius-antioch.jpg", note: "", children : []},{name:"doc-early-christian-martyrdom-polycarp", data:"doc-early-christian-martyrdom-polycarp", title:"martyrdom of polycarp", img: "https://www.catholicer.com/liturgia/images/icon-polycarp.jpg", note: "", children : []},]},{name:"liturgies", data:"liturgies", title:"liturgies", img: "https://www.catholicer.com/liturgia/images/icon-liturgies.jpg", note: "", children : [{name:"alexandrian", data:"alexandrian", title:"started in alexandria", img: "https://www.catholicer.com/liturgia/images/icon-alexandrian.jpg", note: "", children : [{name:"coptic", data:"coptic", title:"coptic rites", img: "https://www.catholicer.com/liturgia/images/icon-coptic.png", note: "", children : []},{name:"ethiopean", data:"ethiopean", title:"ethiopean rites", img: "https://www.catholicer.com/liturgia/images/icon-ethiopean.jpg", note: "", children : []},]},{name:"antioch", data:"antioch", title:"started in antioch", img: "https://holylandphotos.files.wordpress.com/2013/05/tcmcaosp01.jpg", note: "", children : [{name:"armenian", data:"armenian", title:"armenian rite", img: "https://upload.wikimedia.org/wikipedia/commons/9/92/Echmiatsin_altair.jpg", note: "", children : []},{name:"byzantine", data:"byzantine", title:"byzantine rite", img: "https://upload.wikimedia.org/wikipedia/commons/thumb/6/60/Cathedral_Uglich_inside_01.jpg/800px-Cathedral_Uglich_inside_01.jpg", note: "", children : [{name:"john-chrysostom", data:"john-chrysostom", title:"john chrysostom", img: "https://www.catholicer.com/liturgia/images/icon-john-chrysostom.jpg", note: "", children : []},]},{name:"chaldeans", data:"chaldeans", title:"east syrian rites", img: "https://www.catholicer.com/liturgia/images/icon-chaldeans.jpg", note: "", children : [{name:"chaldean", data:"chaldean", title:"syro-chaldean rites", img: "http://www.malankaraworld.com/images/church-photos/MulanthuruthyMarthomanInteriorm.jpg", note: "", children : []},{name:"malabar", data:"malabar", title:"syro-malabar", img: "https://www.catholicer.com/liturgia/images/icon-malabar.jpg", note: "", children : []},]},{name:"syrian", data:"syrian", title:"west syrian rites", img: "https://upload.wikimedia.org/wikipedia/commons/0/0b/Holy_mass_of_the_Syriac_Orthodox_Church.jpg", note: "", children : [{name:"antiochene", data:"antiochene", title:"syro-antiochene / syriac rite", img: "https://41.media.tumblr.com/036e1aa30be5e1553fd83af2b8d882be/tumblr_nh5n71c2CK1tey48vo1_500.jpg", note: "", children : []},{name:"malankara", data:"malankara", title:"syro-malankara rites", img: "https://upload.wikimedia.org/wikipedia/commons/d/db/Syro-Malankara_Holy_Mass_1.jpg", note: "", children : []},{name:"maronite", data:"maronite", title:"syro-maronite", img: "https://brooklynheightspress.files.wordpress.com/2011/10/bishops-at-altar__named-in-caption__img_4831.jpg", note: "", children : []},]},]},{name:"latin", data:"latin", title:"started in rome", img: "https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcRyFiLBsDlOcIopm2dcWcqEcyZmEZ-qwaSWuAz6Cq1Siv_XyyXbKg", note: "roman rites", children : [{name:"ambrozian", data:"ambrozian", title:"ambrozian", img: "https://traditionalaltarboy.files.wordpress.com/2015/08/img_0977.jpg", note: "milan area", children : []},{name:"mozarabic", data:"mozarabic", title:"mozarabic", img: "https://www.catholicer.com/liturgia/images/icon-mozarabic.jpg", note: "hispanic", children : []},{name:"novus-ordo", data:"novus-ordo", title:"novus ordo", img: "https://encrypted-tbn3.gstatic.com/images?q=tbn:ANd9GcRsb_FQ3wdLpVRS5coenbS16lfq9bppVzxrV1jLoRJUS1G6EiarRg", note: "current official roman catholic mass", children : []},{name:"novus-ordo-lectionary", data:"novus-ordo-lectionary", title:"novus ordo lectionary", img: "https://encrypted-tbn3.gstatic.com/images?q=tbn:ANd9GcRsb_FQ3wdLpVRS5coenbS16lfq9bppVzxrV1jLoRJUS1G6EiarRg", note: "current official roman lectionary for catholic mass", children : []},{name:"tridentine", data:"tridentine", title:"tridentine", img: "https://upload.wikimedia.org/wikipedia/commons/0/02/Missa_tridentina_002.jpg", note: "pre-vatican 2 mass", children : []},]},]}, ] } $scope.riteInfos = { 'actofcontrition' : '

Act of Contrition

An act of contrition is a Christian prayer genre that expresses sorrow for sins. It may be used in a liturgical service or be used privately, especially in connection with an examination of conscience.

','alexandrian' : '

Alexandrian Rite Family

The Alexandrian Rite is the liturgical rite used by the Coptic Catholic, Eritrean Catholic, and Ethiopian Catholic churches, as well as by those churches\' corresponding Orthodox Churches. The rite\'s divine liturgy contains elements from the liturgies of Saints Mark the Evangelist (who is traditionally regarded as the first bishop of Alexandria), Basil the Great, Cyril the Great, and Gregory Nazianzus. The Liturgy of Saint Cyril is a Coptic language translation from Greek of the Liturgy of Saint Mark.

','ambrozian' : '

Ambrosian Rite

also called the Milanese Rite, is a Catholic liturgical Western rite. The rite is named after Saint Ambrose, a bishop of Milan in the fourth century. The Ambrosian Rite, which differs from the Roman Rite, is used by some five million Catholics in the greater part of the Archdiocese of Milan, Italy (excluding, notably, the areas of Monza, Treviglio, Trezzo sull\'Adda and a few other parishes), in some parishes of the Diocese of Como, Bergamo, Novara, Lodi and in about fifty parishes of the Diocese of Lugano, in the Canton Ticino, Switzerland.

Although at various points in its history the distinctive Ambrosian Rite has risked suppression, it survived and was reformed after the Second Vatican Council partly because Pope Paul VI belonged to the Ambrosian \"rite\", having previously been Archbishop of Milan. In the 20th century it also gained prominence and prestige from the attentions of two other scholarly Archbishops of Milan: Achille Ratti, later Pope Pius XI, and the Blessed Ildefonso Schuster, both of whom had been involved in studies and publications on the rite before their appointment.

','angelus' : '

The Angelus

The Angelus (/ˈændʒələs/; Latin for angel) is a Catholic devotion commemorating the Incarnation. As with many Catholic prayers, the name Angelus is derived from its incipit: Angelus Domini nuntiavit Mariæ (... the Angel of the Lord declared unto Mary ...) and is practised by reciting as versicle and response three Biblical verses narrating the mystery; alternating with the prayer Hail Mary. The Angelus exemplifies a species of prayers called the prayer of the devotee. The devotion was traditionally recited in Roman Catholic churches, convents, and monasteries three times daily: 6:00 am, noon, and 6:00 pm

','anima-christi' : '

The Anima Christi

The Anima Christi is a prayer from around the 14th century. It is still widely used after receiving the body and blood of Our Lord, Jesus Christ in Holy Communion.

','antioch' : '

Antiochian Rite Family

The family of liturgies include the Apostolic Constitutions; then that of St. James in Greek, the Syriac Liturgy of St. James, and the other Syriac Anaphoras. The line may be further continued to the Byzantine Rite (the older Liturgy of St. Basil and the later and shorter one of St. John Chrysostom), and through it to the Armenian use

','antiochene' : '

Antiochene Rite

The family of liturgies include the Apostolic Constitutions; then that of St. James in Greek, the Syriac Liturgy of St. James, and the other Syriac Anaphoras. The line may be further continued to the Byzantine Rite (the older Liturgy of St. Basil and the later and shorter one of St. John Chrysostom), and through it to the Armenian use.

','apostle-creed' : '

The Apostle\'s Creed

The title Symbolum Apostolicum (Symbol or Creed of the Apostles) appears for the first time in a letter, probably written by Ambrose, from a Council in Milan to Pope Siricius in about 390 AD \'Let them give credit to the Creed of the Apostles, which the Roman Church has always kept and preserved undefiled\'. But what existed at that time was not what is now known as the Apostles\' Creed but a shorter statement of belief that, for instance, did not include the phrase \'maker of heaven and earth\', a phrase that may have been inserted only in the 7th century

','armenian' : '

Armenian Rite

The liturgy is patterned after the directives of Saint Gregory the Illuminator, founder and patron saint of The Armenian Church. Unlike the Byzantine Church, churches of the Armenian rite are usually devoid of icons and have a curtain concealing the priest and the altar from the people during parts of the liturgy, an influence from early apostolic times. The use of bishop\'s mitre and of unleavened bread, is reminiscent of the influence Western missionaries once had upon the Armenian Rite Catholics.

','axion-estin' : '

Axion Estin

Axion estin (Greek: Ἄξιον ἐστίν, Slavonic: Достóйно éсть, Dostóino yesť), or It is Truly Meet, is a megalynarion and a theotokion, i.e. a magnification of and a Hymn to Mary which is chanted in the Divine Services of the Eastern Orthodox and Eastern Catholic Churches. It is a troparion and a sticheron composed in honor of the Theotokos (i.e. the Virgin Mary). The same name also refers to a style of icon of the Theotokos.

','byzantine' : '

Byzantine Rite

The Byzantine Rite, also known as the Greek Rite, Rite of Constantinople or Constantinopolitan Rite, is the liturgical rite currently used by the Eastern Orthodox Church and some Eastern Catholic churches. Its development began during the third century in Constantinople and it is now the second most-used rite in Christendom after the Roman Rite.

The rite consists of the divine liturgies, canonical hours, forms for the administration of sacred mysteries (sacraments) and the numerous prayers, blessings and exorcisms developed by the Church of Constantinople.

Also involved are the specifics of architecture, icons, liturgical music, vestments and traditions which have evolved over the centuries in the practice of this rite. Traditionally, the congregation stands throughout the whole service, and an iconostasis separates the sanctuary from the nave of the church. The faithful are very active in their worship, making frequent bows and prostrations, and feeling free to move about the temple (church building) during the services. Also, traditionally, the major clergy and monks neither shave nor cut their hair or beards.

','canticle-mary' : '

Magnificat (Canticle of Mary) / Ode of the Theotokos

a canticle frequently sung or spoken liturgically in Christian church services. It is one of the eight most ancient Christian hymns and perhaps the earliest Marian hymn.

','canticle-zechariah' : '

Benedictus (Song of Zechariah)

The Benedictus was the song of thanksgiving uttered by Zechariah on the occasion of the circumcision of his son, John the Baptist.

','chaldean' : '

Easy Syrian (Chaldean) Rite

The Chaldean Catholic Church uses the East Syrian Rite. A slight reform of the liturgy was effective since 6 January 2007, and it aimed to unify the many different uses of each parish, to remove centuries-old additions that merely imitated the Roman Rite, and for pastoral reasons. The main elements of variations are: the Anaphora said aloud by the priest, the return to the ancient architecture of the churches, the restoration of the ancient use where the bread and wine are readied before a service begins, and the removal from the Creed of the Filioque clause.

','chaldeans' : '

East Syrian Rite Family

also known as the Thomasine Rite, Assyrian-Chaldean Rite, Assyrian Rite and the Persian Rite, originated in Edessa, Mesopotamia. It was used historically in the Church of the East, and remains in use in churches descended from it; namely the Assyrian Church of the East, the Ancient Church of the East, the Chaldean Catholic Church, and the Syro-Malabar Catholic Church. The latter two churches are Eastern Catholic Churches in full communion with the Holy See.

','coptic' : '

Coptic Rite

alexandrian rite used in Egypt

','decent-holy-spirit' : '','divinemercy' : '

Divine Mercy

prayer Jesus asked St. Faustina to share to the whole world, calling for Jesus\' mercy and to state trust in Him\"

','doc-council-2nd-vatican' : '

Second Vatican Council

Second Vatican Council, popularly called Vatican II, 1962–65, the 21st ecumenical council (see council, ecumenical) of the Roman Catholic Church, convened by Pope John XXIII and continued under Paul VI. Its announced purpose was spiritual renewal of the church and reconsideration of the position of the church in the modern world. The most spectacular innovation of the council, which convened Oct. 11, 1962, was the invitation extended to Protestant and Orthodox Eastern churches to send observers; the meetings were attended by representatives from many of those churches. Another obvious feature was the diversity of national and cultural origins shown among those who attended from all over the world.

','doc-council-2nd-vatican-Ad-Gentes' : '

Ad Gentes

','doc-council-2nd-vatican-Apostolicam-Actuositatem' : '

Apostolicam Actuositatem

','doc-council-2nd-vatican-Christus-Dominus' : '

Christus Dominus

','doc-council-2nd-vatican-Dei-Verbum' : '

Dei Verbum

','doc-council-2nd-vatican-Dignitatis-Humanae' : '

Dignitatis Humanae

','doc-council-2nd-vatican-Gaudium-et-Spes' : '

Gaudium et Spes

','doc-council-2nd-vatican-Gravissimum-Educationis' : '

Gravissimum Educationis

','doc-council-2nd-vatican-Inter-Mirifica' : '

Inter Mirifica

','doc-council-2nd-vatican-Lumen-Gentium' : '

Lumen Gentium

','doc-council-2nd-vatican-Nostra-Aetate' : '

Nostra Aetate

','doc-council-2nd-vatican-Optatam-Totius' : '

Optatam Totius

','doc-council-2nd-vatican-Orientalium-Ecclesiarum' : '

Orientalium Ecclesiarum

','doc-council-2nd-vatican-Perfectae-Caritatis' : '

Perfectae Caritatis

','doc-council-2nd-vatican-Presbyterorum-Ordinis' : '

Presbyterorum Ordinis

','doc-council-2nd-vatican-Sacrosanctum-Concilium' : '

Sacrosanctum Concilium

','doc-council-2nd-vatican-Unitatis-Redintegratio' : '

Unitatis Redintegratio

','doc-early-christian-epistle-barnabas' : '

The Epistle of Barnabas

','doc-early-christian-epistle-on-arianism' : '

Epistles on Arianism & the deposition of Arius

(Alexander of Alexandria)

','doc-early-christian-epistle-polycarp' : '

The Epistle of Polycarp

','doc-early-christian-ignatius-polycarp' : '

Ignatius to Polycarp

','doc-early-christian-martyrdom-polycarp' : '

The Martyrdom of Polycarp

','doc-pope-francis' : '

Documents by Pope Francis

','doc-pope-francis-laudato-si' : '

Laudato Si

','entrance-of-theotokos' : '','ethiopean' : '

Ethiopean Rite

The Ethiopian rite is one of the oldest rites and is used by the Ethiopian Orthodox Church as well as by that group which is in full communion with the Church of Rome, The Ethiopian Catholic Church. In its essential elements, it stems from the Alexandrian rite and the language used in the services is classical Ethiopian called Ge’ez. Because local documents are lacking, it is difficult to reconstruct the history of the Ethiopian rite, and to study the various phases through which it attained its actual form. This lack of historical witness is the result of politico-religious upheavals that led to the destruction of the literary and archeological patrimony to do with the liturgy.

','glorybe' : '

Glory be

The Glory Be prayer reaffirms the eternal glory of our \'God in Three Persons, Blessed Trinity,\' as our Triune God is called in the well known hymn Holy Holy Holy. Let us try each day, in reciting this prayer and others, to be open to God’s graces, so that we may live our lives as hymns of praise to Our Creator.

','glorybe-arabic' : '

Glory be Prayer

Arabic version

','glorybe-english' : '

Glory be Prayer

English version

','glorybe-greek' : '

Glory be Prayer

Greek version

','glorybe-mozarabic' : '

Glory be Prayer

Mozarabic version

','glorybe-roman' : '

Glory Be Prayer

The Roman version

','hail-holy-queen' : '

Hail Holy Queen

','hailmary' : '

Hail Mary

Repetition of Elizabeth\'s greeting to Mary with requesting for her prayer for us now and at the end of our life

','hailmary-greek' : '

Hail Mary

in greek tradition

','hailmary-latin' : '

Hail Mary

in latin tradition

','hailmary-slavonic' : '

Hail Mary

in slavonic tradition

','icon-nativity' : '','icon-theophany' : '','icon-theotokos' : '','icons' : '

Byzantine Icons

integral liturgical tool in the byzantine liturgies

','jesus-prayer' : '

Jesus Prayer

The Jesus\' Prayer is a short formulaic prayer esteemed and advocated especially within the Eastern churches: Lord Jesus Christ, Son of God, have mercy on me, a sinner.

','john-chrysostom' : '

The Divine Liturgy of Saint John Chrysostom

The Divine Liturgy of Saint John Chrysostom is the most celebrated Divine Liturgy in the Byzantine Rite. It is named after the anaphora with the same name which is its core part and it is attributed to Saint John Chrysostom, Archbishop of Constantinople in the 5th century.It reflects the work of the Cappadocian Fathers to both combat heresy and define Trinitarian theology for the Christian Church. The Liturgy of St. John Chrysostom was probably the divine liturgy used originally by the School of Antioch and was, therefore, most likely developed from West Syrian liturgical rites. In Constantinople, it was refined and beautified under John\'s guidance as Patriarch of Constantinople (398–404). Having become the liturgical form of the Church of Holy Wisdom, Hagia Sophia, it became over time the normative liturgical form in the churches within the Byzantine Empire. The two liturgical rites of St. John Chrysostom and St. Basil in the Eastern Church became the norm by the end of the reign of Justinian I

','kyrie-eleison' : '

Kyrie eleison

Asking the Lord God to grant us his infinite mercy

','latin' : '

Latin / Roman Rite Family

Latin liturgical rites used within that area of the Catholic Church where the Latin language once dominated (the Latin Church) were for many centuries no less numerous than the liturgical rites of the Eastern autonomous particular Churches. Their number is now much reduced. In the aftermath of the Council of Trent, in 1568 and 1570 Pope Pius V suppressed the Breviaries and Missals that could not be shown to have an antiquity of at least two centuries (see Tridentine Mass and Roman Missal). Many local rites that remained legitimate even after this decree were abandoned voluntarily, especially in the 19th century. In the second half of the 20th century, most of the religious orders that had a distinct liturgical rite chose to adopt in its place the Roman Rite as revised in accordance with the decrees of the Second Vatican Council (see Mass of Paul VI). A few such liturgical rites persist today for the celebration of Mass, since 1965-1970 in revised forms, but the distinct liturgical rites for celebrating the other sacraments have been almost completely abandoned.

','letters' : '

Letters

Letters written by saints

','litany-of-humility' : '

Litany of Humility

This Litany is commonly attribted to Rafael Cardinal Merry del Val (1865-1930), Cardinal Secretary of State of the Holy See under Pope Saint Pius X, but there is scant evidence of this. Father Charles Belmonte, S.Th.D., a priest of the Opus Dei Prelature, who was inspired by the writings of the Cardinal, included it in a collection, the Handbook of Prayers

','litany-of-loretto' : '

Litany of Loretto

Unknown source but the Church approved 1587 as a litany in the Church

','liturgies' : '

Liturgies

The Catholic Churches celebrate liturgies in various forms every day since the 12 apostles travelled throughout the Mediterranean area and many other countries to preach the Gospel of Christ. As Christian apostles, they were all worshiping God in Jewish service form but replacing the Torah with the Good news of Jesus Christ as its fulfillment and the animal sacrifice with Jesus\' sacrifice of the new covenant in the breaking of Bread, Eucharist, as the eternal and purest Sacrifice.

The Church started by apostles picked up different styles of celebrating this service most of us now call \"Holy Mass\" taking the influence the apostles brought them, but there was no 1 dictated form how to celebrate them. Later on, a couple more important saints also try to formalize a new form for different reasons, one of which was an attempt to act in accord to the result of ecumenical councils. Liturgy of the Mass is usually called in different names too, such as Divine Liturgy, Holy Qurbana, Divine Mysteries and so on.

','malabar' : '

Malabar Rite

a conventional term for certain customs or practices of the native Catholics of South India, concerning the liturgical rites, which the Jesuit missionaries allowed their Indian neophytes to retain after conversion but were afterwards prohibited by Rome.

Now Malabar Rite is well used to describe the rite of the 2nd biggest sui iuris Catholic Church, the Syro-Malabar Church

','malankara' : '

Malankara Rite

The Malankara Rite or Syro-Malankara Rite is the form of the West Syrian liturgical rite practiced by several churches of the Saint Thomas Christian tradition in southern India. West Syrian liturgy was brought to India by the Syriac Orthodox Bishop of Jerusalem, Gregorios Abdul Jaleel, in 1665; in the following decades the Malankara Rite emerged as the liturgy of the Malankara Church, one of the two churches that evolved from the split in the Saint Thomas Christian community in the 17th century. Today it is practiced by the various churches that descend from the Malankara Church, namely the Malankara Orthodox Syrian Church, the Jacobite Syrian Christian Church, the Syro-Malankara Catholic Church, the Malabar Independent Syrian Church, and the Mar Thoma Syrian Church.

','maronite' : '

Maronite Rite

Descended from Syrian Rite, used in Maronite Catholic Church

','meal-prayer' : '

Mealtime Blessings

Prayer before or after meals

','meal-prayer-greek' : '

Prayer before and after meals in Greek Byzantine Tradition

','meal-prayer-latin' : '

Prayer before and after meals in Latin Tradition

The prayers should be said aloud by the head of the table who prays for all present. When two persons of equal standing are beginning a meal, one should offer the other the honor of praying for both.

','meal-prayer-ukraine' : '

Prayer before and after meals in Ukrainian Byzantine Tradition

','mozarabic' : '

Mozarabic Rite

The Mozarabic Rite, also called the Visigothic Rite or the Hispanic Rite, is a form of Christian worship within the Latin Catholic Church. Its beginning dates to the 7th century, and is localized in the Iberian Peninsula (Hispania). \"Mozarab\" was originally an Islamic term for the Visigothic Christians that lived under Muslim rulers in Al-Andalus. The Visigothic/ Mozarabic Rite\'s origins predates the Al-Andalus to the time of the Christian Visigothic Kingdom. The rite was superseded by the Roman Rite as part of a wider programme of liturgical standardization within the Catholic Church.

','nicene-constantinopolitan-creed' : '

The Nicene Constantinopolitan Creed

It is called Nicene /ˈnaɪsiːn/ because it was originally adopted in the city of Nicaea (present day Iznik, Turkey) by the First Council of Nicaea in 325. In 381, it was amended at the First Council of Constantinople, and the amended form is referred to as the Nicene or the Niceno-Constantinopolitan Creed.

','nicene-creed' : '

The Nicene Creed

(Greek: Σύμβολον τῆς Νικαίας or τῆς πίστεως, Latin: Symbolum Nicaenum) is a profession of faith widely used in Christian liturgy.

','novus-ordo' : '

New Order of The Mass

The Mass of Paul VI is a form of Mass in the Catholic Church, promulgated by Pope Paul VI in 1969 after the Second Vatican Council (1962-1965). It is now the ordinary or standard form of the Roman Rite Mass.

','novus-ordo-lectionary' : '

Ordinary Roman Calendar Lectionary

The Church Lectionary for ordinary mass

','o-salutaris-hostia' : '

O Salutaris Hostia

Written by St. Thomas Aquinas O.P. for the Solemnity of Corpus Christi

','ourfather' : '

The Lord\'s Prayer

When you pray, you are not to be like the hypocrites; for they love to stand and pray in the synagogues and on the street corners so that they may be seen by men. Truly I say to you, they have their reward in full. But you, when you pray, go into your inner room, close your door and pray to your Father who is in secret, and your Father who sees what is done in secret will reward you. And when you are praying, do not use meaningless repetition as the Gentiles do, for they suppose that they will be heard for their many words. So do not be like them; for your Father knows what you need before you ask Him. Pray, then, in this way:

Our Father who is in heaven, Hallowed be Your name. Your kingdom come. Your will be done, On earth as it is in heaven. Give us this day our daily bread. And forgive us our debts, as we also have forgiven our debtors. And do not lead us into temptation, but deliver us from evil. [For Yours is the kingdom and the power and the glory forever. Amen.]

For if you forgive others for their transgressions, your heavenly Father will also forgive you. But if you do not forgive others, then your Father will not forgive your transgressions.

','pange-lingua' : '

Pange Lingua

Written by St. Thomas Aquinas O.P. for the Solemnity of Corpus Christi

','pantocrator' : '','prayer-guardian-angel' : '

Prayer to Your Guardian Angel

','prayers' : '

Catholic Prayers & Hymns

To achieve holiness it is indispensable to maintain a constant conversation with God, or, to put it in another way, to pray. This does not consist only in the repetition of vocal prayers; it means talking with God, bringing into play all our human capacities: soul and body, head and heart, doctrine and affections. Being holy means being like Jesus Christ; the more closely we imitate him and the more we become like him, developing the sacramental identification received in Baptism, with the help of grace and through our own efforts, the greater the holiness and identification with the Master we will achieve. Hence the importance of that “constant conversation” with Jesus. “Sanctity, without prayer?” St Josemaría asked himself in one of his most widely-known books. And he replies concisely, “I don’t believe in such sanctity” (The Way, 107).

','rosary' : '

Rosary

A form of devotion loved by Our Lady, where we meditate on the life of Jesus and Mary.

','rosary-seven-sorrows' : '

Seven Sorrows Rosary

The Blessed Virgin Mary grants seven graces to the souls who honor her daily by saying seven Hail Mary\'s and meditating on her tears and dolors. The devotion was passed on by St. Bridget.


Here Are the Seven Graces:

  1. I will grant peace to their families.
  2. They will be enlightened about the divine mysteries.
  3. I will console them in their pains and I will accompany them in their work.
  4. I will give them as much as they ask for as long as it does not oppose the adorable will of my divine Son or the sanctification of their souls.
  5. I will defend them in their spiritual battles with the infernal enemy and I will protect them at every instant of their lives.
  6. I will visibly help them at the moment of their death, they will see the face of their Mother.
  7. I have obtained from my divine Son, that those who propagate this devotion to my tears and dolors, will be taken directly from this earthly life to eternal happiness since all their sins will be forgiven and my Son and I will be their eternal consolation and joy.

 

','st-joseph-byzantine' : '

Hymn to St. Joseph

in Byzantine Liturgy

','st-michael-the-archangel' : '

Prayer to St. Michael the Archangel

The Prayer to Saint Michael usually refers to one Catholic prayer to Michael the Archangel, among the various prayers in existence that are addressed to him. This prayer was incorporated into the rubrics of the Low Mass of the Catholic Church from 1886 to its suppression in 1964.

','syrian' : '

West Syrian Rite Family

The West Syrian Rite, also known as the Syrian Rite or the Syro-Antiochene Rite, is a Christian liturgical rite chiefly practiced in the Syriac Orthodox Church and churches related to or descended from it. It is part of the liturgical family known as the Antiochene Rite, which originated in the ancient Patriarchate of Antioch. This rite has a great number of anaphoras - in fact, more than any other rite. The rite is practiced in the Syriac Orthodox Church, an Oriental Orthodox body; the Syriac Catholic Church, an Eastern Catholic Church in full communion with the Holy See; and to a great extent in the Maronite Church, another Eastern Catholic body. A regional variant, the Malankara Rite, developed in the Malankara Church of India, and is still practiced in its descendant churches.

','tantum-ergo' : '

Tantum Ergo Sacramentum

Part of Pange Lingua, written by St. Thomas Aquinas O.P. for the Solemnity of Corpus Christi

','teachings' : '

Teaching Documents

Encyclicals, Council, and Exhortations, and other teaching documents

','tridentine' : '

The Mass

The Tridentine Mass is the Roman Rite Mass which appears in typical editions of the Roman Missal published from 1570 to 1962. The most widely used Mass liturgy in the world until the introduction of the Mass of Paul VI in 1969, it is celebrated in Liturgical Latin.

','trisagion' : '

Trisagion

sometimes called by its opening line Agios O Theos, is a standard hymn of the Divine Liturgy in most of the Eastern Catholic churches.

','veni-sancte-spiritus' : '

Come, Holy Spirit

prayer for guidance from the Spirit

','watch-o-lord' : '

Watch O Lord

Night prayer composed by St. Augustine

', }; $scope.cService.api.validate("Svg4Mjw091",function(d){ if (d.success) { $scope.cService.adminAccess = d.data.membership == "admin"; $scope.cService.userOwnerships = !d.data.ownership || d.data.ownership==""? [] : d.data.ownership.split(","); $scope.cService.loggedIn = true; $scope.cService.userId = d.data.id; $scope.cService.userEntityId = d.data.entity_id; $scope.cService.determineAccessRight(location.pathname); // $scope.$apply(); } else { $scope.cService.showLogin = true; $scope.language = $scope.getRite().children.length==0 && window.requestedLanguage ? $scope.availableLanguages.find(function(l){return l.name===window.requestedLanguage}) : $scope.availableLanguages[0]; } }); $scope.loading = false; $scope.isLoading = function () { return $scope.loading; } $scope.document = {}; $scope.paths = []; $scope.getRiteString = function(forUrl) { var s = ""; var rites = $scope.rites; for (var i in $scope.paths) { if (typeof($scope.paths[i])=="number") rites = rites.children[$scope.paths[i]]; else if (typeof($scope.paths[i])=="string" && $scope.paths[i].length>0) rites = rites.children.find(function(r){ return r.data===$scope.paths[i]; }); if (forUrl) s += rites.data+"/"; else s += rites.name+", "; } if (forUrl) s = s.substring(0,s.length-1); return s; } $scope.getRite = function() { var rites = $scope.rites; for (var i in $scope.paths) { if (typeof($scope.paths[i])=="number") rites = rites.children[$scope.paths[i]]; else if (typeof($scope.paths[i])=="string" && $scope.paths[i].length>0) rites = rites.children.find(function(r){ return r.data===$scope.paths[i]; }); } if (rites.children.length == 0) $("#leftOption").fadeIn(); else $("#leftOption").fadeOut(); return rites; } $scope.filterText = {"title":""}; $scope.addRitePath = function(path) { $scope.filterText = {title:""}; if (path==undefined || path==="") return; if (typeof(path)=="object") $scope.paths = path; else $scope.paths.push(path); var current = $scope.getRite() $analytics.eventTrack('liturgy: '+$scope.getRiteString(), { category: 'liturgia-path' }); if (current.children.length == 0) { if (typeof(path)=="number" || typeof(path)=="string") location.href = "/liturgia/"+$scope.defaultLanguage.name+"/"+$scope.getRiteString(true); $scope.document = {}; $scope.loading = true; $scope.cService.entryRaw($scope.document, "liturgy",current.data, function(data){ $scope.loading = false; if (data.liturgy) $scope.document = data.liturgy; if (!$scope.document || !$scope.document.id) { // liturgy not found $scope.document = { id : current.data, liturgy_id : null, previous_id : null }; $scope.cService.api.add("liturgy",$scope.document,function(){ $scope.document.liturgy = []; $scope.document.liturgical_text = []; // console.log("CREATED"); }) } // sort liturgy document parts $scope.sortLiturgicalTexts($scope.document); // add all languages // for (var i in $scope.availableLanguages) // if ($scope.availableLanguages[i].name != "?") // $scope.forceAddText($scope.document,$scope.availableLanguages[i]); }); } $("#liturgyInfo").hide(); $("#liturgyInfo").fadeIn(); } $scope.sortLiturgicalTexts = function(lit) { var n = [] var last = null; while (lit.liturgy.length > 0) { for (var i in lit.liturgy) if (lit.liturgy[i].previous_id == last) { $scope.sortLiturgicalTexts(lit.liturgy[i]); n.push(lit.liturgy[i]); last = lit.liturgy[i].id; lit.liturgy.splice(i,1); break; } } lit.liturgy = n; } $scope.languageDocumentExists = function(liturgy, lang) { var found = false; // if ($scope.cService.adminAccess) return true for (var i in liturgy.liturgical_text) if (liturgy.liturgical_text[i].language == lang.name) { found = true; if (lang.name == $scope.autoAccumulateDataLanguage) { var lid = liturgy.liturgical_text[i].liturgy_id; if ($scope.autoAccumulateData[lid+":content"]) liturgy.liturgical_text[i].content = $scope.autoAccumulateData[lid+":content"]; if ($scope.autoAccumulateData[lid+":title"]) liturgy.liturgical_text[i].title = $scope.autoAccumulateData[lid+":title"]; if ($scope.autoAccumulateData[lid+":note"]) liturgy.liturgical_text[i].note = $scope.autoAccumulateData[lid+":note"]; } break; } return found; } $scope.forceAddText = function (x,lang) { // find existing language & add if it doesnt exist if (lang.name != '?' && !$scope.languageDocumentExists(x,lang)) { x.liturgical_text.push( {liturgy_id: x.id, language: lang.name, title: x.id, content: "", note: null, type: null, liturgy: [ ], liturgical_text: [ ]}); } for (var l in x.liturgy) $scope.forceAddText(x.liturgy[l],lang); } $scope.leftButtonClicked = function() { $scope.chooseLanguage=true; $("#leftRequestButton").show(); } $scope.rightButtonClicked = function() { $scope.filterText = {title:""}; if ($scope.paths.length == 0) { $scope.chooseMainLanguage = true; return; } $scope.paths.pop(); $scope.chooseLanguage = false; $scope.language=$scope.availableLanguages[0]; $("#rightRequestButton").show(); $("#liturgyInfo").hide(); $("#liturgyInfo").fadeIn(); } _scope = $scope; $scope.autoAccumulateDataLanguage = "el"; $scope.autoAccumulateData = {}; // $.get("http://catholicer.com/liturgia/temp/st-john-greek.json",function(data) { // $scope.autoAccumulateData = data; // }); $scope.getCurrentName = function() { return $scope.getRite().title } $scope.availableLanguages = [ {name:"?", title:"document information", img:window.path+"/images/info.png"}, {name:"en", title:"english", img:window.path+"/images/lang-en.png", note:"", data: true}, {name:"la", title:"latin", img:window.path+"/images/lang-la.png", note:"", data: true}, {name:"sla", title:"slavonic", img:window.path+"/images/lang-sla.png", note:"", data: true}, {name:"el", title:"greek", img:window.path+"/images/lang-el.png", note:"", data: true}, {name:"aii", title:"assyrian aramaic", img:window.path+"/images/lang-aii.png", note:"", data: true}, {name:"it", title:"italian", img:window.path+"/images/lang-it.png", note:"", data: true}, {name:"fr", title:"french", img:window.path+"/images/lang-fr.png", note:"", data: true}, {name:"pl", title:"polish", img:window.path+"/images/lang-pl.png", note:"", data: true}, {name:"ar", title:"arabic", img:window.path+"/images/lang-ar.png", note:"", data: true}, {name:"es", title:"spanish", img:window.path+"/images/lang-es.png", note:"", data: true}, {name:"id", title:"indonesian", img:window.path+"/images/lang-id.png", note:"", data: true}, {name:"ja", title:"japanese", img:window.path+"/images/lang-ja.png", note:"", data: true}, {name:"zh-Hant", title:"chinese", img:window.path+"/images/lang-zh-Hant.png", note:"", data: true}, {name:"gez", title:"ge'ez", img:window.path+"/images/info.png", note:"", data: true}, {name:"amh", title:"amharic", img:window.path+"/images/info.png", note:"", data: true}, {name:"fil", title:"philippine", img:window.path+"/images/info.png", note:"", data: true}, ]; $scope.language = $scope.availableLanguages[0]; $scope.defaultLanguage = window.requestedLanguage ? $scope.availableLanguages.find(function(l){return l.name===window.requestedLanguage}) : $scope.availableLanguages[1]; $scope.selectLanguage = function(lang) { if ($scope.chooseMainLanguage) $scope.defaultLanguage = lang; else { $scope.language = lang; // for admin access to create new language if ($scope.cService.adminAccess) $scope.forceAddText($scope.document,lang); } $scope.chooseMainLanguage = false; $scope.chooseLanguage = false; } $scope.getCurrentLanguage = function() { return $scope.language; } $scope.hasCompleteLiturgicalText = function() { if ($scope.cService.adminAccess) return true; if ($scope.document.liturgy) { for (var t in $scope.document.liturgy) { for (var l in $scope.document.liturgy[t].liturgical_text) if ($scope.document.liturgy[t].liturgical_text[l].language == $scope.language.name) return true; } } for (var l in $scope.document.liturgical_text) if ($scope.document.liturgical_text[l].language == $scope.language.name) return true; return false; } $scope.hasCompleteLiturgicalTextInDefaultLanguage = function() { if ($scope.cService.adminAccess) return true; if ($scope.document.liturgy) { for (var t in $scope.document.liturgy) { for (var l in $scope.document.liturgy[t].liturgical_text) if ($scope.document.liturgy[t].liturgical_text[l].language == $scope.defaultLanguage.name) return true; } } for (var l in $scope.document.liturgical_text) if ($scope.document.liturgical_text[l].language == $scope.defaultLanguage.name) return true; return false; } $scope.requestDocument = function(e) { $("#leftRequestButton").fadeOut(); $.post("/api/notify", JSON.stringify({ subject: "request for liturgia document", message: "user "+$scope.cService.userId+" (https://www.catholicer.com/profile/"+$scope.cService.userEntityId+") asks for "+$scope.getRiteString() + " in " + $scope.language.title + " from " + window.clientIp }), function (data) {}, "json"); } $scope.requestDocumentInDefaultLanguage = function(e) { $("#rightRequestButton").fadeOut(); $.post("/api/notify", JSON.stringify({ subject: "request for liturgia document", message: "user "+$scope.cService.userId+" (https://www.catholicer.com/profile/"+$scope.cService.userEntityId+") asks for "+$scope.getRiteString() + " in " + $scope.defaultLanguage.title + " from " + window.clientIp }), function (data) {}, "json"); } $scope.getLiturgy = function(x) { return x.liturgy; } $scope.gotoCatholicer = function() { document.location.href= "/default.php"; } if (window.requestedPath) $scope.addRitePath(window.requestedPath.filter(function(n){ return n != "" })); }] ).directive('homepage', function() { return { restrict: 'E', templateUrl: window.path+'/view/homepage.html' }; }).directive('liturgy', ["RecursionHelper", function(RecursionHelper) { return { restrict: 'E', scope: { liturgy : '=', language : '=', editing : '=' }, templateUrl: window.path+'/view/liturgy.html', compile : function( element){ return RecursionHelper.compile(element); }, link : { post : function(scope, element) { } } } }]).directive('structure', ["RecursionHelper", function(RecursionHelper) { return { restrict: 'E', scope: { liturgy : '=', language : '=', parent : '=', editing : '=' }, templateUrl: window.path+'/view/structure.html', compile : function( element){ return RecursionHelper.compile(element); }, } }]).directive('info', function() { return { restrict: 'E', scope: { page : '@', }, templateUrl: window.path+'/view/info.html' }; }).directive('picklanguage', function() { return { restrict: 'E', templateUrl: window.path+'/view/language.html', }; }).factory('RecursionHelper', ['$compile', function($compile){ return { /** * Manually compiles the element, fixing the recursion loop. * @param element * @param [link] A post-link function, or an object with function(s) registered via pre and post properties. * @returns An object containing the linking functions. */ compile: function(element, link){ // Normalize the link parameter if(angular.isFunction(link)){ link = { post: link }; } // Break the recursion loop by removing the contents var contents = element.contents().remove(); var compiledContents; return { pre: (link && link.pre) ? link.pre : null, /** * Compiles and re-adds the contents */ post: function(scope, element){ // newValue = newValue.split(":").join("-"); // var i = setInterval(function() { // if ($scope.language.name != "?" && $('#content-'+newValue+'-'+$scope.language.name).get(0) && $('#note-'+newValue+'-'+scope.language.name).get(0)) { // tinymce.init({ // selector:'#content-'+newValue+'-'+$scope.language.name, // menubar : false, // toolbar : 'styleselect | bold italic underline | bullist numlist outdent indent | link image | preview media fullpage | forecolor backcolor emoticons', // plugins: [ 'advlist autolink link image lists charmap print preview hr anchor pagebreak spellchecker', // 'searchreplace wordcount visualblocks visualchars code fullscreen insertdatetime media nonbreaking', // 'save table contextmenu directionality emoticons template paste textcolor' ], // }); // tinymce.init({ // selector:'#note-'+newValue+'-'+$scope.language.name, // menubar : false, // toolbar : 'styleselect | bold italic underline | bullist numlist outdent indent | link image | preview media fullpage | forecolor backcolor emoticons', // plugins: [ 'advlist autolink link image lists charmap print preview hr anchor pagebreak spellchecker', // 'searchreplace wordcount visualblocks visualchars code fullscreen insertdatetime media nonbreaking', // 'save table contextmenu directionality emoticons template paste textcolor' ], // }); // clearInterval(i); // } // }, 500); scope.$watch("liturgy.id", function(newValue) { if (scope.editing && newValue) { newValue = newValue.split(":").join("-"); var i = setInterval(function() { if (scope.language.name != "?" && $('#content-'+newValue+'-'+scope.language.name).get(0) && $('#note-'+newValue+'-'+scope.language.name).get(0)) { tinymce.init({ selector:'#content-'+newValue+'-'+scope.language.name, menubar : false, toolbar : 'styleselect | bold italic underline | bullist numlist outdent indent | link image | preview media fullpage | forecolor backcolor emoticons', plugins: [ 'advlist autolink link image lists charmap print preview hr anchor pagebreak spellchecker', 'searchreplace wordcount visualblocks visualchars code fullscreen insertdatetime media nonbreaking', 'save table contextmenu directionality emoticons template paste textcolor' ], }); tinymce.init({ selector:'#note-'+newValue+'-'+scope.language.name, menubar : false, toolbar : 'styleselect | bold italic underline | bullist numlist outdent indent | link image | preview media fullpage | forecolor backcolor emoticons', plugins: [ 'advlist autolink link image lists charmap print preview hr anchor pagebreak spellchecker', 'searchreplace wordcount visualblocks visualchars code fullscreen insertdatetime media nonbreaking', 'save table contextmenu directionality emoticons template paste textcolor' ], }); clearInterval(i); } }, 500); } }); // Compile the contents if(!compiledContents){ compiledContents = $compile(contents); } // Re-add the compiled contents to the element compiledContents(scope, function(clone){ element.append(clone); }); // Call the post-linking function, if any if(link && link.post){ link.post.apply(null, arguments); } scope.includeSubliturgy = function(content, lang) { var subs = content.match(/\[%(\w+)%\]/g); _scope.subliturgies = _scope.subliturgies || {}; for (var i in subs) { var subName = subs[i].match(/\[%(\w+)%\]/)[1]; var subliturgy = {}; if (_scope.subliturgies[subName]) { if (_scope.subliturgies[subName].liturgical_text) { var c = _scope.subliturgies[subName].liturgical_text.find(function(x) { return x.language==lang; } ); if (c) return content.replace(subs[i],c.content); } } else { _scope.subliturgies[subName] = {}; _scope.cService.entryRaw(subliturgy, "liturgy",subName, function(data){ if (data.liturgy) _scope.subliturgies[subName] = data.liturgy; }); } } return content; } scope.save = function (liturgy,lang) { for (var t in liturgy.liturgical_text) { var text = liturgy.liturgical_text[t]; if (text.language==lang) { if (text.title) text.title.replaceAll("

",""); text.content = tinyMCE.get('content-'+liturgy.id.split(":").join("-")+'-'+lang).getContent({format : 'raw'}); text.note = tinyMCE.get('note-'+liturgy.id.split(":").join("-")+'-'+lang).getContent({format : 'raw'}); // if (text.note) text.note.replaceAll("

",""); // if (text.content) text.content.replaceAll("

",""); var packet = { liturgy_id: text.liturgy_id, note: text.note, title: text.title, language: text.language, content: text.content, }; if (text.id) { packet.id = text.id; _scope.cService.api.edit("liturgical_text",text.id,packet,function(){console.log("UPDATED");}) } else _scope.cService.api.add("liturgical_text",packet,function(){console.log("CREATED");}) } } for (var l in liturgy.liturgy) scope.save(liturgy.liturgy[l],lang); } scope.sectionClicked = function (s) { document.getElementById(_scope.language.name+':'+s).scrollIntoView(); document.getElementById(_scope.defaultLanguage.name+':'+s).scrollIntoView(); } scope.reformat = function(text,str) { text.content = text.content.replaceAll("

",""); } scope.saveStructureHelper = function (liturgy) { if (liturgy.length > 0 ) { var l = liturgy[0]; var packet = { id : l.id, liturgy_id: l.liturgy_id, previous_id: l.previous_id }; liturgy.shift(); if (l.liturgical_text) { _scope.cService.api.edit("liturgy",l.id,packet,function(){console.log("UPDATED"); scope.saveStructureHelper(liturgy); if (l.liturgy.length>0) scope.saveStructureHelper(l.liturgy); }) } else _scope.cService.api.add("liturgy",packet,function(){console.log("CREATED"); scope.saveStructureHelper(liturgy); if (l.liturgy.length>0) scope.saveStructureHelper(l.liturgy); }) } } scope.saveStructure = function (liturgy) { var toUpdates = []; for (var t in liturgy.liturgy) toUpdates.push(liturgy.liturgy[t]); scope.saveStructureHelper(toUpdates); } scope.addInside = function (l) { var w = l.id.split(':'); var prefix = ""; for (var i=0;i< w.length-1;++i) prefix += w[i]+":"; if (w.length>1) w = w[1].split('-'); for (var i in w) if (w[i].length>0) prefix += w[i].substr(0,1); l.liturgy.push({ id: l+":", liturgy_id : l.id, previous_id : null, liturgy : [], }); } scope.addAfter = function (l,p) { var w = p.id.split(':'); var prefix = ""; for (var i=0;i< w.length-1;++i) prefix += w[i]+":"; w = w[w.length-1].split('-'); for (var i in w) if (w[i].length>0) prefix += w[i].substr(0,1); var n = { id: l+":", liturgy_id : p.id, previous_id : l.id, liturgy : [], }; for (var i in p.liturgy) if (p.liturgy[i].previous_id==l.id) { p.liturgy[i].previous_id = n.id; p.liturgy.splice(i,0,n); return; } p.liturgy.push(n); } scope.isLoading = function () { return _scope.loading; } } }; } }; }]).filter('unsafe', function($sce) { return function(val) { // if (val == "") val = " "; // val = val.replaceAll("

", "

") return $sce.trustAsHtml(val); }; }) app.controller('c-login', function($scope, $location, cService){ this.cService = cService; $scope.cService = cService; $scope.login = function() { var email = $scope.email; var pass = $scope.password; $scope.cService.api.login(email,pass,"Svg4Mjw091",function(d){ if (d.success) { $scope.cService.adminAccess = d.data.membership == "admin"; $scope.cService.userOwnerships = !d.data.ownership || d.data.ownership==""? [] : d.data.ownership.split(","); $scope.cService.loggedIn = true; $scope.cService.determineAccessRight(location.pathname); $scope.cService.showLogin = false; $scope.password = ""; document.location.reload(); } else $scope.status = d.message; }); } $scope.closeDialog = function() { $scope.cService.showLogin = false; } }).directive( 'login', function() { return { restrict: 'E', templateUrl: window.path+'/view/login.html', controller: "c-login", link: function(scope, element, attributes, controller) { } } }); // http://www.stpaulbrisbane.org/LiturgyInArabic.htm