Questions tagged [sgml]

Standard Generalized Markup Language (SGML) is the precursor to XML and HTML. It is an ISO standard (ISO 8879) that was used for electronic publishing of documents and books.

Standard Generalized Markup Language (SGML) is the precursor to XML and HTML. It is an ISO standard (ISO 8879) that was used for electronic publishing of documents and books.


Useful links

134 questions
73
votes
5 answers

Where is the HTML5 Document Type Definition?

The "old" HTML/XHTML standards have a DTD (Document Type Definition) defined for them: HTML 4.01 http://www.w3.org/TR/html401/sgml/dtd.html XHTML 1.0 http://www.w3.org/TR/xhtml1/dtds.html#a_dtd_XHTML-1.0-Strict This DTDs specify the rules for…
Šime Vidas
  • 182,163
  • 62
  • 281
  • 385
50
votes
4 answers

Is HTML a context-free language?

Reading some related questions made me think about the theoretical nature of HTML. I'm not talking about XHTML-like code here. I'm talking about stuff like this crazy piece of markup, which is perfectly valid HTML(!)
user123444555621
  • 148,182
  • 27
  • 114
  • 126
24
votes
3 answers

HTML comments break down

I have a page that is generated which inserts an HTML comment near the top of the page. Inside the comment is a *nix-style command. This comment breaks the page completely. What is wrong…
Rudd Zwolinski
  • 26,712
  • 17
  • 57
  • 60
20
votes
6 answers

SGML parser in Java?

I'm looking for a parser in Java that can parse a document formatted in SGML. For duplicate monitors: I'm aware of the two other threads that discuss this topic: Parsing Java String with SGML Java SGML to XML conversion? But neither has a…
user183037
  • 2,549
  • 4
  • 31
  • 42
19
votes
1 answer

Parse SGML with Open Arbitrary Tags in Python 3

I am trying to parse a file such as: http://www.sec.gov/Archives/edgar/data/1409896/000118143112051484/0001181431-12-051484.hdr.sgml I am using Python 3 and have been unable to find a solution with existing libraries to parse an SGML file with open…
borncamp
  • 300
  • 2
  • 5
18
votes
2 answers

HTML5 is not based on SGML, so what is it based on then?

http://www.w3schools.com/tags/tag_doctype.asp HTML5 is not based on SGML, and therefore does not require a reference to a DTD. On what standard is HTML 5 based on if not on SGML?
Aquarius_Girl
  • 21,790
  • 65
  • 230
  • 411
14
votes
5 answers

Is > ever necessary?

I now develop websites and XML interfaces since 7 years, and never, ever came in a situation, where it was really necessary to use the > for a >. All disambiguition could so far be handled by quoting <, &, " and ' alone. Has anyone ever been in a…
Boldewyn
  • 81,211
  • 44
  • 156
  • 212
12
votes
3 answers

What is the difference between SGML and XML?

All the Google results suck.
Tom Lehman
  • 85,973
  • 71
  • 200
  • 272
9
votes
4 answers

Parsing EDGAR filings

I would like to use python2.7 to remove anything that isn't the documents' text from EDGAR filings (which are available online as .txt files). An example of what the files look like is here: Example EDGAR provides its Document Type Definitions…
philq
  • 157
  • 1
  • 1
  • 8
8
votes
3 answers

Are there any reasons to use SGML instead of XML?

As I understand it, XML is a subset of SGML conceived to simplify it and encourage a more widespread usage. I guess most useful features was brought into XML, but are there any features in SGML powerful enough to motivate using it instead of XML…
sharkin
  • 12,162
  • 24
  • 86
  • 122
8
votes
3 answers

Why can't SGML::Parser::OpenSP find the symbol __ZTI15SGMLApplication?

I'm trying to "install SGML::Parser::OpenSP" from the cpan shell, but it fails on the first "make test". I also get the same error if I go into the build directory and run make test. I believe this bit of the output below is the relevant part. Note…
Josh
8
votes
3 answers

How to parse a OFX (Version 1.0.2) file in PHP?

I have a OFX file downloaded from Citibank, this file has a DTD defined at http://www.ofx.net/DownloadPage/Files/ofx102spec.zip (file OFXBANK.DTD), the OFX file appear to be SGML valid. I'm trying with DomDocument of PHP 5.4.13, but I get several…
Jose Nobile
  • 3,243
  • 4
  • 23
  • 30
8
votes
4 answers

Definition of HTML whitespace rules?

I'm looking for this definition to make my HTML renderer conform a bit better. Currently it's guessing which whitespace to keep, which to collapse and what to throw. The SGML standard is hard to find and the HTML standard doesn't seem to treat the…
fret
  • 1,542
  • 21
  • 36
7
votes
1 answer

How can I stop empty XML elements self-closing using XmlDocument in C#?

Before I get jumped on by people saying the XML parser shouldn’t care if the elements are empty or self-closed, there is a reason why I can’t allow self-closed XML elements. The reason is that I’m actually working with SGML not XML and the SGML DTD…
Can'tCodeWon'tCode
  • 543
  • 1
  • 11
  • 36
7
votes
1 answer

Make emacs always close html tags

How can I make emacs always close a sgml-tag (C-c-C-t)? For example div, h2 tags work fine but p or li do not. Basically I'm looking for a way of specifing that I'm always using xhtml when I insert a tag.
vise
  • 12,713
  • 11
  • 52
  • 64
1
2 3
8 9