Zvanysse Week 3
From LMU BioDB 2017
Contents
Screenshots with Inspector Open
Screenshots without Inspector Open
Curling in an input
curl -d "pre_text=cgatggtacatggagtccagtagccgtagtgatgagatcgatgagctagc&submit=Submit" http://web.expasy.org/cgi-bin/translate/dna_aa
Question responses
- Yes, there are a few links that show up within the ExPASy translation server’s responses upon inspecting the page. The first is "ga.js." This is where all the javascript code is stored. Javascript code is the code that turns inputs into outputs. There are a few .css files: "sib_print.css," "base.css," and "sib.css." This is what makes the webpage look pretty. These files are joined together in the HTML code, or "/translate" page.
- "/cgi-bin/translate/dna_aa" presents as an identifier for an action. "pre_text" is an identifier for the textarea name. I would also argue that "POST" would be an identifier for a method in the form.
Extracting Answers via Command Line
curl -d "pre_text=cgatggtacatggagtccagtagccgtagtgatgagatcgatgagctagc&submit=Submit" http://web.expasy.org/cgi-bin/translate/dna_aa | sed "1,47d" | sed "14,44d" | sed 's/<[^>]*>//g' | sed "2s/[A-Z]/& /g" | sed "4s/[A-Z]/& /g" | sed "6s/[A-Z]/& /g" | sed "8s/[A-Z]/& /g" | sed "10s/[A-Z]/& /g" | sed "12s/[A-Z]/& /g" | sed "s/M/Met/g"| sed "s/-/Stop /g"
Notebook
With the curl function, "curl -d" is used to capture the data of the website. "pre_text=" is used because that is where the input data goes into. "&submit=Submit" was a command that I found while I was looking on a website. When going about extracting the data, I first deleted out the section before and after the desired data I wanted. Then, I deleted everything in between the "< >" brackets. Then, I went and spaced out the uppercase letters and substituted "-" for "Stop" and "M" with "Met."
Acknowledgements
- Consulted with Blair on usage of the curl function
- Consulted with my homework partner, [Etyrnauer| Emma], on the 2nd curl question
- Used the LMU Website to hack
- Used Coachella Lineup Website to hack
While I worked with the people noted above, this individual journal entry was completed by me and not copied from another source.
References
- LMU BioDB 2017. (2017). Week 3. Retrieved September 14, 2017, from https://xmlpipedb.cs.lmu.edu/biodb/fall2017/index.php/Week_3
- Manual -- curl usage explained. Retrieved September 17, 2017, from https://curl.haxx.se/docs/manual.html