161 $this->current_column = xml_get_current_column_number($xml); |
174 $this->current_column = xml_get_current_column_number($xml); |
162 $this->current_byte = xml_get_current_byte_index($xml); |
175 $this->current_byte = xml_get_current_byte_index($xml); |
163 xml_parser_free($xml); |
176 xml_parser_free($xml); |
164 return $return; |
177 return $return; |
165 } |
178 } |
166 else |
179 |
167 { |
180 libxml_clear_errors(); |
168 libxml_clear_errors(); |
181 $xml = new XMLReader(); |
169 $xml = new XMLReader(); |
182 $xml->xml($data); |
170 $xml->xml($data); |
183 while (@$xml->read()) |
171 while (@$xml->read()) |
184 { |
172 { |
185 switch ($xml->nodeType) |
173 switch ($xml->nodeType) |
186 { |
174 { |
187 |
175 |
188 case constant('XMLReader::END_ELEMENT'): |
176 case constant('XMLReader::END_ELEMENT'): |
189 if ($xml->namespaceURI !== '') |
|
190 { |
|
191 $tagName = $xml->namespaceURI . $this->separator . $xml->localName; |
|
192 } |
|
193 else |
|
194 { |
|
195 $tagName = $xml->localName; |
|
196 } |
|
197 $this->tag_close(null, $tagName); |
|
198 break; |
|
199 case constant('XMLReader::ELEMENT'): |
|
200 $empty = $xml->isEmptyElement; |
|
201 if ($xml->namespaceURI !== '') |
|
202 { |
|
203 $tagName = $xml->namespaceURI . $this->separator . $xml->localName; |
|
204 } |
|
205 else |
|
206 { |
|
207 $tagName = $xml->localName; |
|
208 } |
|
209 $attributes = array(); |
|
210 while ($xml->moveToNextAttribute()) |
|
211 { |
177 if ($xml->namespaceURI !== '') |
212 if ($xml->namespaceURI !== '') |
178 { |
213 { |
179 $tagName = $xml->namespaceURI . $this->separator . $xml->localName; |
214 $attrName = $xml->namespaceURI . $this->separator . $xml->localName; |
180 } |
215 } |
181 else |
216 else |
182 { |
217 { |
183 $tagName = $xml->localName; |
218 $attrName = $xml->localName; |
184 } |
219 } |
|
220 $attributes[$attrName] = $xml->value; |
|
221 } |
|
222 $this->tag_open(null, $tagName, $attributes); |
|
223 if ($empty) |
|
224 { |
185 $this->tag_close(null, $tagName); |
225 $this->tag_close(null, $tagName); |
186 break; |
226 } |
187 case constant('XMLReader::ELEMENT'): |
227 break; |
188 $empty = $xml->isEmptyElement; |
228 case constant('XMLReader::TEXT'): |
189 if ($xml->namespaceURI !== '') |
229 |
190 { |
230 case constant('XMLReader::CDATA'): |
191 $tagName = $xml->namespaceURI . $this->separator . $xml->localName; |
231 $this->cdata(null, $xml->value); |
192 } |
232 break; |
193 else |
233 } |
194 { |
234 } |
195 $tagName = $xml->localName; |
235 if ($error = libxml_get_last_error()) |
196 } |
236 { |
197 $attributes = array(); |
237 $this->error_code = $error->code; |
198 while ($xml->moveToNextAttribute()) |
238 $this->error_string = $error->message; |
199 { |
239 $this->current_line = $error->line; |
200 if ($xml->namespaceURI !== '') |
240 $this->current_column = $error->column; |
201 { |
241 return false; |
202 $attrName = $xml->namespaceURI . $this->separator . $xml->localName; |
242 } |
203 } |
243 |
204 else |
244 return true; |
205 { |
|
206 $attrName = $xml->localName; |
|
207 } |
|
208 $attributes[$attrName] = $xml->value; |
|
209 } |
|
210 $this->tag_open(null, $tagName, $attributes); |
|
211 if ($empty) |
|
212 { |
|
213 $this->tag_close(null, $tagName); |
|
214 } |
|
215 break; |
|
216 case constant('XMLReader::TEXT'): |
|
217 |
|
218 case constant('XMLReader::CDATA'): |
|
219 $this->cdata(null, $xml->value); |
|
220 break; |
|
221 } |
|
222 } |
|
223 if ($error = libxml_get_last_error()) |
|
224 { |
|
225 $this->error_code = $error->code; |
|
226 $this->error_string = $error->message; |
|
227 $this->current_line = $error->line; |
|
228 $this->current_column = $error->column; |
|
229 return false; |
|
230 } |
|
231 else |
|
232 { |
|
233 return true; |
|
234 } |
|
235 } |
|
236 } |
245 } |
237 |
246 |
238 public function get_error_code() |
247 public function get_error_code() |
239 { |
248 { |
240 return $this->error_code; |
249 return $this->error_code; |
402 $cache[$string] = array('', $string); |
411 $cache[$string] = array('', $string); |
403 } |
412 } |
404 } |
413 } |
405 return $cache[$string]; |
414 return $cache[$string]; |
406 } |
415 } |
|
416 |
|
417 private function parse_hcard($data, $category = false) { |
|
418 $name = ''; |
|
419 $link = ''; |
|
420 // Check if h-card is set and pass that information on in the link. |
|
421 if (isset($data['type']) && in_array('h-card', $data['type'])) { |
|
422 if (isset($data['properties']['name'][0])) { |
|
423 $name = $data['properties']['name'][0]; |
|
424 } |
|
425 if (isset($data['properties']['url'][0])) { |
|
426 $link = $data['properties']['url'][0]; |
|
427 if ($name === '') { |
|
428 $name = $link; |
|
429 } |
|
430 else { |
|
431 // can't have commas in categories. |
|
432 $name = str_replace(',', '', $name); |
|
433 } |
|
434 $person_tag = $category ? '<span class="person-tag"></span>' : ''; |
|
435 return '<a class="h-card" href="'.$link.'">'.$person_tag.$name.'</a>'; |
|
436 } |
|
437 } |
|
438 return isset($data['value']) ? $data['value'] : ''; |
|
439 } |
|
440 |
|
441 private function parse_microformats(&$data, $url) { |
|
442 $feed_title = ''; |
|
443 $feed_author = NULL; |
|
444 $author_cache = array(); |
|
445 $items = array(); |
|
446 $entries = array(); |
|
447 $mf = Mf2\parse($data, $url); |
|
448 // First look for an h-feed. |
|
449 $h_feed = array(); |
|
450 foreach ($mf['items'] as $mf_item) { |
|
451 if (in_array('h-feed', $mf_item['type'])) { |
|
452 $h_feed = $mf_item; |
|
453 break; |
|
454 } |
|
455 // Also look for h-feed or h-entry in the children of each top level item. |
|
456 if (!isset($mf_item['children'][0]['type'])) continue; |
|
457 if (in_array('h-feed', $mf_item['children'][0]['type'])) { |
|
458 $h_feed = $mf_item['children'][0]; |
|
459 // In this case the parent of the h-feed may be an h-card, so use it as |
|
460 // the feed_author. |
|
461 if (in_array('h-card', $mf_item['type'])) $feed_author = $mf_item; |
|
462 break; |
|
463 } |
|
464 else if (in_array('h-entry', $mf_item['children'][0]['type'])) { |
|
465 $entries = $mf_item['children']; |
|
466 // In this case the parent of the h-entry list may be an h-card, so use |
|
467 // it as the feed_author. |
|
468 if (in_array('h-card', $mf_item['type'])) $feed_author = $mf_item; |
|
469 break; |
|
470 } |
|
471 } |
|
472 if (isset($h_feed['children'])) { |
|
473 $entries = $h_feed['children']; |
|
474 // Also set the feed title and store author from the h-feed if available. |
|
475 if (isset($mf['items'][0]['properties']['name'][0])) { |
|
476 $feed_title = $mf['items'][0]['properties']['name'][0]; |
|
477 } |
|
478 if (isset($mf['items'][0]['properties']['author'][0])) { |
|
479 $feed_author = $mf['items'][0]['properties']['author'][0]; |
|
480 } |
|
481 } |
|
482 else if (count($entries) === 0) { |
|
483 $entries = $mf['items']; |
|
484 } |
|
485 for ($i = 0; $i < count($entries); $i++) { |
|
486 $entry = $entries[$i]; |
|
487 if (in_array('h-entry', $entry['type'])) { |
|
488 $item = array(); |
|
489 $title = ''; |
|
490 $description = ''; |
|
491 if (isset($entry['properties']['url'][0])) { |
|
492 $link = $entry['properties']['url'][0]; |
|
493 if (isset($link['value'])) $link = $link['value']; |
|
494 $item['link'] = array(array('data' => $link)); |
|
495 } |
|
496 if (isset($entry['properties']['uid'][0])) { |
|
497 $guid = $entry['properties']['uid'][0]; |
|
498 if (isset($guid['value'])) $guid = $guid['value']; |
|
499 $item['guid'] = array(array('data' => $guid)); |
|
500 } |
|
501 if (isset($entry['properties']['name'][0])) { |
|
502 $title = $entry['properties']['name'][0]; |
|
503 if (isset($title['value'])) $title = $title['value']; |
|
504 $item['title'] = array(array('data' => $title)); |
|
505 } |
|
506 if (isset($entry['properties']['author'][0]) || isset($feed_author)) { |
|
507 // author is a special case, it can be plain text or an h-card array. |
|
508 // If it's plain text it can also be a url that should be followed to |
|
509 // get the actual h-card. |
|
510 $author = isset($entry['properties']['author'][0]) ? |
|
511 $entry['properties']['author'][0] : $feed_author; |
|
512 if (!is_string($author)) { |
|
513 $author = $this->parse_hcard($author); |
|
514 } |
|
515 else if (strpos($author, 'http') === 0) { |
|
516 if (isset($author_cache[$author])) { |
|
517 $author = $author_cache[$author]; |
|
518 } |
|
519 else { |
|
520 $mf = Mf2\fetch($author); |
|
521 foreach ($mf['items'] as $hcard) { |
|
522 // Only interested in an h-card by itself in this case. |
|
523 if (!in_array('h-card', $hcard['type'])) { |
|
524 continue; |
|
525 } |
|
526 // It must have a url property matching what we fetched. |
|
527 if (!isset($hcard['properties']['url']) || |
|
528 !(in_array($author, $hcard['properties']['url']))) { |
|
529 continue; |
|
530 } |
|
531 // Save parse_hcard the trouble of finding the correct url. |
|
532 $hcard['properties']['url'][0] = $author; |
|
533 // Cache this h-card for the next h-entry to check. |
|
534 $author_cache[$author] = $this->parse_hcard($hcard); |
|
535 $author = $author_cache[$author]; |
|
536 break; |
|
537 } |
|
538 } |
|
539 } |
|
540 $item['author'] = array(array('data' => $author)); |
|
541 } |
|
542 if (isset($entry['properties']['photo'][0])) { |
|
543 // If a photo is also in content, don't need to add it again here. |
|
544 $content = ''; |
|
545 if (isset($entry['properties']['content'][0]['html'])) { |
|
546 $content = $entry['properties']['content'][0]['html']; |
|
547 } |
|
548 $photo_list = array(); |
|
549 for ($j = 0; $j < count($entry['properties']['photo']); $j++) { |
|
550 $photo = $entry['properties']['photo'][$j]; |
|
551 if (!empty($photo) && strpos($content, $photo) === false) { |
|
552 $photo_list[] = $photo; |
|
553 } |
|
554 } |
|
555 // When there's more than one photo show the first and use a lightbox. |
|
556 // Need a permanent, unique name for the image set, but don't have |
|
557 // anything unique except for the content itself, so use that. |
|
558 $count = count($photo_list); |
|
559 if ($count > 1) { |
|
560 $image_set_id = preg_replace('/[[:^alnum:]]/', '', $photo_list[0]); |
|
561 $description = '<p>'; |
|
562 for ($j = 0; $j < $count; $j++) { |
|
563 $hidden = $j === 0 ? '' : 'class="hidden" '; |
|
564 $description .= '<a href="'.$photo_list[$j].'" '.$hidden. |
|
565 'data-lightbox="image-set-'.$image_set_id.'">'. |
|
566 '<img src="'.$photo_list[$j].'"></a>'; |
|
567 } |
|
568 $description .= '<br><b>'.$count.' photos</b></p>'; |
|
569 } |
|
570 else if ($count == 1) { |
|
571 $description = '<p><img src="'.$photo_list[0].'"></p>'; |
|
572 } |
|
573 } |
|
574 if (isset($entry['properties']['content'][0]['html'])) { |
|
575 // e-content['value'] is the same as p-name when they are on the same |
|
576 // element. Use this to replace title with a strip_tags version so |
|
577 // that alt text from images is not included in the title. |
|
578 if ($entry['properties']['content'][0]['value'] === $title) { |
|
579 $title = strip_tags($entry['properties']['content'][0]['html']); |
|
580 $item['title'] = array(array('data' => $title)); |
|
581 } |
|
582 $description .= $entry['properties']['content'][0]['html']; |
|
583 if (isset($entry['properties']['in-reply-to'][0])) { |
|
584 $in_reply_to = ''; |
|
585 if (is_string($entry['properties']['in-reply-to'][0])) { |
|
586 $in_reply_to = $entry['properties']['in-reply-to'][0]; |
|
587 } |
|
588 else if (isset($entry['properties']['in-reply-to'][0]['value'])) { |
|
589 $in_reply_to = $entry['properties']['in-reply-to'][0]['value']; |
|
590 } |
|
591 if ($in_reply_to !== '') { |
|
592 $description .= '<p><span class="in-reply-to"></span> '. |
|
593 '<a href="'.$in_reply_to.'">'.$in_reply_to.'</a><p>'; |
|
594 } |
|
595 } |
|
596 $item['description'] = array(array('data' => $description)); |
|
597 } |
|
598 if (isset($entry['properties']['category'])) { |
|
599 $category_csv = ''; |
|
600 // Categories can also contain h-cards. |
|
601 foreach ($entry['properties']['category'] as $category) { |
|
602 if ($category_csv !== '') $category_csv .= ', '; |
|
603 if (is_string($category)) { |
|
604 // Can't have commas in categories. |
|
605 $category_csv .= str_replace(',', '', $category); |
|
606 } |
|
607 else { |
|
608 $category_csv .= $this->parse_hcard($category, true); |
|
609 } |
|
610 } |
|
611 $item['category'] = array(array('data' => $category_csv)); |
|
612 } |
|
613 if (isset($entry['properties']['published'][0])) { |
|
614 $timestamp = strtotime($entry['properties']['published'][0]); |
|
615 $pub_date = date('F j Y g:ia', $timestamp).' GMT'; |
|
616 $item['pubDate'] = array(array('data' => $pub_date)); |
|
617 } |
|
618 // The title and description are set to the empty string to represent |
|
619 // a deleted item (which also makes it an invalid rss item). |
|
620 if (isset($entry['properties']['deleted'][0])) { |
|
621 $item['title'] = array(array('data' => '')); |
|
622 $item['description'] = array(array('data' => '')); |
|
623 } |
|
624 $items[] = array('child' => array('' => $item)); |
|
625 } |
|
626 } |
|
627 // Mimic RSS data format when storing microformats. |
|
628 $link = array(array('data' => $url)); |
|
629 $image = ''; |
|
630 if (!is_string($feed_author) && |
|
631 isset($feed_author['properties']['photo'][0])) { |
|
632 $image = array(array('child' => array('' => array('url' => |
|
633 array(array('data' => $feed_author['properties']['photo'][0])))))); |
|
634 } |
|
635 // Use the name given for the h-feed, or get the title from the html. |
|
636 if ($feed_title !== '') { |
|
637 $feed_title = array(array('data' => htmlspecialchars($feed_title))); |
|
638 } |
|
639 else if ($position = strpos($data, '<title>')) { |
|
640 $start = $position < 200 ? 0 : $position - 200; |
|
641 $check = substr($data, $start, 400); |
|
642 $matches = array(); |
|
643 if (preg_match('/<title>(.+)<\/title>/', $check, $matches)) { |
|
644 $feed_title = array(array('data' => htmlspecialchars($matches[1]))); |
|
645 } |
|
646 } |
|
647 $channel = array('channel' => array(array('child' => array('' => |
|
648 array('link' => $link, 'image' => $image, 'title' => $feed_title, |
|
649 'item' => $items))))); |
|
650 $rss = array(array('attribs' => array('' => array('version' => '2.0')), |
|
651 'child' => array('' => $channel))); |
|
652 $this->data = array('child' => array('' => array('rss' => $rss))); |
|
653 return true; |
|
654 } |
|
655 |
|
656 private function declare_html_entities() { |
|
657 // This is required because the RSS specification says that entity-encoded |
|
658 // html is allowed, but the xml specification says they must be declared. |
|
659 return '<!DOCTYPE html [ <!ENTITY nbsp " "> <!ENTITY iexcl "¡"> <!ENTITY cent "¢"> <!ENTITY pound "£"> <!ENTITY curren "¤"> <!ENTITY yen "¥"> <!ENTITY brvbar "¦"> <!ENTITY sect "§"> <!ENTITY uml "¨"> <!ENTITY copy "©"> <!ENTITY ordf "ª"> <!ENTITY laquo "«"> <!ENTITY not "¬"> <!ENTITY shy "­"> <!ENTITY reg "®"> <!ENTITY macr "¯"> <!ENTITY deg "°"> <!ENTITY plusmn "±"> <!ENTITY sup2 "²"> <!ENTITY sup3 "³"> <!ENTITY acute "´"> <!ENTITY micro "µ"> <!ENTITY para "¶"> <!ENTITY middot "·"> <!ENTITY cedil "¸"> <!ENTITY sup1 "¹"> <!ENTITY ordm "º"> <!ENTITY raquo "»"> <!ENTITY frac14 "¼"> <!ENTITY frac12 "½"> <!ENTITY frac34 "¾"> <!ENTITY iquest "¿"> <!ENTITY Agrave "À"> <!ENTITY Aacute "Á"> <!ENTITY Acirc "Â"> <!ENTITY Atilde "Ã"> <!ENTITY Auml "Ä"> <!ENTITY Aring "Å"> <!ENTITY AElig "Æ"> <!ENTITY Ccedil "Ç"> <!ENTITY Egrave "È"> <!ENTITY Eacute "É"> <!ENTITY Ecirc "Ê"> <!ENTITY Euml "Ë"> <!ENTITY Igrave "Ì"> <!ENTITY Iacute "Í"> <!ENTITY Icirc "Î"> <!ENTITY Iuml "Ï"> <!ENTITY ETH "Ð"> <!ENTITY Ntilde "Ñ"> <!ENTITY Ograve "Ò"> <!ENTITY Oacute "Ó"> <!ENTITY Ocirc "Ô"> <!ENTITY Otilde "Õ"> <!ENTITY Ouml "Ö"> <!ENTITY times "×"> <!ENTITY Oslash "Ø"> <!ENTITY Ugrave "Ù"> <!ENTITY Uacute "Ú"> <!ENTITY Ucirc "Û"> <!ENTITY Uuml "Ü"> <!ENTITY Yacute "Ý"> <!ENTITY THORN "Þ"> <!ENTITY szlig "ß"> <!ENTITY agrave "à"> <!ENTITY aacute "á"> <!ENTITY acirc "â"> <!ENTITY atilde "ã"> <!ENTITY auml "ä"> <!ENTITY aring "å"> <!ENTITY aelig "æ"> <!ENTITY ccedil "ç"> <!ENTITY egrave "è"> <!ENTITY eacute "é"> <!ENTITY ecirc "ê"> <!ENTITY euml "ë"> <!ENTITY igrave "ì"> <!ENTITY iacute "í"> <!ENTITY icirc "î"> <!ENTITY iuml "ï"> <!ENTITY eth "ð"> <!ENTITY ntilde "ñ"> <!ENTITY ograve "ò"> <!ENTITY oacute "ó"> <!ENTITY ocirc "ô"> <!ENTITY otilde "õ"> <!ENTITY ouml "ö"> <!ENTITY divide "÷"> <!ENTITY oslash "ø"> <!ENTITY ugrave "ù"> <!ENTITY uacute "ú"> <!ENTITY ucirc "û"> <!ENTITY uuml "ü"> <!ENTITY yacute "ý"> <!ENTITY thorn "þ"> <!ENTITY yuml "ÿ"> <!ENTITY OElig "Œ"> <!ENTITY oelig "œ"> <!ENTITY Scaron "Š"> <!ENTITY scaron "š"> <!ENTITY Yuml "Ÿ"> <!ENTITY fnof "ƒ"> <!ENTITY circ "ˆ"> <!ENTITY tilde "˜"> <!ENTITY Alpha "Α"> <!ENTITY Beta "Β"> <!ENTITY Gamma "Γ"> <!ENTITY Epsilon "Ε"> <!ENTITY Zeta "Ζ"> <!ENTITY Eta "Η"> <!ENTITY Theta "Θ"> <!ENTITY Iota "Ι"> <!ENTITY Kappa "Κ"> <!ENTITY Lambda "Λ"> <!ENTITY Mu "Μ"> <!ENTITY Nu "Ν"> <!ENTITY Xi "Ξ"> <!ENTITY Omicron "Ο"> <!ENTITY Pi "Π"> <!ENTITY Rho "Ρ"> <!ENTITY Sigma "Σ"> <!ENTITY Tau "Τ"> <!ENTITY Upsilon "Υ"> <!ENTITY Phi "Φ"> <!ENTITY Chi "Χ"> <!ENTITY Psi "Ψ"> <!ENTITY Omega "Ω"> <!ENTITY alpha "α"> <!ENTITY beta "β"> <!ENTITY gamma "γ"> <!ENTITY delta "δ"> <!ENTITY epsilon "ε"> <!ENTITY zeta "ζ"> <!ENTITY eta "η"> <!ENTITY theta "θ"> <!ENTITY iota "ι"> <!ENTITY kappa "κ"> <!ENTITY lambda "λ"> <!ENTITY mu "μ"> <!ENTITY nu "ν"> <!ENTITY xi "ξ"> <!ENTITY omicron "ο"> <!ENTITY pi "π"> <!ENTITY rho "ρ"> <!ENTITY sigmaf "ς"> <!ENTITY sigma "σ"> <!ENTITY tau "τ"> <!ENTITY upsilon "υ"> <!ENTITY phi "φ"> <!ENTITY chi "χ"> <!ENTITY psi "ψ"> <!ENTITY omega "ω"> <!ENTITY thetasym "ϑ"> <!ENTITY upsih "ϒ"> <!ENTITY piv "ϖ"> <!ENTITY ensp " "> <!ENTITY emsp " "> <!ENTITY thinsp " "> <!ENTITY zwnj "‌"> <!ENTITY zwj "‍"> <!ENTITY lrm "‎"> <!ENTITY rlm "‏"> <!ENTITY ndash "–"> <!ENTITY mdash "—"> <!ENTITY lsquo "‘"> <!ENTITY rsquo "’"> <!ENTITY sbquo "‚"> <!ENTITY ldquo "“"> <!ENTITY rdquo "”"> <!ENTITY bdquo "„"> <!ENTITY dagger "†"> <!ENTITY Dagger "‡"> <!ENTITY bull "•"> <!ENTITY hellip "…"> <!ENTITY permil "‰"> <!ENTITY prime "′"> <!ENTITY Prime "″"> <!ENTITY lsaquo "‹"> <!ENTITY rsaquo "›"> <!ENTITY oline "‾"> <!ENTITY frasl "⁄"> <!ENTITY euro "€"> <!ENTITY image "ℑ"> <!ENTITY weierp "℘"> <!ENTITY real "ℜ"> <!ENTITY trade "™"> <!ENTITY alefsym "ℵ"> <!ENTITY larr "←"> <!ENTITY uarr "↑"> <!ENTITY rarr "→"> <!ENTITY darr "↓"> <!ENTITY harr "↔"> <!ENTITY crarr "↵"> <!ENTITY lArr "⇐"> <!ENTITY uArr "⇑"> <!ENTITY rArr "⇒"> <!ENTITY dArr "⇓"> <!ENTITY hArr "⇔"> <!ENTITY forall "∀"> <!ENTITY part "∂"> <!ENTITY exist "∃"> <!ENTITY empty "∅"> <!ENTITY nabla "∇"> <!ENTITY isin "∈"> <!ENTITY notin "∉"> <!ENTITY ni "∋"> <!ENTITY prod "∏"> <!ENTITY sum "∑"> <!ENTITY minus "−"> <!ENTITY lowast "∗"> <!ENTITY radic "√"> <!ENTITY prop "∝"> <!ENTITY infin "∞"> <!ENTITY ang "∠"> <!ENTITY and "∧"> <!ENTITY or "∨"> <!ENTITY cap "∩"> <!ENTITY cup "∪"> <!ENTITY int "∫"> <!ENTITY there4 "∴"> <!ENTITY sim "∼"> <!ENTITY cong "≅"> <!ENTITY asymp "≈"> <!ENTITY ne "≠"> <!ENTITY equiv "≡"> <!ENTITY le "≤"> <!ENTITY ge "≥"> <!ENTITY sub "⊂"> <!ENTITY sup "⊃"> <!ENTITY nsub "⊄"> <!ENTITY sube "⊆"> <!ENTITY supe "⊇"> <!ENTITY oplus "⊕"> <!ENTITY otimes "⊗"> <!ENTITY perp "⊥"> <!ENTITY sdot "⋅"> <!ENTITY lceil "⌈"> <!ENTITY rceil "⌉"> <!ENTITY lfloor "⌊"> <!ENTITY rfloor "⌋"> <!ENTITY lang "〈"> <!ENTITY rang "〉"> <!ENTITY loz "◊"> <!ENTITY spades "♠"> <!ENTITY clubs "♣"> <!ENTITY hearts "♥"> <!ENTITY diams "♦"> ]>'; |
|
660 } |
407 } |
661 } |