/webtrees/app/Services/ |
H A D | GedcomImportService.php | 92 foreach ($matches as $n => $match) { 93 [, $level, $xref, $tag, $data] = $match; 157 … (preg_match('/(.*), (\d\d)(\d\d)(\d\d)([NS])(\d\d\d)(\d\d)(\d\d)([EW])$/', $data, $match) === 1) { 158 $degns = (int) $match[2]; 159 $minns = (int) $match[3]; 160 $secns = (int) $match[4]; 161 $degew = (int) $match[6]; 162 $minew = (int) $match[7]; 163 $secew = (int) $match[8]; 165 $match[1] . "\n" . [all …]
|
/webtrees/app/Report/ |
H A D | ReportParserGenerate.php | 237 …$ct = preg_match_all($searchTarget, $gedrec, $match, PREG_SET_ORDER | PREG_OFFSET_CAPTUR… 244 $pos1 = $match[$num - 1][0][1]; 304 if (preg_match("/^\\$(\w+)$/", $value, $match)) { 305 … if (isset($this->vars[$match[1]]['id']) && !isset($this->vars[$match[1]]['gedcom'])) { 306 $value = $this->vars[$match[1]]['id']; 705 if (preg_match('/\$(.+)/', $tag, $match)) { 706 if (isset($this->vars[$match[1]]['gedcom'])) { 707 $newgedrec = $this->vars[$match[1]]['gedcom']; 709 $tmp = Registry::gedcomRecordFactory()->make($match[1], $this->tree); 713 if (preg_match('/@(.+)/', $tag, $match)) { [all …]
|
H A D | ReportPdfCell.php | 57 $match = []; 62 if (preg_match('/#?(..)(..)(..)/', $this->bgcolor, $match)) { 63 $r = hexdec($match[1]); 64 $g = hexdec($match[2]); 65 $b = hexdec($match[3]); 76 if (preg_match('/#?(..)(..)(..)/', $this->bocolor, $match)) { 77 $r = hexdec($match[1]); 78 $g = hexdec($match[2]); 79 $b = hexdec($match[3]); 84 if (preg_match('/#?(..)(..)(..)/', $this->tcolor, $match)) { [all …]
|
H A D | ReportParserSetup.php | 58 if (preg_match('/^I18N::number\((.+)\)$/', $attrs['var'], $match)) { 59 $this->text .= I18N::number((int) $match[1]); 60 } elseif (preg_match('/^I18N::translate\(\'(.+)\'\)$/', $attrs['var'], $match)) { 61 $this->text .= I18N::translate($match[1]); 62 …} elseif (preg_match('/^I18N::translateContext\(\'(.+)\', *\'(.+)\'\)$/', $attrs['var'], $match)) { 63 $this->text .= I18N::translateContext($match[1], $match[2]); 127 $match = []; 128 if (preg_match('/NOW([+\-]\d+)/', $attrs['default'], $match) > 0) { 129 $date = Registry::timestampFactory()->now()->addDays((int)$match[1]);
|
H A D | ReportPdfText.php | 58 $match = []; 59 if (preg_match('/#?(..)(..)(..)/', $this->color, $match)) { 60 $r = hexdec($match[1]); 61 $g = hexdec($match[2]); 62 $b = hexdec($match[3]);
|
/webtrees/public/ckeditor-4.15.1-custom/plugins/pastefromword/filter/ |
H A D | default.js | 6 …match(/mso-list:\s*l\d+\s+level\d+\s+lfo\d+/)),l=[],w={root:function(d){d.filterChildren(c);CKEDIT… 7 …||a.STYLE)&&a.match(/mso\-list:\s?Ignore/)&&(d.attributes["cke-ignored"]=!0)}k.mapCommonStyles(d);… 8 …match(/^https?:\/\//)&&(d.attributes.src=d.attributes.alt);d=d.attributes["v:shapes"]?d.attributes… 9 …list-level"]&&e["mso-list"]&&e["mso-list"].match(/level/)&&(b.attributes["cke-list-level"]=e["mso-… 11 …eListItem(a,d);k.createStyleStack(d,c,a)},font:function(d){if(d.getHtml().match(/^\s*$/))return d.… 13 …tyle.match(/^mso\-bookmark:OLE_LINK\d+$/)||d.getHtml().match(/^(\s| )+$/))return t.elements.r… 15 …g:r,cellpadding:r,border:r,"v:shapes":r,"o:spid":r},comment:function(a){a.match(/\[if.* supportFie… 16 …match(/mso-list:\s*ignore/i)?a.replace(/ /g," "):a}};n.array.forEach(E,function(a){w.elements… 17 …="·",a.remove())},CKEDITOR.NODE_ELEMENT);a.forEach(function(a){c||a.value.match(/^ /)||(c=a.value)… 18 …ndexOf(a)},!0),e;c&&(c.value=c.value.replace(a,""),e=c.parent,e.getHtml().match(/^(\s| )*$/)&& [all …]
|
/webtrees/app/Factories/ |
H A D | CalendarDateFactory.php | 49 …_match('/^(@#D(?:GREGORIAN|JULIAN|HEBREW|HIJRI|JALALI|FRENCH R|ROMAN)+@) ?(.*)/', $date, $match)) { 50 $cal = $match[1]; 51 $date = $match[2]; 56 …HR|MEHR|ABAN|AZAR|DEY|BAHMA|ESFAN) ?((?:\d{1,4}(?: B\.C\.)?|\d\d\d\d\/\d\d)?)$/', $date, $match)) { 57 $d = $match[1]; 58 $m = $match[2]; 59 $y = $match[3]; 60 } elseif (preg_match('/^(\d{1,4}(?: B\.C\.)?|\d\d\d\d\/\d\d)$/', $date, $match)) { 64 $y = $match[1]; 71 if (preg_match('/(\d{3,4})/', $date, $match)) { [all …]
|
/webtrees/app/Elements/ |
H A D | AgeAtEvent.php | 100 …'/\b(\d+)y\b/' => fn (array $match) => I18N::plural('%s year', '%s years', (int) $match[1], I18N::… 101 …'/\b(\d+)m\b/' => fn (array $match) => I18N::plural('%s month', '%s months', (int) $match[1], I18N… 102 …'/\b(\d+)w\b/' => fn (array $match) => I18N::plural('%s week', '%s weeks', (int) $match[1], I18N::… 103 …'/\b(\d+)d\b/' => fn (array $match) => I18N::plural('%s day', '%s days', (int) $match[1], I18N::nu…
|
/webtrees/resources/views/ |
H A D | fact-place.phtml | 23 <?php if (preg_match('/\n(2 PLAC.*(?:\n[3-9].*)*)/', $fact->gedcom(), $match) === 1) : ?> 24 <?php $placerec = $match[1]; ?> 28 <?php foreach ($matches[1] as $match) : ?> 29 — <?= (new Place($match, $record->tree()))->fullName() ?> 42 <?php foreach ($matches as $match) : ?> 43 …<?= view('fact-gedcom-fields', ['gedcom' => $match[1], 'parent' => $fact->tag() . ':PLAC:NOTE', 't… 48 <?php if (preg_match('/2 TEMP (.+)/', $fact->gedcom(), $match)) : ?> 49 …<?= Registry::elementFactory()->make($fact->tag() . ':TEMP')->labelValue($match[1], $record->tree(… 52 <?php if (preg_match('/2 STAT (.+)/', $fact->gedcom(), $match)) : ?> 53 …<?= Registry::elementFactory()->make($fact->tag() . ':STAT')->labelValue($match[1], $record->tree(… [all …]
|
H A D | fact-date.phtml | 27 if (preg_match('/\n2 AGE (.+)/', $factrec, $match) === 1) { 28 …$fact_age = Registry::elementFactory()->make($fact->tag() . ':AGE')->value($match[1], $record->tre… 33 if (preg_match('/\n2 HUSB\n3 AGE (.+)/', $factrec, $match) === 1) { 34 …$husb_age = Registry::elementFactory()->make($fact->tag() . ':HUSB:AGE')->value($match[1], $record… 39 if (preg_match('/\n2 WIFE\n3 AGE (.+)/', $factrec, $match) === 1) { 40 …$wife_age = Registry::elementFactory()->make($fact->tag() . ':WIFE:AGE')->value($match[1], $record… 48 if (preg_match('/\n2 DATE (.+)/', $factrec, $match) === 1) { 49 $date = new Date($match[1]); 52 if ($time && preg_match('/\n3 TIME (.+)/', $factrec, $match) === 1) { 53 $html .= ' – <span class="date">' . $match[1] . '</span>';
|
/webtrees/app/ |
H A D | GedcomRecord.php | 166 preg_match('/^0 @[^@]*@ (\w+)/', $this->gedcom(), $match); 168 return $match[1] ?? static::RECORD_TYPE; 325 foreach ($matches as $match) { 326 $xref = $match[1]; 330 $gedcom = str_replace($match[0], '', $gedcom); 715 …f (preg_match('/\n3 TIME (([01]\d|2[0-3]):([0-5]\d):([0-5]\d))/', $chan->gedcom(), $match) === 1) { 716 … return Registry::timestampFactory()->fromString($ymd . $match[1], 'Y-m-d H:i:s'); 719 … if (preg_match('/\n3 TIME (([01]\d|2[0-3]):([0-5]\d))/', $chan->gedcom(), $match) === 1) { 720 return Registry::timestampFactory()->fromString($ymd . $match[1], 'Y-m-d H:i'); 880 if (preg_match('/\n1 CHAN(\n[2-9].*)*/', $gedcom, $match)) { [all …]
|
H A D | Date.php | 63 if (preg_match('/^(.*) ?[(](.*)[)]/', $date, $match)) { 64 $date = $match[1]; 65 $this->text = $match[2]; 67 if (preg_match('/^(FROM|BET) (.+) (AND|TO) (.+)/', $date, $match)) { 68 $this->qual1 = $match[1]; 69 $this->date1 = $calendar_date_factory->make($match[2]); 70 $this->qual2 = $match[3]; 71 $this->date2 = $calendar_date_factory->make($match[4]); 72 } elseif (preg_match('/^(TO|FROM|BEF|AFT|CAL|EST|INT|ABT) (.+)/', $date, $match)) { 73 $this->qual1 = $match[1]; [all …]
|
H A D | Fact.php | 186 if (preg_match('/^1 (' . Gedcom::REGEX_TAG . ')/', $gedcom, $match)) { 190 $this->tag = $match[1]; 204 if (preg_match('/^1 ' . $this->tag . ' ?(.*(?:\n2 CONT ?.*)*)/', $this->gedcom, $match)) { 205 $value = preg_replace("/\n2 CONT ?/", "\n", $match[1]); 220 if (!preg_match('/^@(' . Gedcom::REGEX_XREF . ')@$/', $this->value(), $match)) { 224 $xref = $match[1]; 270 if (preg_match('/\n2 ' . $tag . '\b ?(.*(?:(?:\n3 CONT ?.*)*)*)/', $this->gedcom, $match)) { 271 $value = preg_replace("/\n3 CONT ?/", "\n", $match[1]); 284 if (preg_match('/\n4 LATI (.+)/', $this->gedcom, $match)) { 287 return $gedcom_service->readLatitude($match[1]); [all …]
|
H A D | MediaFile.php | 81 if (preg_match('/^\d FILE (.+)/m', $gedcom, $match)) { 82 $this->multimedia_file_refn = $match[1]; 85 if (preg_match('/^\d FORM (.+)/m', $gedcom, $match)) { 86 $this->multimedia_format = $match[1]; 89 if (preg_match('/^\d TYPE (.+)/m', $gedcom, $match)) { 90 $this->source_media_type = $match[1]; 93 if (preg_match('/^\d TITL (.+)/m', $gedcom, $match)) { 94 $this->descriptive_title = $match[1];
|
H A D | Individual.php | 103 foreach ($matches as $match) { 104 $date = new Date($match[1]); 114 foreach ($matches as $match) { 115 $date = new Date($match[1]); 652 if (preg_match('/\n1 SEX ([MFX])/', $this->gedcom . $this->pending, $match)) { 653 return $match[1]; 711 if (preg_match('/\n1 NCHI (\d+)(?:\n|$)/', $this->gedcom(), $match)) { 712 return (int) $match[1]; 943 … $GIVN = preg_match('/\n' . $sublevel . ' GIVN (.+)/', $gedcom, $match) === 1 ? $match[1] : ''; 944 … $SURN = preg_match('/\n' . $sublevel . ' SURN (.+)/', $gedcom, $match) === 1 ? $match[1] : ''; [all …]
|
/webtrees/app/SurnameTradition/ |
H A D | LithuanianSurnameTradition.php | 92 if (preg_match(self::REGEX_SURN, $this->extractName($father), $match) === 1) { 94 $name = $this->inflect($match['NAME'], self::INFLECT_DAUGHTER); 95 $surn = $this->inflect($match['SURN'], self::INFLECT_MALE); 97 $name = $match['NAME']; 98 $surn = $match['SURN']; 121 … if ($sex === 'M' && preg_match(self::REGEX_SURN, $this->extractName($child), $match) === 1) { 122 $name = $this->inflect($match['NAME'], self::INFLECT_MALE); 123 $surn = $this->inflect($match['SURN'], self::INFLECT_MALE); 145 … if ($sex === 'F' && preg_match(self::REGEX_SURN, $this->extractName($spouse), $match) === 1) { 146 $name = $this->inflect($match['NAME'], self::INFLECT_WIFE); [all …]
|
H A D | PolishSurnameTradition.php | 82 if (preg_match(self::REGEX_SURN, $this->extractName($father), $match) === 1) { 84 $name = $this->inflect($match['NAME'], self::INFLECT_FEMALE); 86 $name = $this->inflect($match['NAME'], self::INFLECT_MALE); 89 $surn = $this->inflect($match['SURN'], self::INFLECT_MALE); 107 … if ($sex === 'M' && preg_match(self::REGEX_SURN, $this->extractName($child), $match) === 1) { 108 $name = $this->inflect($match['NAME'], self::INFLECT_MALE); 109 $surn = $this->inflect($match['SURN'], self::INFLECT_MALE); 129 … if ($sex === 'F' && preg_match(self::REGEX_SURN, $this->extractName($spouse), $match) === 1) { 130 $name = $this->inflect($match['NAME'], self::INFLECT_FEMALE); 131 $surn = $this->inflect($match['SURN'], self::INFLECT_MALE);
|
H A D | IcelandicSurnameTradition.php | 76 if (preg_match(self::REGEX_GIVN, $this->extractName($father), $match) === 1) { 79 $givn = $match['GIVN'] . 'sson'; 86 $givn = $match['GIVN'] . 'sdottir'; 109 …ex === 'M' && preg_match('~(?<GIVN>[^ /]+)(:?sson)$~', $this->extractName($child), $match) === 1) { 111 … $this->buildName($match['GIVN'], ['TYPE' => NameType::VALUE_BIRTH, 'GIVN' => $match['GIVN']]), 115 …=== 'F' && preg_match('~(?<GIVN>[^ /]+)(:?sdottir)$~', $this->extractName($child), $match) === 1) { 117 … $this->buildName($match['GIVN'], ['TYPE' => NameType::VALUE_BIRTH, 'GIVN' => $match['GIVN']]),
|
H A D | MatrilinealSurnameTradition.php | 64 if (preg_match(self::REGEX_SPFX_SURN, $this->extractName($mother), $match) === 1) { 65 $name = $match['NAME']; 66 $spfx = $match['SPFX']; 67 $surn = $match['SURN']; 87 … if ($sex === 'F' && preg_match(self::REGEX_SPFX_SURN, $this->extractName($child), $match) === 1) { 88 $name = $match['NAME']; 89 $spfx = $match['SPFX']; 90 $surn = $match['SURN'];
|
H A D | PaternalSurnameTradition.php | 64 … if ($sex === 'F' && preg_match(self::REGEX_SPFX_SURN, $this->extractName($child), $match) === 1) { 65 $name = $match['NAME']; 66 $spfx = $match['SPFX']; 67 $surn = $match['SURN']; 88 …if ($sex === 'F' && preg_match(self::REGEX_SPFX_SURN, $this->extractName($spouse), $match) === 1) { 89 $name = $match['NAME']; 90 $spfx = $match['SPFX']; 91 $surn = $match['SURN'];
|
H A D | PatrilinealSurnameTradition.php | 64 if (preg_match(self::REGEX_SPFX_SURN, $this->extractName($father), $match) === 1) { 65 $name = $match['NAME']; 66 $spfx = $match['SPFX']; 67 $surn = $match['SURN']; 87 … if ($sex === 'M' && preg_match(self::REGEX_SPFX_SURN, $this->extractName($child), $match) === 1) { 88 $name = $match['NAME']; 89 $spfx = $match['SPFX']; 90 $surn = $match['SURN'];
|
H A D | SpanishSurnameTradition.php | 107 if (preg_match(self::REGEX_SURNS, $this->extractName($child), $match) === 1) { 111 $this->buildName('/' . $match['SURN1'] . '/ //', [ 113 'SURN' => $match['SURN1'], 119 $this->buildName('/' . $match['SURN2'] . '/ //', [ 121 'SURN' => $match['SURN2'],
|
H A D | PortugueseSurnameTradition.php | 107 if (preg_match(self::REGEX_SURNS, $this->extractName($child), $match) === 1) { 111 $this->buildName('// /' . $match['SURN1'] . '/', [ 113 'SURN' => $match['SURN1'], 119 $this->buildName('// /' . $match['SURN2'] . '/', [ 121 'SURN' => $match['SURN2'],
|
/webtrees/app/Http/RequestHandlers/ |
H A D | ReportSetupPage.php | 165 … if (preg_match('/^I18N::number\((.+?)(,([\d+]))?\)$/', $value, $match)) { 166 $number = (float) $match[1]; 167 $precision = (int) ($match[3] ?? 0); 169 … } elseif (preg_match('/^I18N::translate\(\'(.+)\'\)$/', $value, $match)) { 170 $options[$key] = I18N::translate($match[1]); 171 … } elseif (preg_match('/^I18N::translateContext\(\'(.+)\', *\'(.+)\'\)$/', $value, $match)) { 172 $options[$key] = I18N::translateContext($match[1], $match[2]);
|
/webtrees/tests/ |
H A D | TestCase.php | 240 if (preg_match('~^</([a-z]+)>~', $html, $match)) { 241 if ($match[1] !== array_pop($stack)) { 242 … static::fail('Closing tag matches nothing: ' . $match[0] . ' at ' . implode(':', $stack)); 244 $html = substr($html, strlen($match[0])); 245 … } elseif (preg_match('~^<([a-z]+)(?:\s+[a-z_\-]+="[^">]*")*\s*(/?)>~', $html, $match)) { 246 $tag = $match[1]; 247 $self_closing = $match[2] === '/'; 271 $html = substr($html, strlen($match[0]));
|