text page 6 - Dave's Blog

Search
My timeline on Mastodon

Cadbury Nibbles Toy Box

2008 Sep 1, 4:17
Cadbury sits in and eats her box of toys. She enjoys eating her toy box more often than playing with any of the toys.
From: David Risney
Views: 343
2 ratings
Time: 00:16 More in Pets & Animals
PermalinkCommentsvideo

Tag Metadata in Feeds

2008 Aug 25, 10:13

As noted previously, my page consists of the aggregation of my various feeds and in working on that code recently it was again brought to my attention that everyone has different ways of representing tag metadata in feeds. I made up a list of how my various feed sources represent tags and list that data here so that it might help others in the future.

Tag markup from various sources
Source Feed Type Tag Markup Scheme One Tag Per Element Tag Scheme URI Human / Machine Names Example Markup
LiveJournal Atom atom:category yes no no , (source)
LiveJournal RSS 2.0 rss2:category yes no no technical
(soure)
WordPress RSS 2.0 rss2:category yes no no , (source)
Delicious RSS 1.0 dc:subject no no no photosynth photos 3d tool
(source)
Delicious RSS 2.0 rss2:category yes yes no domain="http://delicious.com/SequelGuy/">
hulu

(source)
Flickr Atom atom:category yes yes no term="seattle"
scheme="http://www.flickr.com/photos/tags/" />

(source)
Flickr RSS 2.0 media:category no yes no scheme="urn:flickr:tags">
seattle washington baseball mariners

(source)
YouTube RSS 2.0 media:category no no no label="Tags">
bunny rabbit yawn cadbury

(source)
LibraryThing RSS 2.0 No explicit tag metadata. no no no n/a, (source)
Tag markup scheme
Tag Markup Scheme Notes Example
Atom Category
atom:category
xmlns:atom="http://www.w3.org/2005/Atom"
category/@term
Required category name.
category/@scheme
Optional IRI id'ing the categorization scheme.
category/@label
Optional human readable category name.
term="catName"
scheme="tag:deletethis.net,2008:tagscheme"
label="category name in human readable format"/>
RSS 2.0 category
rss2:category
empty namespace
category/@domain
Optional string id'ing the categorization scheme.
category/text()
Required category name. The value of the element is a forward-slash-separated string that identifies a hierarchic location in the indicated taxonomy. Processors may establish conventions for the interpretation of categories.
domain="tag:deletethis.net,2008:tagscheme">
MSFT
Yahoo Media RSS Module category
media:category
xmlns:media="http://search.yahoo.com/mrss/"
category/text()
Required category name.
category/@domain
Optional string id'ing the categorization scheme.
scheme="http://dmoz.org"
label="Ace Ventura - Pet Detective">
Arts/Movies/Titles/A/Ace_Ventura_Series/Ace_Ventura_-_Pet_Detective
Dublin Core subject
dc:subject
xmlns:dc="http://purl.org/dc/elements/1.1/"
subject/text()
Required category name. Typically, the subject will be represented using keywords, key phrases, or classification codes. Recommended best practice is to use a controlled vocabulary.
humor

Update 2009-9-14: Added WordPress to the Tag Markup table and namespaces to the Tag Markup Scheme table.

PermalinkCommentsfeed media delicious technical atom youtube yahoo rss tag

Flickr: Seattle Municipal Archives

2008 Aug 25, 11:39"The Seattle Municipal Archives documents the history, development, and activities of the agencies and elected officials of the City of Seattle. Strengths of the records include those documenting engineering, parks, urban planning, the legislative process and elected officials. Holdings include over 6,000 cubic feet of textual records; 3,000 maps and drawings, 3,000 audiotapes; hundreds of hours of motion picture film; and over 1.5 million photographic images of City projects and personnel."PermalinkCommentsvia:swannman photo flickr seattle history public-domain

YouTube - Norm MacDonald - Bob Saget roast

