Coding and Structure

For the Rick and Morty project, we used several coding languages in building the website, marking up text, and structuring the data.

XML

Short for eXtensible Markup Language. It's used for storing and accessing information, providing an excellent method for marking up our documents. It's also cross-platform and used freely around the world.

    <?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="../../ODD/out/RickandMortyODD.rng" type="application/xml" schematypens="http://relaxng.org/ns/structure/1.0"?>
<?xml-model href="../../ODD/out/RickandMortyODD.rng" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron"?>
<TEI xmlns="http://www.tei-c.org/ns/1.0">
    <teiHeader>
        <fileDesc>
            <titleStmt>
                <title>Rick Potion #9</title>
                <author>Justin Roiland</author>
                <editor>A. Hall</editor>
            </titleStmt>
            <publicationStmt>
                <p>Digital edition hosted on <ref target="http://rickandmorty.newtfire.org"
                    >http://rickandmorty.newtfire.org</ref> and GitHub: <ref
                        target="https://github.com/dorothealint/Rick-and-Morty"
                        >https://github.com/dorothealint/Rick-and-Morty</ref></p>
            </publicationStmt>
            <sourceDesc>
                <bibl>
                    <title>Rick Potion #9</title>
                    <date when="2015-09-07"/>
                </bibl>
            </sourceDesc>
        </fileDesc>
        <encodingDesc>
            <p>Some small changes to the original transcriptions were made including fixed spelling errors and getting rid 
            of parentheses, brackes, and colons.</p>
        </encodingDesc>
    </teiHeader>
    <text>
        <body>
            <stage>Open ext. Harry Herpson High School</stage>
            <stage>Trans. int. Harry Herpson High School hallway</stage>
            <stage>Morty is standing at his locker.</stage>
            <sp><speaker>Principal Vagina</speaker><p> <stage>over the intercom, while the 
            students talk</stage> Principal Vagina here, don't let the name fool you, I'm very much in charge, 
            reminding you that tonight is our annual flu season dance. I don't know how many times I have to say this but 
            if you have the flu, stay home, the flu season dance is about awareness, not celebration. You don't bring dead 
            babies to Passover.</p></sp>
            <stage>Morty watches Jessica with her friends at a nearby locker</stage>
            <sp><speaker>Jessica's friend</speaker><p> <stage>to Jessica</stage> 
            Hey.</p></sp>
            <sp><speaker>Morty</speaker><p> Ohhh. Okay, here we go. <stage>walks over to 
            Jessica and her friends</stage> <stage>Nervously</stage> H-Heyy Jessica, 
            ughh.</p></sp>
            <sp><speaker>Jessica</speaker><p> What's up Morty? <stage>sneezes</stage>
            </p></sp>
            <sp><speaker>Morty</speaker><p> Ugghh</p></sp>
            <sp><speaker>Brad</speaker><p> <stage>butts in</stage> What are you 
            doing?</p></sp>
            <sp><speaker>Morty</speaker><p> Ummm</p></sp>
            

RelaxNG

An acronym for REgular LAnguage description for XML Next Generation. RelaxNG is used for creating template rules to write XML in, allowing us to code multiple documents without human error. Here is our schema for this project:

datatypes xsd = "http://www.w3.org/2001/XMLSchema-datatypes"

start = script
script = element script {title, description, body}
title = element title {text}
description = element description {season, episode, airdate*}
season = element season {text, xsd:integer}
episode = element episode {text, xsd:integer}
airdate = element airdate {xsd:date}
body = element body {speech, direction}
speech = element speech {designation, character?, guestStar?, text, burp*, catchPhrase*}
designation = attribute designation {"main" | "extra"}
character = attribute character {"rick" | "morty" | "summer" | "beth" | "jerry" | "other"}
guestStar = attribute guestStar {text}
burp = element burp {text}
catchphrase = element catchPhrase {text}
                    

HTML

Short for HyperText Markup Language. HTML and XML are similar languages, but HTML is used for presentation and display while XML is used for the storage of information. We used HTML in conjunction with CSS to build and style our website.

CSS

Short for Cascading Stylesheets. CSS is used to style code and display it on websites.

JS

Short for JavaScript. JS was used to create our menu bar, making it dynamic and more functional than a menu might be without using a language other than HTML.



Created by: A. Hall and D. Lint. GitHub. Creative Commons License Powered by firebellies.