This document contains two TEI XML files: one containing the text of Ovid's Ibis poem, and the other containing critical apparatus from Owen's edition of the poem. The Ibis text contains line numbers and page breaks. The apparatus file cross-references textual variations in the poem to passages in a separate XML file containing the full text. It includes critical notes on variants found in different manuscript witnesses for several lines.
This is a PHP talk about consuming web services, dealing with XML and JSON and serialised PHP. It covers use of services using SOAP, XML-RPC, JSON-RPC and some RESTful concepts with plenty of code examples. Examples of making web service clients using streams, pecl_http and curl are included
[PL] Jak nie zostać "programistą" PHP?Radek Benkel
Po sieci krąży wiele opinii, jak to programiści PHP nie są prawdziwymi programistami i że PHP to w ogóle nie jest język programowania, etc.
A winni takiego stanu rzeczy są sami programiści bądź właśnie „programiści”. Dlaczego? W każdym języku da się napisać kod zły jak i dobry. A w świecie PHP niestety dużo jest tego złego – choć trend ten zmienia się na lepsze.
Celem wykładu jest zapoznanie uczestników z rzeczami, na które należy zwrócić uwagę podczas tworzenia aplikacji w języku PHP. Druga (krótsza) część prezentacji będzie poświęcona ogólnym dobrym praktykom programistycznym, nie związanym z żadnym konkretnym językiem.
This is a PHP talk about consuming web services, dealing with XML and JSON and serialised PHP. It covers use of services using SOAP, XML-RPC, JSON-RPC and some RESTful concepts with plenty of code examples. Examples of making web service clients using streams, pecl_http and curl are included
[PL] Jak nie zostać "programistą" PHP?Radek Benkel
Po sieci krąży wiele opinii, jak to programiści PHP nie są prawdziwymi programistami i że PHP to w ogóle nie jest język programowania, etc.
A winni takiego stanu rzeczy są sami programiści bądź właśnie „programiści”. Dlaczego? W każdym języku da się napisać kod zły jak i dobry. A w świecie PHP niestety dużo jest tego złego – choć trend ten zmienia się na lepsze.
Celem wykładu jest zapoznanie uczestników z rzeczami, na które należy zwrócić uwagę podczas tworzenia aplikacji w języku PHP. Druga (krótsza) część prezentacji będzie poświęcona ogólnym dobrym praktykom programistycznym, nie związanym z żadnym konkretnym językiem.
PHP has its own treasure chest of classic mistakes that surprises even the most seasoned expert: code that dies just by changing its namespace, strpos() that fails to find strings or arrays that changes without touching them. Do that get on your nerves too? Let's make a list of them, so we can always teach them to the new guys, spot them during code reviews and kick them out of our code once and for all. Come on, you're not frightening us!
Given it's share of ~80% (W3Techs dixit) with more than 240M active websites (Netcraft dixit) we can say that PHP is the de facto standard for web programming.
We can find she both in made-by-son-of-a-friend-after-dinner websites and on enterprise portals or e-commerce platforms, perhaps because she's available on almost every hosting service and because it's very easy to start with her.
As we should have learnt from history, simplicity hides complexity, therefore a lot of uncommon functions' arguments and little known behaviours.
The talk present ways to insert obfuscated and hard to spot
vulnerabilities in existent code and some naughty functions. For every given example we will show how to trigger the backdoor through the vulnerability and how it works, her pros and cons, and how to detect her.
vfsStream - a better approach for file system dependent testsFrank Kleine
Have you ever been annoyed by testing classes or functions operating on the file system? Be it tests that rely on presence of physical files, the problem of not cleaning up correctly after the test run or checking that your algorithm creates the correct directories and files with correct file permissions. Then this is for you: vfsStream to the rescue!
Review unknown code with static analysis Zend con 2017Damien Seguy
Code quality is not just for Christmas, it is a daily part of the job. So, what do you do when you're handed with a five feet long pole a million lines of code that must be vetted? You call static analysis to the rescue. During one hour, we'll be reviewing totally unknown code: no name, no usage, not a clue. We'll apply a wide range of tools, reaching for anything that helps us understand the code and form an opinion on it. Can we break this mystery and learn how everyone else is looking at our code?
Code Obfuscation, PHP shells & more
What hackers do once they get passed your code - and how you can detect & fix it.
Content:
- What happens when I get hacked?
- What's code obfuscation?
- What are PHP shells?
- Show me some clever hacks!
- Prevention
- Post-hack cleanup
What is this not about:
- How can I hack a website?
- How can I DoS a website?
- How can I find my insecure code?
There are a lot of operators in Perl 6, so many that it can be called an OOL: operator oriented language. Here I describe most of them from the angle of contexts, which Perl 6 has also much more than Perl 5.
Full-day tutorial for the dutch php conference 2011 giving a very quick tour around all the various areas of the ZCE syllabus and some tips on the exam styles
PHP has its own treasure chest of classic mistakes that surprises even the most seasoned expert: code that dies just by changing its namespace, strpos() that fails to find strings or arrays that changes without touching them. Do that get on your nerves too? Let's make a list of them, so we can always teach them to the new guys, spot them during code reviews and kick them out of our code once and for all. Come on, you're not frightening us!
Given it's share of ~80% (W3Techs dixit) with more than 240M active websites (Netcraft dixit) we can say that PHP is the de facto standard for web programming.
We can find she both in made-by-son-of-a-friend-after-dinner websites and on enterprise portals or e-commerce platforms, perhaps because she's available on almost every hosting service and because it's very easy to start with her.
As we should have learnt from history, simplicity hides complexity, therefore a lot of uncommon functions' arguments and little known behaviours.
The talk present ways to insert obfuscated and hard to spot
vulnerabilities in existent code and some naughty functions. For every given example we will show how to trigger the backdoor through the vulnerability and how it works, her pros and cons, and how to detect her.
vfsStream - a better approach for file system dependent testsFrank Kleine
Have you ever been annoyed by testing classes or functions operating on the file system? Be it tests that rely on presence of physical files, the problem of not cleaning up correctly after the test run or checking that your algorithm creates the correct directories and files with correct file permissions. Then this is for you: vfsStream to the rescue!
Review unknown code with static analysis Zend con 2017Damien Seguy
Code quality is not just for Christmas, it is a daily part of the job. So, what do you do when you're handed with a five feet long pole a million lines of code that must be vetted? You call static analysis to the rescue. During one hour, we'll be reviewing totally unknown code: no name, no usage, not a clue. We'll apply a wide range of tools, reaching for anything that helps us understand the code and form an opinion on it. Can we break this mystery and learn how everyone else is looking at our code?
Code Obfuscation, PHP shells & more
What hackers do once they get passed your code - and how you can detect & fix it.
Content:
- What happens when I get hacked?
- What's code obfuscation?
- What are PHP shells?
- Show me some clever hacks!
- Prevention
- Post-hack cleanup
What is this not about:
- How can I hack a website?
- How can I DoS a website?
- How can I find my insecure code?
There are a lot of operators in Perl 6, so many that it can be called an OOL: operator oriented language. Here I describe most of them from the angle of contexts, which Perl 6 has also much more than Perl 5.
Full-day tutorial for the dutch php conference 2011 giving a very quick tour around all the various areas of the ZCE syllabus and some tips on the exam styles
I will show how to create an interpreter for a simple programming language using Perl 6 grammars.
This talk is not an introduction to Perl 6 regexes and grammars, so we'll use them straight on, but I will add comments so that you can understand what's going on even if you never tried Perl 6 grammars.
There will not be enough time to write the whole compiler, of course, but I will show how you can do that at home.
Dealing with Legacy Perl Code - Peter ScottO'Reilly Media
Peter Scott, author of the O'Reilly School of Technology's Perl Programming Certificate series, talks about how to deal with "legacy" Perl code - written by someone else, or maybe even yourself when you were younger and less wise.
A key feature of TYPO3 today is its extendability and flexibility. Writing extensions was never easier since the Kickstarter, and tslib_piBase. But, time doesn't stand still: new programming paradigms other innovative frameworks came up. It's time to take a next step to faster, cleaner extension coding. With the new Version 5 of TYPO3 and its basis FLOW3 the way to develop extensions will change fundamentally. With Extbase - the new framework for extension development introduced in TYPO3 4.3 - you are able to develop with the paradigms of FLOW3 today. During this talk, you get in touch with the features of the framework to understand how it supports your development process. We also address the users perspective by discussing best practices how to migrate to TYPO3 v5.
Writing Modular Command-line Apps with App::CmdRicardo Signes
It's easy to write command-line programs in Perl. There are a million option parsers to choose from, and Perl makes it easy to deal with input, output, and all that stuff.
Once your program has gotten beyond just taking a few switches, though, it can be difficult to maintain a clear interface and well-tested code. App::Cmd is a lightweight framework for writing easy to manage CLI programs.
This talk provides an introduction to writing programs with App::Cmd.
This presentation is for those students and IT professionals who have basic programming knowledge and want to learn Perl basics for Pentesting.
We have explained minimal Perl basics which a pentester should know to write,read,modify Perl scripts for Pentesting like data type, comparison operator, loop controls, minimal CPAN modules related to web and networking, perl scripts in Kali and some demo
Stop the noise! - Introduction to the JSON:API specification in DrupalBjörn Brala
If you’ve ever argued about the way your JSON responses should be formatted, JSON:API can be your anti-bikeshedding tool. JSON:API is a great way to expose a consistent API in your application.
In this session, we will talk about how JSON:API got to where it is today and how it can help you make Drupal the core of all your online transactions. We will check out the specifications and look at the main benefits of JSON:API and see how Drupal implemented the spec.
Expect to learn the structure and features of the JSON:API specifications and why it should be your smart default. You should be able to get started right away with some examples we will provide in this session.
Web Typography is exploding all over the web, we made a jQuery plugin to give you control over those new fonts. We also made this powerpoint for a talk on the same subject.
Crafting Custom Interfaces with Sub::ExporterRicardo Signes
Everybody knows about Exporter.pm: you use it, and if someone uses your module, they don't have to type quite as much. We'll look at how the Exporter works, and how it fails to take advantage of the powerful concepts on which it's built. We'll see how you can provide flexible import routines that allow your module's user to type even less and get code that behaves much more like part of his own program. You can avoid repeating unnecessary parameters to every overly-generic routine and can avoid collision-prone global configuration. All of this is made possible -- and easy -- by Sub::Exporter.
Generators -- routines that build routines -- can produce customized code, built to each importer's specifications. Sub::Exporter lets you build and provide customized routines easily. You'll learn how to write generators, and how to use them with Sub::Exporter . In its simplest form, it's as easy to use as Exporter.pm. With just a bit more configuration, it can build, group, rename, and julienne routines easily. With this tool, you'll be able to provide interfaces that are both simpler and more powerful than those provided by the stock Exporter.
Ruby is amazing. It has a huge standard library and a core choc full of weird and wonderful things. In this talk, given at the Ipswich Ruby User Group, I give a whimsical nonstop tour through some of the more obscure parts of Ruby.
2. Outline
✤ What are XPointers?
✤ Why should you care?
✤ Rebooting the TEI Pointer Guidelines
✤ Implementation and examples
3. What are XPointers?
✤ http://example.com/example.xml#xpath(//lb[@n='5'])
{
xpointer
✤ Tacked on to a URL to indicate a section inside the document.
✤ http://example.com/example.xml#anID (also an XPointer,
technically)
✤ TEI Xpointer Schemes:
http://www.tei-c.org/release/doc/tei-p5-doc/en/html/SA.html#SATS
4. TEI Pointers address:
✤ nodes (elements, attributes, or text nodes)
✤ points (conceptual locations between elements or inside text nodes)
✤ ranges (chunks of document between two points).
17. usage scenarios
✤ Including and transcluding text
✤ I want to import chunks of document from outside, or from
another part of my document.
✤ Leveraging annotations or standoff markup during transformations
✤ I want to make standoff annotations and have their effects show up
in the results
19. <div type="edition">
<ab>
<lb n="5"/><unclear>Ἰσ</unclear>ά<hi rend="diaeresis">ι</hi>ς ἁλιεύς <num value="5">ε</num>
</ab>
</div>
<div type="annotations">
<ab>
<name ref="#name1"><ref target="#match(//lb[@n='5'],'Ἰσάις')"/></name>
</ab>
</div>
5 Ἰ̣σ̣άι(¨)ς ἁλιεύς ε
On mouseover, we get more
info about the person, name, etc.,
pulled from the annotation.
20. Ovid, Ibis, Merkel & Ehwald Ovid, Ibis – apparatus, Owen
<?xml version="1.0" encoding="utf-8"?>
<TEI.2><text><body><div1 type="book" n="1" org="uniform" sample="complete"><p> <?xml version="1.0" encoding="UTF-8"?>
<pb id="p.103" /> <?xml-model href="http://www.tei-c.org/release/xml/tei/custom/schema/relaxng/tei_all.rng"
schematypens="http://relaxng.org/ns/structure/1.0"?>
<TEI
<lb rend="displayNum" n="1" /> xmlns="http://www.tei-c.org/ns/1.0">
<milestone unit="alt" n="1" />Tempus ad hoc; lustris bis iam mihi quinque peractis, <teiHeader>
<lb rend="displayNum" n="2" />Omne fuit Musae carmen inerme meae; <fileDesc>
<lb rend="displayNum" n="3" />Nullaque; quae possit; scriptis tot milibus, extat <titleStmt>
<lb rend="displayNum" n="4" />Littera Nasonis sanguinolenta legi: <title>Ovid: Ibis – Apparatus</title>
<lb rend="displayNum" n="5" /> Nec quemquam nostri nisi me laesere libelli, </titleStmt>
<lb rend="displayNum" n="6" />Artificis periit cum caput Arte sua. <publicationStmt>
<lb rend="displayNum" n="7" />Unus — et hoc ipsum est iniuria magna — perennem <p>An experiment</p>
</publicationStmt>
<lb rend="displayNum" n="8" />Candoris titulum non sinit esse mei. <sourceDesc>
<lb rend="displayNum" n="9" />Quisquis is est, — nam nomen adhuc utcumque tacebo — <p><bibl>S. G. Owen, <title>P. Ovidi Nasonis Tristium Libri Quinque,
<lb rend="displayNum" n="10" /> Cogit inassuetas sumere tela manus. Ibis, Ex Ponto Libri Quattuor, Halieutica Fragmenta, Oxford (1915)</title></bibl></p>
<lb rend="displayNum" n="11" />Ille relegatum gelidos aquilonis ad ortus </sourceDesc>
</fileDesc>
<lb rend="displayNum" n="12" />Non sinit exilio delituisse meo; </teiHeader>
<lb rend="displayNum" n="13" />Vulneraque inmitis requiem quaerentia vexat, <text>
<lb rend="displayNum" n="14" />Iactat et in toto nomina nostra foro; <body>
<lb rend="displayNum" n="15" /> Perpetuoque mihi sociatam foedere lecti <div type="apparatus">
<lb rend="displayNum" n="16" />Non patitur vivi funera flere viri. <ab>
<lb rend="displayNum" n="17" />Cumque ego quassa meae complectar membra carinae, <app corresp="ibis-perseus.xml#match(//lb[@n='9'],'tacebo')">
<lb rend="displayNum" n="18" />Naufragii tabulas pugnat habere mei: <lem>tacebo</lem>
<lb rend="displayNum" n="19" />Et qui debuerat subitas extinguere flammas, <rdg wit="#F #T #X">latebit</rdg>
<lb rend="displayNum" n="20" /> Hic praedam medio raptor ab igne petit. </app>
<app corresp="ibis-perseus.xml#match(//lb[@n='30'],'Qua')">
<lb rend="displayNum" n="21" /> <lem>quod</lem>
<milestone unit="alt" n="2" />Nititur, ut profugae desint alimenta senectae. <rdg wit="#G">qua</rdg>
<lb rend="displayNum" n="22" />Heu! quanto est nostris dignior ipse malis! <rdg wit="#P">quam</rdg>
</app>
<pb id="p.104" /> <app corresp="ibis-perseus.xml#match(//lb[@n='30'],'ei!')">
<lem wit="#P">et</lem>
<lb rend="displayNum" n="23" />Di melius; quorum longe mihi maximus ille est, <rdg wit="#F #H #T #V">hei</rdg>
<lb rend="displayNum" n="24" />Qui nostras inopes noluit esse vias. <rdg wit="#G #X #Zamoscianus">heu</rdg>
<lb rend="displayNum" n="25" /> Huic igitur meritas grates, ubicumque licebit, </app>
<lb rend="displayNum" n="26" />Pro tam mansueto pectore semper agam. </ab>
<lb rend="displayNum" n="27" />Audiat hoc Pontus. faciet quoque forsitan idem, </div>
</body>
<lb rend="displayNum" n="28" />Terra sit ut propior testificanda mihi. </text>
<lb rend="displayNum" n="29" />At tibi, calcasti qui me, violente, iacentem, </TEI>
<lb rend="displayNum" n="30" /> Qua licet ei! misero, debitus hostis ero.
21. Ovid, Ibis, Merkel & Ehwald Ovid, Ibis – apparatus, Owen
<?xml version="1.0" encoding="utf-8"?>
<TEI.2><text><body><div1 type="book" n="1" org="uniform" sample="complete"><p> <?xml version="1.0" encoding="UTF-8"?>
<pb id="p.103" /> <?xml-model href="http://www.tei-c.org/release/xml/tei/custom/schema/relaxng/tei_all.rng"
schematypens="http://relaxng.org/ns/structure/1.0"?>
<TEI
<lb rend="displayNum" n="1" /> xmlns="http://www.tei-c.org/ns/1.0">
<milestone unit="alt" n="1" />Tempus ad hoc; lustris bis iam mihi quinque peractis, <teiHeader>
<lb rend="displayNum" n="2" />Omne fuit Musae carmen inerme meae; <fileDesc>
<lb rend="displayNum" n="3" />Nullaque; quae possit; scriptis tot milibus, extat <titleStmt>
<lb rend="displayNum" n="4" />Littera Nasonis sanguinolenta legi: <title>Ovid: Ibis – Apparatus</title>
<lb rend="displayNum" n="5" /> Nec quemquam nostri nisi me laesere libelli, </titleStmt>
<lb rend="displayNum" n="6" />Artificis periit cum caput Arte sua. <publicationStmt>
<lb rend="displayNum" n="7" />Unus — et hoc ipsum est iniuria magna — perennem <p>An experiment</p>
</publicationStmt>
<lb rend="displayNum" n="8" />Candoris titulum non sinit esse mei. <sourceDesc>
<lb rend="displayNum" n="9" />Quisquis is est, — nam nomen adhuc utcumque tacebo — <p><bibl>S. G. Owen, <title>P. Ovidi Nasonis Tristium Libri Quinque,
<lb rend="displayNum" n="10" /> Cogit inassuetas sumere tela manus. Ibis, Ex Ponto Libri Quattuor, Halieutica Fragmenta, Oxford (1915)</title></bibl></p>
<lb rend="displayNum" n="11" />Ille relegatum gelidos aquilonis ad ortus </sourceDesc>
</fileDesc>
<lb rend="displayNum" n="12" />Non sinit exilio delituisse meo; </teiHeader>
<lb rend="displayNum" n="13" />Vulneraque inmitis requiem quaerentia vexat, <text>
<lb rend="displayNum" n="14" />Iactat et in toto nomina nostra foro; <body>
<lb rend="displayNum" n="15" /> Perpetuoque mihi sociatam foedere lecti <div type="apparatus">
<lb rend="displayNum" n="16" />Non patitur vivi funera flere viri. <ab>
<lb rend="displayNum" n="17" />Cumque ego quassa meae complectar membra carinae, <app corresp="ibis-perseus.xml#match(//lb[@n='9'],'tacebo')">
<lb rend="displayNum" n="18" />Naufragii tabulas pugnat habere mei: <lem>tacebo</lem>
<lb rend="displayNum" n="19" />Et qui debuerat subitas extinguere flammas, <rdg wit="#F #T #X">latebit</rdg>
<lb rend="displayNum" n="20" /> Hic praedam medio raptor ab igne petit. </app>
<app corresp="ibis-perseus.xml#match(//lb[@n='30'],'Qua')">
<lb rend="displayNum" n="21" /> <lem>quod</lem>
<milestone unit="alt" n="2" />Nititur, ut profugae desint alimenta senectae. <rdg wit="#G">qua</rdg>
<lb rend="displayNum" n="22" />Heu! quanto est nostris dignior ipse malis! <rdg wit="#P">quam</rdg>
</app>
<pb id="p.104" /> <app corresp="ibis-perseus.xml#match(//lb[@n='30'],'ei!')">
<lem wit="#P">et</lem>
<lb rend="displayNum" n="23" />Di melius; quorum longe mihi maximus ille est, <rdg wit="#F #H #T #V">hei</rdg>
<lb rend="displayNum" n="24" />Qui nostras inopes noluit esse vias. <rdg wit="#G #X #Zamoscianus">heu</rdg>
<lb rend="displayNum" n="25" /> Huic igitur meritas grates, ubicumque licebit, </app>
<lb rend="displayNum" n="26" />Pro tam mansueto pectore semper agam. </ab>
<lb rend="displayNum" n="27" />Audiat hoc Pontus. faciet quoque forsitan idem, </div>
</body>
<lb rend="displayNum" n="28" />Terra sit ut propior testificanda mihi. </text>
<lb rend="displayNum" n="29" />At tibi, calcasti qui me, violente, iacentem, </TEI>
<lb rend="displayNum" n="30" /> Qua licet ei! misero, debitus hostis ero.
22. Perseus’ Ibis:
30 Qua licet ei! misero, debitus hostis ero.
Perseus’ Ibis with Owen’s apparatus lemmata interpolated:
30 quod licet et misero, debitus hostis ero.
23. Perseus’ Ibis:
30 Qua licet ei! misero, debitus hostis ero.
Perseus’ Ibis with Owen’s apparatus lemmata interpolated:
30 quod licet et misero, debitus hostis ero.
“Another poem, more than 600 lines long, was written by Ovid in his
exile and has come down to our own times. Its name is not on Mr.
Owen’s title-page, but under cover of this silence, it has been slipped
into the middle of the book, — medio tutissimus Ibis, as its author
himself observed, — apparently in the hope that it may escape
notice. Well, so it shall.” – A. E. Housman
25. Where are we now?
✤ Draft spec: http://goo.gl/8YRqe
26. Where are we now?
✤ Draft spec: http://goo.gl/8YRqe
✤ I'm working on a reference implementation of the draft spec as it
stands: https://github.com/hcayless/tei-pointers
(very little there, and not yet working, but watch this space)
27. Where are we now?
✤ Draft spec: http://goo.gl/8YRqe
✤ I'm working on a reference implementation of the draft spec as it
stands: https://github.com/hcayless/tei-pointers
(very little there, and not yet working, but watch this space)
✤ This talk: http://goo.gl/4R5zo
28. Where are we now?
✤ Draft spec: http://goo.gl/8YRqe
✤ I'm working on a reference implementation of the draft spec as it
stands: https://github.com/hcayless/tei-pointers
(very little there, and not yet working, but watch this space)
✤ This talk: http://goo.gl/4R5zo
✤ Thanks!
Editor's Notes
I am painfully aware that this is the last paper of the last session of the day, and that I&#x2019;m all that stands between you and beer. And, moreover, that the topic I&#x2019;m presenting on isn&#x2019;t the most accessible one ever. I hope the dry topic will make the beer that much more refreshing afterwards\n\n
\n
XPointers are an extension to URLs. What's a URL? A URL is an address. It tells you where to go, but (I must emphasize) not what to do when you get there. XPointers are tacked onto a URL and address a location inside the document referenced by the URL. This is an important point, because although XPointers look very much like programming language functions, they are not functions. They don't actually dictate what happens to the things they address, they just tell you how to get there.\n\nTEI has a set of XPointer schemes, detailed at http://www.tei-c.org/release/doc/tei-p5-doc/en/html/SA.html#SATS \nWarning: this section is so abstract, you may temporarily lose the will to live while reading it. It has been the victim of a Catch-22. It is difficult enough to grasp that most people never bother to try using it, and so few people have tried using it that it has never accumulated a good set of implementations and use-cases.\n
\n
Well, this is a good question. If nobody ever uses them, should they even exist? I've come to the conclusion that they do actually cover a set of edge cases that are worth dealing with and that more people are likely to run into as TEI adoption spreads.\n\nThe TEI has satisfactorily proved by example that trees make for a very useful (even though not perfect) data structure for documents of many kinds. Trees have the advantage over simpler constructs of being easy to navigate. The XML tree-structure even has a path language which can be used to address nodes in a document or retrieve values from it. With XML and XPath, we can get at pretty much any part of a TEI document that we might want. So what is the point of Pointers?\n\nWell, XPointers allow you to address unmarked pieces of a document. They let you address things like a name embedded in a chunk of text, or an apparatus lemma spanning a series of elements and partial text nodes. You may object: "well, you can do that with XPath too!" But in fact, technically, you can't. XPath does have a number of functions that allow you to get at bits of text (substring, string-before, string-after, and so-on), but these functions return atomic values rather than nodes in the document tree. In other words, they return the text but discard the context. &#xA0;This is ok for certain modes of work, but if what you actually want to do is address the text in its context, then XPath may not work for you, because it can only address whole nodes in their context.\n
Now, I mentioned earlier that these are edge cases, and they are, because if you want to say something about a chunk of text in an XML document, what you typically do is put some markup around it with an id attribute that you can point to. Easy. Done.\n\nThe XPointer use case comes in when for some reason you can't insert new elements into the target document or when you really don't want to. &#xA0;This might happen if you wanted to have markup that annotates a document published by someone else, and you don't want to or can't re-host a derivative version with your own markup added. We have another use case at papyri.info, a project I work on which provides online editing of editions of ancient documents. Our markup editor only deals with marking up aspects of the text, not things like names, organizations, dates, etc. To add more types of markup to the mix would be to raise the complexity bar too high. So if we want to add that kind of markup, we'll need to do it in a standoff fashion, using something like TEI Pointers.\n\nSo the answer is, actually, that you probably don't need to care until or unless you run smack into one of these edge cases. Then you may find that you suddenly start to care a lot.\n
Now, I mentioned earlier that these are edge cases, and they are, because if you want to say something about a chunk of text in an XML document, what you typically do is put some markup around it with an id attribute that you can point to. Easy. Done.\n\nThe XPointer use case comes in when for some reason you can't insert new elements into the target document or when you really don't want to. &#xA0;This might happen if you wanted to have markup that annotates a document published by someone else, and you don't want to or can't re-host a derivative version with your own markup added. We have another use case at papyri.info, a project I work on which provides online editing of editions of ancient documents. Our markup editor only deals with marking up aspects of the text, not things like names, organizations, dates, etc. To add more types of markup to the mix would be to raise the complexity bar too high. So if we want to add that kind of markup, we'll need to do it in a standoff fashion, using something like TEI Pointers.\n\nSo the answer is, actually, that you probably don't need to care until or unless you run smack into one of these edge cases. Then you may find that you suddenly start to care a lot.\n
Now, I mentioned earlier that these are edge cases, and they are, because if you want to say something about a chunk of text in an XML document, what you typically do is put some markup around it with an id attribute that you can point to. Easy. Done.\n\nThe XPointer use case comes in when for some reason you can't insert new elements into the target document or when you really don't want to. &#xA0;This might happen if you wanted to have markup that annotates a document published by someone else, and you don't want to or can't re-host a derivative version with your own markup added. We have another use case at papyri.info, a project I work on which provides online editing of editions of ancient documents. Our markup editor only deals with marking up aspects of the text, not things like names, organizations, dates, etc. To add more types of markup to the mix would be to raise the complexity bar too high. So if we want to add that kind of markup, we'll need to do it in a standoff fashion, using something like TEI Pointers.\n\nSo the answer is, actually, that you probably don't need to care until or unless you run smack into one of these edge cases. Then you may find that you suddenly start to care a lot.\n
Earlier this year, a working group on TEI Pointers was convened. The members include myself, Piotr Ba&#x144;ski, Syd Bauman, Gabriel Bodard, Martin Holmes, and Laurent Romary. We've been discussing what to do about the Pointers section in the guidelines, starting with the development of a set of use cases, and moving on to the development of a draft update to the section, which I've been editing (with feedback from the other members). Discussions are still ongoing, and the following represents my own views, not those of the working group as a whole, though it has certainly been informed and I hope improved by their input..\n
There are a variety of problems with the TEI Pointer schemes as currently defined. The first being the negative feedback loop that I identified earlier, where lack of implementations mean lack of use, which means lack of use cases, which means lack of work on implementations. We need to break that cycle by providing a reference implementation for whatever we end up recommending.\n\nSecond, the specification needs to be made more explicit and less abstract, so that it is actually possible to develop implementations. This includes detailing what exactly a TEI Pointer addresses when it indicates a point or a range, tightening up the syntax, and modifying or adding to the definitions in the specification.\n
So, what is a point? This is tricky, because they don&#x2019;t exist. They are a useful construct for saying where to start or stop when grabbing a chunk of document, or maybe for describing where to insert a bookmark, but they don&#x2019;t correspond to anything actually in an XML document, and particularly not to anything in the XML Infoset. So points are a bit theoretical. The old specification defines them as the positions next to elements or between characters in a text node. The old specification does not make it entirely clear, but there have to be strict limitations on where points can be. They can&#x2019;t be in the middle of an element (i.e. between the brackets), for example. Though perhaps they could be inside an attribute.\n
Points can define the start and end of a range. So a range is the piece of document between two points. But again, we have to be careful about what that means. In the draft specification, I&#x2019;ve taken a hard line that ranges can&#x2019;t contain partial elements, so if you do something silly like [range-1.graffle], you don&#x2019;t get the elements foo, bar, and baz at all. Instead you get a sequence that looks like ("\\n &#xA0;", "\\n &#xA0;&#xA0;&#xA0;", "Here be"). \n
You only get elements when the whole element is part of the sequence. This solves a big implementation roadblock, because it&#x2019;s very difficult (maybe impossible) to know how to deal with a range containing what would be not-well-formed markup. There&#x2019;s no such thing as half an element node in the XML DOM, for example. By defining exactly what a range can be&#x2014;basically what&#x2019;s called a Sequence in XSLT 2.0&#x2014;we can eliminate that obstacle to implementation.\n\nSo this is all very boring. Thanks to those of you who&#x2019;ve managed to stay awake this far! It&#x2019;s also a bit mad&#x2014;Nobody in their right mind is going to type most of these things. We might find ways of generating them though.\n
\n\nLet&#x2019;s see if we can figure out how pointers might actually be useful. I noted earlier that the set of use cases I see this technology targeting are cases where you want to layer new markup on top of existing markup that you either can&#x2019;t, or don&#x2019;t want to change. There&#x2019;s a caveat built in here: as with any URL, you are taking a risk that the thing you point at won&#x2019;t always be there. If you&#x2019;re using pointers with documents that change regularly, you&#x2019;ll need to come up with strategies for mitigating the risk of broken links.\n\nSome usage scenarios I can think of are:\n\nIncluding and transcluding text: I want to import chunks of document from outside, or from another part of my document.\nLeveraging annotations or standoff markup during transformations\n\n
I'll conclude with a couple of examples of ways I might use TEI pointers in my own work. In Papyri.info, we take a very opinionated view of how texts should be structured. These are editions of texts where the object is to present the nature of the text as observed and interpreted by its editors. So we take care to mark things like gaps in the text, unclear letters, aspects of how the scribe wrote the text, editorial supplements, etc. We do not mark names of places, people, organizations, dates, events, and so on. If we did this inline it would be too much of a mess. Nevertheless, this is something we'll want to do. We might do something like slide 13: leverage the annotation in the HTML output by using it to supply a callout with further information on mouseover.\n
I'll conclude with a couple of examples of ways I might use TEI pointers in my own work. In Papyri.info, we take a very opinionated view of how texts should be structured. These are editions of texts where the object is to present the nature of the text as observed and interpreted by its editors. So we take care to mark things like gaps in the text, unclear letters, aspects of how the scribe wrote the text, editorial supplements, etc. We do not mark names of places, people, organizations, dates, events, and so on. If we did this inline it would be too much of a mess. Nevertheless, this is something we'll want to do. We might do something like slide 13: leverage the annotation in the HTML output by using it to supply a callout with further information on mouseover.\n
Second, I've started as an experiment to see how you might take the apparatus from one edition and apply it to an earlier edition. Perseus has an edition of Ovid's Ibis from 1879 that they publish, and they make the XML available. What if I wanted to take their text, but use S. G. Owen's apparatus from his 1915 Oxford Classical Text to "enhance" it?\n
Second, I've started as an experiment to see how you might take the apparatus from one edition and apply it to an earlier edition. Perseus has an edition of Ovid's Ibis from 1879 that they publish, and they make the XML available. What if I wanted to take their text, but use S. G. Owen's apparatus from his 1915 Oxford Classical Text to "enhance" it?\n
Second, I've started as an experiment to see how you might take the apparatus from one edition and apply it to an earlier edition. Perseus has an edition of Ovid's Ibis from 1879 that they publish, and they make the XML available. What if I wanted to take their text, but use S. G. Owen's apparatus from his 1915 Oxford Classical Text to "enhance" it?\n
Second, I've started as an experiment to see how you might take the apparatus from one edition and apply it to an earlier edition. Perseus has an edition of Ovid's Ibis from 1879 that they publish, and they make the XML available. What if I wanted to take their text, but use S. G. Owen's apparatus from his 1915 Oxford Classical Text to "enhance" it?\n
Second, I've started as an experiment to see how you might take the apparatus from one edition and apply it to an earlier edition. Perseus has an edition of Ovid's Ibis from 1879 that they publish, and they make the XML available. What if I wanted to take their text, but use S. G. Owen's apparatus from his 1915 Oxford Classical Text to "enhance" it?\n
Second, I've started as an experiment to see how you might take the apparatus from one edition and apply it to an earlier edition. Perseus has an edition of Ovid's Ibis from 1879 that they publish, and they make the XML available. What if I wanted to take their text, but use S. G. Owen's apparatus from his 1915 Oxford Classical Text to "enhance" it?\n
As an aside, this isn't necessarily something you'd want to do, except as a way of examining the scholarly tradition. A.E. Housman had nothing good to say about Owen's edition.\n
So the current state of play is this: I've been working on a draft specification, which is open for comment on Google Drive at https://docs.google.com/document/d/1JsMA-gOGrevyY-crzHGiC7eZ8XdV5H_wFTlUGzrf20w/edit# &#x2014; this is under revision in my copious spare time, and I've started (only started, mind!) building a reference implementation at https://github.com/hcayless/tei-pointers. There is really nothing to look at there yet, but I'm trying to make progress on it, so watch this space!\n
So the current state of play is this: I've been working on a draft specification, which is open for comment on Google Drive at https://docs.google.com/document/d/1JsMA-gOGrevyY-crzHGiC7eZ8XdV5H_wFTlUGzrf20w/edit# &#x2014; this is under revision in my copious spare time, and I've started (only started, mind!) building a reference implementation at https://github.com/hcayless/tei-pointers. There is really nothing to look at there yet, but I'm trying to make progress on it, so watch this space!\n
So the current state of play is this: I've been working on a draft specification, which is open for comment on Google Drive at https://docs.google.com/document/d/1JsMA-gOGrevyY-crzHGiC7eZ8XdV5H_wFTlUGzrf20w/edit# &#x2014; this is under revision in my copious spare time, and I've started (only started, mind!) building a reference implementation at https://github.com/hcayless/tei-pointers. There is really nothing to look at there yet, but I'm trying to make progress on it, so watch this space!\n
So the current state of play is this: I've been working on a draft specification, which is open for comment on Google Drive at https://docs.google.com/document/d/1JsMA-gOGrevyY-crzHGiC7eZ8XdV5H_wFTlUGzrf20w/edit# &#x2014; this is under revision in my copious spare time, and I've started (only started, mind!) building a reference implementation at https://github.com/hcayless/tei-pointers. There is really nothing to look at there yet, but I'm trying to make progress on it, so watch this space!\n