2008 Aug 18, 4:06Norm MacDonald performs at the roast of Bob Saget. Must be viewed with context of entire roast in mind in which roasters spout profane offensive insult humor. Norm does a sort of un-roast consisting of jokes from the back of milk cartons or cracker jack boxes. Not at all offensive. Funny conceptually and of course since its Norm MacDonald its hilarious in practice. Later described by Jim Norton: "Watching your set, was like watching Henry Fonda pick blueberries."PermalinkCommentsnorm-macdonald bob-saget roast comedy-central humor video youtube

How to Clean Old Markings off a Whiteboard (super secret method)

2008 Aug 8, 2:51

Photo of Whiteboard, by Richard HoldenI've got a new office and I must clean off my inherited whiteboard. The previous owner left various diagrams, code snippets, etc. on for such a time that they can no longer be erased by conventional means: the whiteboard eraser is useless! I couldn't find any whiteboard cleaner either, but Ali told me the following secret. You can write over the dried on text with a normal dry erase marker. When you erase the new markings the old are erased as well. It sounds too fantastic, but believe me, its true! I don't know the brand or material of the whiteboard but the whiteboard markers are 'Expo, Bold Color Dry Erase'.

PermalinkCommentserase howto whiteboard office secret nontechnical

New office, new cubes

2008 Aug 5, 6:32

Second Window OfficeNew Patent CubesMy previous window office was ripped from me when our team moved buildings but now I've got another. The photo is poor because I didn't get the lighting correct and it depicts the office before I've moved all my crap into it. I have a lovely view of our parking lot and freeway which Jane spun as an 'urban view'. At any rate I'm not complaining: I like knowing what its like outside and that there is an outside. The day after I found out about my office, I also got two new patent cubes. I didn't have any pictures last time so I took some now and blacked out their text for fear of laywers.

PermalinkCommentsmicrosoft patent cube office nontechnical

Fast hashing of variable-length text strings

2008 Jul 3, 10:12"Fast hashing of variable-length text strings", from Source Communications of the ACM archive Volume 33 , Issue 6 (June 1990) Pages: 677 - 680, Year of Publication: 1990, Author Peter K. Pearson, Lawrence Livermore National Lab, Livermore, CAPermalinkCommentshash programming acm reference

Wordle - Beautiful Word Clouds

2008 Jun 19, 7:09"Wordle is a toy for generating "word clouds" from text that you provide. The clouds give greater prominence to words that appear more frequently in the source text. You can tweak your clouds with different fonts, layouts, and color schemes. The imagePermalinkCommentsart word design visualization ui java

Wordle - SequelGuy's Delicious Tags

2008 Jun 19, 4:53Create word art from your Delicious tags or any arbitrary block of text. Neat.PermalinkCommentsme delicious tag tagging word

Catalog | Stickers | Sticker #213: Orwell was Right | Microcosm Publishing

2008 Jun 9, 11:34Sticker depicting two CC camers with the text 'Orwell was Right' under.PermalinkCommentssticker orwell purchase shirt product camera privacy

Generating N-D Tetris Pieces

2008 Jun 1, 7:27

When I woke up this morning for some reason I was thinking about Polytope Tetris, my N-D Tetris game, and specifically generating Tetris pieces in various number of dimensions. When I first wrote PTT I thought that as the number of dimensions increased you could end up with an infinite number of non-equivalent crazy Tetris pieces. However this morning I realized that because you only get four blocks per piece there are only a possible three joints in a single Tetris piece which means that you only need three dimensions to represent all possible distinct N-D Tetris pieces.

Below is the table of the various possible pieces per number of dimensions and sorted by the number of joints in the piece. Notice that the 'J' and 'L' become equivalent in 3D because you can rotate the 'J' through the third dimension to make it an 'L'. The same happens for 'S' and 'Z' in 3D, and 'S+' and 'Z+' in 4D.

Joints Name 1D 2D 3D +
1 I I I I I
2 J J J J
L L
3 O O O O
T T T T
S S S S
Z Z
T+ T+ T+
S+ S+ S+
Z+ Z+
Total 1 7 8 7

