Final Project

 

<< Back

You been asked to generate various baseball statistics for a popular pub, but with a twist. You will need to use BaseX  to do initial queries of  the XML data, and then you will proceed to code your project using XSL and CSS. Follow the instructions below to complete the project. To start the project, you will need to download this .jpg file, and the 1998 baseball season roster of players baseball_names.xml

Your completed final project should look like this.

 

Part 1 XQuery (5 points)

  • Create an XQuery file using BaseX.
    • Find the top three boy baby names for 1969.
    • Using a FLWOR expression, search and retrieve those names in baseball_names.xml file. You will need to search for their names and nick names, for example, "Robert" "Bob".
    • For help, you will need to refer to our in-class examples and exercise from Unit 11. Here's a hint for the if statement
    • Print out each player, including all of his statistics, and ensure the result is enclosed in a root tag, <BASEBALL_NAMES></BASEBALL_NAMES>. Save your newly created .xq file to your project folder.
    • Save the newly created .xml file created in BaseX, and call it "baseball_names_new.xml"
  •  

    Part 2 XSLT (5 points)

  • Create an .xsl file.
  • Link up your .xsl file with your newly created .xml file, which should look like this: "baseball_names_new.xml".
  • Using code hints from HW5 part 2, use XSLT find out who had the highest number of RBIs (Runs Batted In) and display it to screen.
  • Display the photo as well, there's only one: Mike Piazza.

 

Part 3 CSS (5 points)

  • Link your .css file from your .xsl file, per HW5
  • Create selectors for img and strong:

Once completed, you must individually send me one zip file that includes your ( .jpg, .css, .xsl, .xml, and .xq) files and email them to me.

The assignment is due Friday, May 10th.

 

**This is a group assignment, so you are free to work together on this!**

 

 

<< Back