Kategorie: Open Web

Hier geht es um Webdesign, Microformats, (X)HTML und CSS, Web2.0, usw.

  • bioformats

    Modern biological research is reliant on the data and tools made available on the web. However, even as the volume of biological data grows, and as new tools arrive to accommodate this growth, putting them to work is not straightforward. Cut and paste, screen scrapers and custom parsers are all common place. Microformats offer an alternative. 

    #

    Bioformats sind Mikroformate um biologische Daten abzubilden. Es gibt schon ein paar Working Drafts für Proteine, Gene und Abläufe, wobei bisher nur die hGenes ausformuliert wurden.

    Ein hGene könnte wie folgt aussehen:

    <div class='hgene'>
      <span class='name'>BRCA2</span>
      <p class='description'>
        Breast cancer type 2 susceptibility protein 
        (Fanconi anemia group D1 protein)	
      </p>
      <ul>
        <li>Genbank: <a href='genbank.pl?U43746' class='ident' rel='genbank'>U43746</a></li>
        <li>Entrez: <a href='entrez.pl?675' class='ident' rel='entrez'>675</a></li>
        <li>Location: <a href='lookup.pl?675' class='location' rel='homo_sapiens'>13:31787611-31871347</a></li>	  
      </ul>
    </div>Code-Sprache: HTML, XML (xml)

    Witzige Idee… vor allem das Logo!

    Mal schauen was neben Microformats, Nanoformats, Picoformats und jetzt auch Bioformats noch so alles entsteht.

  • Carnival ist ein Microformats Plugin für den Safari, er unterstützt bis jetzt zwar nur das hCard Format, aber es ist zumindest mal ein Anfang.

    Carnival: microformats for Safari

    Anwendung:

    • runterladen
    • ausführen
    • wenn eine Seite hCards enthält, leuchtet das Microformats Logo grün…

    Beim Beenden ist es ganz wichtig zuerst Carnival und dann Safari zu beenden, sonst öffnet sich Safari ständig wieder neu.

  • Die zwei Jungs von wevent haben mal wieder tolle Arbeit geleistet. Nach dem „Freundesnetzwerk-Import“ über das hCard Microformat haben sie das ganze in Windeseile auch noch für Events umgesetzt. Über „Events Importieren“ ist es möglich mit hCalendar ausgezeichnete Events in wevent zu importieren. Einen sehr schönen und ausführlichen Bericht über das neue Feature findet ihr auf Dennis‘ Weblog.

    Und damit ich mich etwas von der Thesis ablenken kann 😉 habe ich die ganzen Neuerungen natürlich sofort das wevent Operator Script angepasst. Die neue Version gibts unter hier.

    Übrigens will sich wevent umbenennen und zahlt 500 € für die beste Idee!

  • Seit dem 21. August steht die Finale Version (Version 0.8) des Firefox Operator Plugins bei addons.mozilla.org zum Download zur Verfügung.

    Features von Operator 0.8:

    • RDFa support (courtesy of Elias Torres)
    • eRDF support (courtesy of Keith Alexander)
    • New user interface elements, including an icon on the location bar as well as a sidebar
    • New preferences including auto-hiding the toolbar
    • The address microformats has been split out so that actions can be more granular
    • Actions can now be associated with multiple types of data, so the Google Maps action, for instance, works with Addresses and Locations
    • Much better support for frames and iframes
    • Support for non HTML documents
    • When debugging microformats, Operator connects to Brian Suda’s X2V behind the scenes so you can compare results
    • Lots of bug fixes

    Außerdem gibt es unter mozillalinks.org ein Interview mit dem Operator Entwickler Michael Kaply über die Microformats implementierung in Firefox 3.

  • Here are some code snippets to use the gorgeous X2V microformats XSLT files from Brian Suda with PHP 5 and libxslt (PHP 5 includes the XSL extension by default).

    hCard to vCard:

    To parse a XML or XHTML document, it has to be valid. To tidy the XML file, you can use a service from the W3C:

    $xml_string_tidy = file_get_contents("http://cgi.w3.org/cgi-bin/tidy?docAddr=".urlencode($uri));Code-Sprache: PHP (php)

    Then you have to create the HTML DOM…

    @$document = new DOMDocument();
    @$document->loadHTML($xml_string_tidy);Code-Sprache: PHP (php)

    and the XSLT DOM…

    $stylesheet = new DOMDocument();
    $stylesheet->load('hcard2vcard.xsl');Code-Sprache: PHP (php)

    Create a new XSLT Processor, load the Stylesheet…

    $processor = new XsltProcessor();
    $processor->importStylesheet($stylesheet);Code-Sprache: PHP (php)

    and run the transformation.

    $result = $processor->transformToDoc($document);
    $str = $result->saveXML();Code-Sprache: PHP (php)

    Now $str contains the transformed code.
    To send the vCard header with PHP, try

    header("Content-Disposition: attachment; filename=contact.vcf");
    header("Content-Type: text/x-vcard; charset=UTF-8 name=contact.vcf");
    echo $str;Code-Sprache: PHP (php)

    If you want to use the vCard extension .vcf instead of .php you have to add something like that to your .htaccess file

    RewriteEngine On
    RewriteBase /
    RewriteRule ^contact.vcf /hcard2vcard.php [L,QSA]

    I hope it works 🙂

  • Mein wevent Operator Script wurde in die wevent Tools aufgenommen 🙂

  • Google macht einen Microformats Rundumschlag, so hat es zumindest den Anschein 🙂

    Seit gestern steht ein kleiner Bericht über die Nutzung von hCard in Google Maps auf dem offiziellen Google Maps API Blog.

    hCard in Google Maps

    Außerdem wurden die Mikroformate hAtom und hCard in alle Blogger Standard-Templates eingebaut.

    hAtom und hCard bei Blogger

    Mal gespannt wann Amazon hReview einsetzt…

  • wevent logo

    So, das User-Script kann jetzt auch nach wevent (past und upcoming) Tags suchen. Für die Installationsanleitung einfach hier schauen.

    Download wevent.js

  • Auf dem gestrigen Webmontag in Karlsruhe kamen wir kurz auf das Thema „Microformats“ zu sprechen und Jochen Lillich meinte, dass die neue Version seines RSS-Readers einige Mikroformate erkennt.
    Das musste ich natürlich gleich ausprobieren, und in der Tat kann NetNewsWire, ab der Version 3.0, hCard und hCalendar interpretieren.

    NetNewsWire News

    Wenn bei NetNewsWire über den integrierten Browser eine Seite aufgerufen wird, die hCard oder hCal unterstützt, bekommt man diese über zwei nette Microformats Icons angezeigt…

    NetNewsWire Icons

    …und kann sie sich in iCal bzw. ins Adressbuch importieren.

    NetNewsWire Export

    Wobei ich persönlich ja eher dieses hCalendar Icon statt dieses hCalendar Icon Icon verwendet hätte 😉

    Screenshots:

  • Die Jungs von wevent haben ein neues Feature zum Importieren von Freundeslisten implementiert. Der Import funktioniert wie auch bei dopplr über das hCard Microformat. Das heißt, es ist möglich bestehende sozialen Netze (Twitter, Last.fm, …) über einen Klick an wevent zu übertragen.

    Und um das ganze noch mehr zu vereinfachen habe ich ein kleines Operator Script geschrieben welches die hCard URL an das Import Script übergibt.

    Installationsanleitung:

    1. Zuerst müsst ihr das Script (wevent.js) lokal speichern.
    2. Dann öffnet ihr die JavaScript Datei über Options->User Scripts->New
    3. Mit „OK“ bestätigen
    4. Firefox neu starten
    5. Fertig 🙂
    wevent operator user script

    Wenn Dennis und Sören das ganze auch noch für hCalendar umgesetzt haben gibt’s natürlich auch ein Update für das Script.