As a consequence of not realizing there's a finite and small number of N-D Tetris pieces, I wrote code that would randomly generate pieces for a specified number of dimensions by wandering through Tetris space. This consists of first marking the current spot, then randomly picking a direction (a dimension and either forward or backward), going in that direction until hitting a previously unvisited spot and repeating until four spots are marked, forming a Tetris piece. However this morning I realized that continuing in the same direction until reaching am unvisited spot means I can't generate the 'T+' piece. I think the better way to go is keep the list of all possible pieces, pick one randomly, and rotate it randomly through the available dimensions. Doing this will also allow me to give distinct pieces their own specific color (like the classic Tetris games do) rather than picking the color randomly like I do now.

PermalinkCommentspolytope tetris tetris

Watermind Home of the American Classics Line featuring Rosie the Riveter

2008 May 28, 3:27A WWI poster with a fallen plane and the text "consider the possible consequences if you are careless in your work". I feel like this should go up in Eric's office.PermalinkCommentsposter purchase wwi propaganda

Internet Anagram Server : Anagrams for david risney

2008 May 9, 5:53W/o my middle name: Add ivy resin, Daisy driven. W/ my middle name: Envy is deadlier, Evil nerdy ideasPermalinkCommentsdavid-risney me anagram text

Font embedding on the Web - Wikipedia, the free encyclopedia

2008 May 9, 9:32"The CSS2 specification adopted Microsoft's @font-face rule as the standard method for embedding fonts. However, Safari is the only browser other than Internet Explorer that supports @font-face, and it supports TrueType fonts instead of EOT fonts."PermalinkCommentsfont text web webdesign microsoft browser safari ie css

Microsoft Typography - Font embedding for the Web

2008 May 9, 9:31"In 1997, we released the preview version of Microsoft Web Embedding Fonts Tool (WEFT), which allows you to create font objects that can be linked to your Web pages."PermalinkCommentsmicrosoft msdn font web webdesign text

FontStruct | Build, Share, Download Fonts

2008 May 9, 9:25Create fonts online, download the resulting font as a TrueType font, embed the font in a webpage. Requires created fonts to be released under creative commons. The embedding method is lame - via Flash.PermalinkCommentsfont development web graphic free cc creativecommons text

URI Fragment Info Roundup

2008 Apr 21, 11:53

['Neverending story' by Alexandre Duret-Lutz. A framed photo of books with the droste effect applied. Licensed under creative commons.]Information about URI Fragments, the portion of URIs that follow the '#' at the end and that are used to navigate within a document, is scattered throughout various documents which I usually have to hunt down. Instead I'll link to them all here.

Definitions. Fragments are defined in the URI RFC which states that they're used to identify a secondary resource that is related to the primary resource identified by the URI as a subset of the primary, a view of the primary, or some other resource described by the primary. The interpretation of a fragment is based on the mime type of the primary resource. Tim Berners-Lee notes that determining fragment meaning from mime type is a problem because a single URI may contain a single fragment, however over HTTP a single URI can result in the same logical resource represented in different mime types. So there's one fragment but multiple mime types and so multiple interpretations of the one fragment. The URI RFC says that if an author has a single resource available in multiple mime types then the author must ensure that the various representations of a single resource must all resolve fragments to the same logical secondary resource. Depending on which mime types you're dealing with this is either not easy or not possible.

