{"id":20,"date":"2016-03-17T10:47:16","date_gmt":"2016-03-17T10:47:16","guid":{"rendered":"http:\/\/www.librarypi.com\/?page_id=20"},"modified":"2019-05-31T21:40:25","modified_gmt":"2019-05-31T21:40:25","slug":"lp-stage-1","status":"publish","type":"page","link":"https:\/\/www.librarypi.com\/index.php\/lp-stage-1\/","title":{"rendered":"LP Stage 1"},"content":{"rendered":"<p>After the initial setup of the services, we can install the PHP files to implement Stage 1 of the Library Pi.\u00a0 This stage will allow us to upload zip files with JPGs, store the files and information in a database, and then use the Internet Archive BookReader component to view books.<\/p>\n<p>Note that you can download a zip file of a Raspberry Pi disk image backup of Stage 1 here ( <em>NOTE: you will need to run <strong>sudo raspi-config<\/strong> to expand file space<\/em>)<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\"   src=\"https:\/\/www.librarypi.com\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/zip.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.librarypi.com\/index.php\/download\/library-pi-stage-1-image\/'>Library Pi Stage 1 Image<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 453 MB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.librarypi.com\/index.php\/download\/library-pi-stage-1-image\/?wpdmdl=84&refresh=69e18cc529eae1776389317\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n<p>Or, you can also just download the Zip file with the Stage 1 PHP files here (you still need to create the database, and setup lp_dbconf.php):<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\" src=\"https:\/\/www.librarypi.com\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/zip.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.librarypi.com\/index.php\/download\/php-files-for-stage-1\/'>PHP Files for stage 1<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 311.19 KB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.librarypi.com\/index.php\/download\/php-files-for-stage-1\/?wpdmdl=90&refresh=69e18cc52b2751776389317\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n<p>At the end of this page is a set of steps to test the new website.\u00a0 You can download a small sample book to use here:<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\" src=\"https:\/\/www.librarypi.com\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/zip.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.librarypi.com\/index.php\/download\/sample-book-the-jungle\/'>Sample Book: The Jungle<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 11.86 MB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.librarypi.com\/index.php\/download\/sample-book-the-jungle\/?wpdmdl=99&refresh=69e18cc52c2751776389317\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n<h3>Data Model<\/h3>\n<p>The first stage data model will be very simple, and just support book and page data using 2 tables.\u00a0 You must use the MySQL script below to create the database as well as the two tables and indices:<\/p>\n<pre>create database if not exists\u00a0 lp;\nuse lp;\n\ncreate table if not exists lp_book(\n\u00a0id integer\u00a0 NOT NULL AUTO_INCREMENT,\n\u00a0title varchar(128),\n\u00a0ukey varchar(32),\n\u00a0PRIMARY KEY PK_lp_bookz (id),\n\u00a0INDEX ilp_book (ukey)\n);\n\ncreate table if not exists lp_page(\n\u00a0id integer\u00a0 NOT NULL AUTO_INCREMENT,\n\u00a0book_id integer,\n\u00a0seq integer,\n\u00a0height integer,\n\u00a0width integer,\n\u00a0status char(1),\n\u00a0filename varchar(256),\n\u00a0PRIMARY KEY PK_lp_page (id),\n\u00a0INDEX ilp_page (book_id)\n);<\/pre>\n<p>Use MySQL Workbench or your MySQL client to execute the above against your MySQL database.<\/p>\n<p>The lp_book table stores a unique ID for our books, as well as a title and a ukey.\u00a0 The ukey field will hold a unique 32-character key for the book.\u00a0 The ukey value will be used in URLs to identify the book, so visitors can\u2019t just modify the URL and start stealing our book data.\u00a0 The lp_page table holds information about the pages for the book.\u00a0 One book will have one or more pages.\u00a0 The pages have a seq field so we can control their order later, as well as a status field that we will use for additional processing later.<\/p>\n<h3>BookReader<\/h3>\n<p>We are going to be using the Internet Archive BookReader for displaying the pages.\u00a0 You can find information and downloads on the book reader here: <a href=\"https:\/\/openlibrary.org\/dev\/docs\/bookreader\">https:\/\/openlibrary.org\/dev\/docs\/bookreader<\/a><\/p>\n<p>This open source reader should be setup in a bookreader sub folder of \/var\/www\/html, or where your website will be installed.\u00a0 The files in this folder should be as follows:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-87\" src=\"http:\/\/www.librarypi.com\/wp-content\/uploads\/2016\/03\/BookReader1.png\" alt=\"BookReader1\" width=\"210\" height=\"365\" \/><\/p>\n<p><span style=\"color: #000000; font-family: Calibri; font-size: medium;\">The PHP files below, specifically the reader.php file, will be using these files and expect them in this specific location.<\/span><\/p>\n<h3>PHP Files<\/h3>\n<p>These PHP files can be installed in the \/var\/www\/html folder of your Raspberry Pi.\u00a0 You should remove the index.html file that is there now.\u00a0 We are going to put most of our logic into a reusable \u2018LP\u2019 class, so you will find that most of the PHP files are pretty barren (except for lp.php where the LP class resides). Keep this mind as you review the PHP files: all the real work is done in lp.php.<\/p>\n<p>You can also just download the files:<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\" src=\"https:\/\/www.librarypi.com\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/zip.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.librarypi.com\/index.php\/download\/php-files-for-stage-1\/'>PHP Files for stage 1<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 311.19 KB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.librarypi.com\/index.php\/download\/php-files-for-stage-1\/?wpdmdl=90&refresh=69e18cc52cbc01776389317\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n<p>You can just download the PHP files for the website, but they are described here:<br \/>\n<strong>lp_dbconf.php<\/strong><br \/>\nThis file serves to centralize our database connection settings and code.\u00a0 It\u2019s not very robust now, but can be enhanced later for things like failures to connect to the database.\u00a0 All other modules we create will include this for simple access to our MySQL database.<\/p>\n<pre>&lt;?php\n $GLOBALS[ \"db_srvr\" ] = \"localhost\";\n $GLOBALS[ \"db_user\" ] = \"root\";\n $GLOBALS[ \"db_pass\" ] = \"(your MySQL password)\";\n $GLOBALS[ \"db_data\" ] = \"lp\";<\/pre>\n<pre>@ $GLOBALS[\"db\"] = mysqli_connect( $GLOBALS[ \"db_srvr\" ],\n      $GLOBALS[ \"db_user\" ], $GLOBALS[ \"db_pass\" ], \n      $GLOBALS[ \"db_data\" ] );\n\u00a0if( !$GLOBALS[\"db\"] )\n\u00a0\u00a0die( \"Database connection failed.\u00a0 Please check settings in \" . __FILE__ );<\/pre>\n<pre>function db()\n{\n    return $GLOBALS[\"db\"];\n}\n?&gt;<\/pre>\n<p><strong>index.php<\/strong><br \/>\nThis is the home page.\u00a0 It\u2019s going to display our menu and a list of books to be read.\u00a0 Of course, it doesn\u2019t really do much, except ask the LP class to do the real work:<\/p>\n<pre>&lt;?php\n include_once( 'lp.php' );\n $lp = new LP();\n $lp-&gt;HTMLPageTop();\n echo $lp-&gt;BookList();\n $lp-&gt;HTMLPageBottom();\n?&gt;<\/pre>\n<p><strong>upload.php<\/strong><br \/>\nUpload.php will offer the users a very simple upload form, and also accept their uploaded files.\u00a0 Again, lp.php does the real work.<\/p>\n<pre>&lt;?php\n include_once( 'lp.php' );<\/pre>\n<pre> $lp = new LP();\n $lp-&gt;HTMLPageTop();\n \/\/ If we find this field, the user posted data.\u00a0 Save it\n if( isset( $_POST[ \"ispost\" ] ) )\n {\n    if( $lp-&gt;AddBook( $_POST[ \"book_title\" ]) )\n       echo \"Uploaded\";\n    else\n       echo \"Error: \" . $lp-&gt;Err;\n }\n else\n { \/\/ If they didn\u2019t post data, display the input form\n ?&gt;\n &lt;form method=\"post\" action=\"upload.php\" enctype=\"multipart\/form-data\"&gt;\n &lt;input type=hidden name=ispost value=\\\"Y\\\"&gt;\n Book title: &lt;input type=text name=book_title&gt;&lt;br \/&gt;\n Zip file: &lt;input type=\"file\" name=\"zip_file\" id=\"zip_file\"&gt;&lt;br \/&gt;\n &lt;input type=\"submit\" value=\"Upload\" name=\"submit\"&gt;&lt;br \/&gt;\n &lt;\/form&gt;\n &lt;?php\n }<\/pre>\n<pre> $lp-&gt;HTMLPageBottom();\n ?&gt;<\/pre>\n<p>The key to what\u2019s going on above is that we are seeing if a POST variable exists.\u00a0 If it doesn\u2019t then we display an HTML form to the user so they can upload and name a book.\u00a0 If the post variable does exist, then we call the AddBook function in the lp class to actually add it to the system.<\/p>\n<p><strong>reader.php<\/strong><br \/>\nThis is the second most complicated file here.\u00a0 This is the reader page that will allow users to view the uploaded books using the Internet Archive BookReader.\u00a0 Most of the code here is for setting up the BookReader for use.\u00a0 We are also using a healer file, reader.js which contains most of the Javascript needed to implement BookReader.\u00a0 See the BookReader section for more information.<\/p>\n<pre>&lt;?php\n include_once( 'lp.php' );\n \/\/This section sets up the headers needed by BookReader\n   $Header =\n \"&lt;link rel=\\\"stylesheet\\\" type=\\\"text\/css\\\" href=\\\"bookreader\/BookReader.css\\\" \/&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/jquery-1.4.2.min.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/jquery-ui-1.8.5.custom.min.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/dragscrollable.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/jquery.colorbox-min.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/jquery.ui.ipad.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/jquery.bt.min.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"bookreader\/BookReader.js\\\"&gt;&lt;\/script&gt;\\n\" .\n \"&lt;script type=\\\"text\/javascript\\\" src=\\\"reader.js\\\"&gt;&lt;\/script&gt;\\n\";<\/pre>\n<pre>    $lp = new LP();\n    $BookKey = isset( $_GET['bk'] ) ? $_GET['bk'] : \"\";\n    $lp-&gt;LoadPages( $BookKey );\n    $lp-&gt;HTMLPageTop( \"Reader\", $Header);\n ?&gt;\n &lt;div id=\"BookReader\"&gt;\n BookReader &lt;br\/&gt;\n &lt;noscript&gt;\n &lt;p&gt;\n The BookReader requires JavaScript to be enabled.\n &lt;\/p&gt;\n &lt;\/noscript&gt;\n &lt;\/div&gt;\n &lt;?php\n   \/\/ This section sets up javascript needed by BookReader\n   $lp-&gt;HTMLPageBottom();\n   echo \"&lt;script&gt;\\n\".\n   \"\u00a0\u00a0var br = new BookReader();\\n\".\n   \"\u00a0\u00a0var CurPageIndex = 0;\\n\" .\n   \"\u00a0\u00a0var PgIDs = [$lp-&gt;PageIDs];\\n\".\n   \"\u00a0\u00a0br.pageWidths = [$lp-&gt;PageWidths];\\n\".\n   \"\u00a0\u00a0br.pageHeights = [$lp-&gt;PageHeights];\\n\".\n   \"\u00a0\u00a0br.BookKey = '$BookKey';\\n\" .\n   \"\u00a0\u00a0br.numLeafs = $lp-&gt;PageCount;\\n\".\n   \"\u00a0\u00a0br.bookTitle = \\\"Demo\\\";\\n\" .\n   \"\u00a0\u00a0br.bookUrl = \\\"Demo\\\";\\n\" .\n   \"\u00a0\u00a0br.logoURL = \\\"Demo\\\";\\n\" .\n   \"\u00a0\u00a0SetupBookReader( br );\\n\";\n ?&gt;\n br.init();\n \/\/ Disable items as needed\n $('#BRtoolbar').find('.read').hide();\n $('.info').hide();\n $('.thumb').hide();\n &lt;\/script&gt;<\/pre>\n<p>Basically, all we are doing in the above code is calling the LoadPages method of the LP class to load data, and then using it in the javascript near the end.<\/p>\n<p><strong>lp.php<\/strong><br \/>\nFinally, we get to the core of the Library Pi coding, lp.php.\u00a0 This php module will create the LP class that we have used in all the other PHP files and allows us to keep them simple and light modules.\u00a0 To keep this page simple, we are not listing the entire contents of this file, just describing the methods in it and some key points.\u00a0 Please see the download links to retrieve the lp.php class file.<\/p>\n<p>One of the first things to noe about lp.php is that it includes lp_dbconf.php in order to gain access to the database files.<\/p>\n<p>Functions in the LP class:<\/p>\n<p><span style=\"text-decoration: underline;\">function HTMLPageTop( $Title = &#8220;LibraryPi&#8221;, $Header=&#8221;&#8221;, $Script=&#8221;&#8221; )<\/span><br \/>\n<span style=\"text-decoration: underline;\">function HTMLPageBottom( $Script = &#8221; )<\/span><br \/>\nThese methods output consistent page tops and bottoms, including a menu on the top.\u00a0 It makes creating consistent pages easier and will help later with authentication.<\/p>\n<p><span style=\"text-decoration: underline;\">function UKey()<\/span><br \/>\nGenerates a unique 32-character key for each book<\/p>\n<p><span style=\"text-decoration: underline;\">function AddBook( $Title )<\/span><br \/>\nAccepts an uploaded ZIP file, and decompresses the JPG files into the uploads folder.\u00a0 It then adds each file into the lp_page table, as well as a book record into the lp_book table.<\/p>\n<p><span style=\"text-decoration: underline;\">function BookList()<\/span><br \/>\nReturns a list of records in the lp_book table in HTML format, with a link to the reader.php page to read that book.<\/p>\n<p><span style=\"text-decoration: underline;\">function LoadPages( $BookKey )<\/span><br \/>\nLoads the pages for a specific book, and provides access to things like how many pages, page dimensions and so on.\u00a0 This information is used by the reader.php file, to hand off data needed to the Internet Archive BookReader component in order to view books.<\/p>\n<p><span style=\"text-decoration: underline;\">function GetPageFilename( $BookKey, $PageID )<\/span><br \/>\nThis function is called to return a URL for a specific page in a book.\u00a0 The BookReader component will need this data to display pages.<\/p>\n<p><span style=\"text-decoration: underline;\">function OutputPageAndExit( $BookKey, $PageID )<\/span><br \/>\nThis method will open a page JPG file and output it.\u00a0 This is alao used by BookReader to display pages.<\/p>\n<p><strong>reader.js<\/strong><br \/>\nThe reader.js file is used by reader.php.\u00a0 It contains much of the code required to implement the BookReader component.\u00a0 Most of the code is described in the BookReader website, as well in the BookReader demo pages.\u00a0 The BookReader component needs to know the width and height for the pages it is going to display, as well as a URI that can be used to display the JPG file for the page.<br \/>\nIn our implementation, we are implementing JavaScript arrays to keep the ID, width, and height for all the pages.\u00a0 The specialized code that we are implementing in this file, that will use these arrays, are as follows:<\/p>\n<pre>br.getPageWidth = function (index) {\n return this.pageWidths[ index ];\n }<\/pre>\n<pre>br.getPageHeight = function (index) {\n return this.pageHeights[ index ];\n }<\/pre>\n<pre>br.getPageURI = function (index, reduce, rotate) {\n url = \"util.php?act=pj&amp;bk=\" + this.BookKey + \"&amp;pid=\" + PgIDs[ index ];\n return url;\n }<\/pre>\n<p>You can see now how the BookReader component knows to call out util.php module for displaying images, thanks to the getPageURI method above.<\/p>\n<h3><span style=\"color: #000000; font-family: Calibri; font-size: medium;\">Testing Stage 1<\/span><\/h3>\n<p>If you don&#8217;t have a sample book, download one here:<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\" src=\"https:\/\/www.librarypi.com\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/zip.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.librarypi.com\/index.php\/download\/sample-book-the-jungle\/'>Sample Book: The Jungle<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 11.86 MB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.librarypi.com\/index.php\/download\/sample-book-the-jungle\/?wpdmdl=99&refresh=69e18cc52d44b1776389317\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n<p>With our MySQL tables created, and all the PHP files in place (and proper lp_dbconf.php settings), we should be able to access the main page:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-93\" src=\"http:\/\/www.librarypi.com\/wp-content\/uploads\/2016\/03\/Stage1Test1.png\" alt=\"Stage1Test1\" width=\"415\" height=\"268\" \/><\/p>\n<p><span style=\"color: #000000; font-family: Calibri; font-size: medium;\">Click the Upload link, then enter The Jungle for the title, and use the TheJungle.zip demo file, then click Upload:<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-94\" src=\"http:\/\/www.librarypi.com\/wp-content\/uploads\/2016\/03\/Stage1Test2.png\" alt=\"Stage1Test2\" width=\"352\" height=\"250\" \/><\/p>\n<p>The page should then show \u2018Uploaded\u2019 (it may take some time to upload, be patient). Click the Home link to go back to the home page, and you should now see the book listed:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-95\" src=\"http:\/\/www.librarypi.com\/wp-content\/uploads\/2016\/03\/Stage1Test3.png\" alt=\"Stage1Test3\" width=\"382\" height=\"243\" \/><\/p>\n<p><span style=\"color: #000000; font-family: Calibri; font-size: medium;\">Clicking that link, should show the BookReader:<\/span><\/p>\n<p><a href=\"http:\/\/www.librarypi.com\/wp-content\/uploads\/2016\/03\/Stage1Test4.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-92\" src=\"http:\/\/www.librarypi.com\/wp-content\/uploads\/2016\/03\/Stage1Test4.png\" alt=\"Stage1Test4\" width=\"437\" height=\"307\" \/><\/a><\/p>\n<p>Proceed to <a href=\"http:\/\/www.librarypi.com\/index.php\/lp-stage-2\/\">Stage 2<\/a> to start adding the OCR and text searching abilities.<\/p>\n<div class='w3eden'><!-- WPDM Link Template: Default Template -->\n\n<div class=\"link-template-default card mb-2\">\n    <div class=\"card-body\">\n        <div class=\"media\">\n            <div class=\"mr-3 img-48\"><img decoding=\"async\" class=\"wpdm_icon\" alt=\"Icon\" src=\"https:\/\/www.librarypi.com\/wp-content\/plugins\/download-manager\/assets\/file-type-icons\/web.svg\" \/><\/div>\n            <div class=\"media-body\">\n                <h3 class=\"package-title\"><a href='https:\/\/www.librarypi.com\/index.php\/download\/library-pi-stage-1-imageb\/'>Library Pi Stage 1 ImageB<\/a><\/h3>\n                <div class=\"text-muted text-small\"><i class=\"fas fa-copy\"><\/i> 1 file(s) <i class=\"fas fa-hdd ml-3\"><\/i> 0.00 KB<\/div>\n            <\/div>\n            <div class=\"ml-3\">\n                <a class='wpdm-download-link download-on-click btn btn-primary ' rel='nofollow' href='#' data-downloadurl=\"https:\/\/www.librarypi.com\/index.php\/download\/library-pi-stage-1-imageb\/?wpdmdl=286&refresh=69e18cc52e4571776389317\">Download<\/a>\n            <\/div>\n        <\/div>\n    <\/div>\n<\/div>\n\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>After the initial setup of the services, we can install the PHP files to implement Stage 1 of the Library Pi.\u00a0 This stage will allow us to upload zip files with JPGs, store the files and information in a database,&#8230;<br \/><a class=\"read-more-button\" href=\"https:\/\/www.librarypi.com\/index.php\/lp-stage-1\/\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":2,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-20","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/pages\/20","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/comments?post=20"}],"version-history":[{"count":30,"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/pages\/20\/revisions"}],"predecessor-version":[{"id":289,"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/pages\/20\/revisions\/289"}],"wp:attachment":[{"href":"https:\/\/www.librarypi.com\/index.php\/wp-json\/wp\/v2\/media?parent=20"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}