HTTP. In HTTP when URIs are used, the fragment is not included. The General Syntax section of the HTTP standard says it uses the definitions of 'URI-reference' (which includes the fragment), 'absoluteURI', and 'relativeURI' (which don't include the fragment) from the URI RFC. However, the 'URI-reference' term doesn't actually appear in the BNF for the protocol. Accordingly the headers like 'Request-URI', 'Content-Location', 'Location', and 'Referer' which include URIs are defined with 'absoluteURI' or 'relativeURI' and don't include the fragment. This is in keeping with the original fragment definition which says that the fragment is used as a view of the original resource and consequently only needed for resolution on the client. Additionally, the URI RFC explicitly notes that not including the fragment is a privacy feature such that page authors won't be able to stop clients from viewing whatever fragments the client chooses. This seems like an odd claim given that if the author wanted to selectively restrict access to portions of documents there are other options for them like breaking out the parts of a single resource to which the author wishes to restrict access into separate resources.

HTML. In HTML, the HTML mime type RFC defines HTML's fragment use which consists of fragments referring to elements with a corresponding 'id' attribute or one of a particular set of elements with a corresponding 'name' attribute. The HTML spec discusses fragment use additionally noting that the names and ids must be unique in the document and that they must consist of only US-ASCII characters. The ID and NAME attributes are further restricted in section 6 to only consist of alphanumerics, the hyphen, period, colon, and underscore. This is a subset of the characters allowed in the URI fragment so no encoding is discussed since technically its not needed. However, practically speaking, browsers like FireFox and Internet Explorer allow for names and ids containing characters outside of the defined set including characters that must be percent-encoded to appear in a URI fragment. The interpretation of percent-encoded characters in fragments for HTML documents is not consistent across browsers (or in some cases within the same browser) especially for the percent-encoded percent.

Text. Text/plain recently got a fragment definition that allows fragments to refer to particular lines or characters within a text document. The scheme no longer includes regular expressions, which disappointed me at first, but in retrospect is probably good idea for increasing the adoption of this fragment scheme and for avoiding the potential for ubiquitous DoS via regex. One of the authors also notes this on his blog. I look forward to the day when this scheme is widely implemented.

XML. XML has the XPointer framework to define its fragment structure as noted by the XML mime type definition. XPointer consists of a general scheme that contains subschemes that identify a subset of an XML document. Its too bad such a thing wasn't adopted for URI fragments in general to solve the problem of a single resource with multiple mime type representations. I wrote more about XPointer when I worked on hacking XPointer into IE.

SVG and MPEG. Through the Media Fragments Working Group I found a couple more fragment scheme definitions. SVG's fragment scheme is defined in the SVG documentation and looks similar to XML's. MPEG has one defined but I could only find it as an ISO document "Text of ISO/IEC FCD 21000-17 MPEG-12 FID" and not as an RFC which is a little disturbing.

AJAX. AJAX websites have used fragments as an escape hatch for two issues that I've seen. The first is getting a unique URL for versions of a page that are produced on the client by script. The fragment may be changed by script without forcing the page to reload. This goes outside the rules of the standards by using HTML fragments in a fashion not called out by the HTML spec. but it does seem to be inline with the spirit of the fragment in that it is a subview of the original resource and interpretted client side. The other hack-ier use of the fragment in AJAX is for cross domain communication. The basic idea is that different frames or windows may not communicate in normal fashions if they have different domains but they can view each other's URLs and accordingly can change their own fragments in order to send a message out to those who know where to look. IMO this is not inline with the spirit of the fragment but is rather a cool hack.

PermalinkCommentsxml text ajax technical url boring uri fragment rfc

Fragment Identification of MPEG Resources (Text of ISO/IEC FCD 21000-17 MPEG-21 FID)

2008 Apr 16, 7:09Standard describing URI fragments identifying parts of MPEG videos. Very similar syntax to XML fragments. Having trouble finding this document as anything other than a Word doc. Looks to exist only as an ISO standard.PermalinkCommentsstandard fragment uri video mpeg reference iso

dretblog: Fragment Identifiers for Plain Text Documents

2008 Apr 16, 6:58Eric Wilde talks about his text plain fragment RFC becoming a standard.PermalinkCommentsblog mime uri fragment text erik-wilde

RFC 5147 - URI Fragment Identifiers for the text/plain Media Type

2008 Apr 16, 6:42The URI fragment for text/plain is finally a Proposed Standard!PermalinkCommentsuri fragment mime web rfc standards
Older EntriesNewer Entries Creative Commons License Some rights reserved.