<?php if (1 == 1 || empty($_POST['page'])) { //disable for now ?> <ul id="deposits-stream" class="deposits-list item-list"> <?php } ?> <?php while (humcore_deposits()) { humcore_the_deposit(); ?> <?php locate_template(array('deposits/entry.php'), true, false); ?> <?php } ?> <?php if (1 == 2 && humcore_deposit_has_more_items()) { ?> <li class="load-more">
/** * Format the page head meta fields. */ function humcore_deposit_item_search_meta() { while (humcore_deposits()) { humcore_the_deposit(); } // Should fetch one record. $metadata = (array) humcore_get_current_deposit(); printf('<meta name="description" content="%1$s">' . "\n\r", htmlentities($metadata['abstract'])); printf('<meta name="citation_title" content="%1$s">' . "\n\r", htmlentities($metadata['title'])); printf('<meta name="citation_publication_date" content="%1$s">' . "\n\r", htmlentities($metadata['date'])); // Format date yyyy/mm/dd. if (!empty($metadata['publisher'])) { printf('<meta name="citation_publisher" content="%1$s">' . "\n\r", htmlentities($metadata['publisher'])); } foreach ($metadata['authors'] as $author) { printf('<meta name="citation_author" content="%1$s">' . "\n\r", htmlentities($author)); } if (!empty($metadata['genre']) && in_array($metadata['genre'], array('Dissertation', 'Technical Report', 'Thesis')) && !empty($metadata['institution'][0])) { printf('<meta name="citation_dissertation_institution" content="%1$s">' . "\n\r", htmlentities($metadata['institution'][0])); } if (!empty($metadata['genre']) && 'Technical report' == $metadata['genre'] && !empty($metadata['institution'])) { printf('<meta name="citation_technical_report_institution" content="%1$s">' . "\n\r", htmlentities($metadata['institution'])); } if (!empty($metadata['genre']) && ('Conference paper' == $metadata['genre'] || 'Conference proceeding' == $metadata['genre']) && !empty($metadata['conference_title'])) { printf('<meta name="citation_conference_title" content="%1$s">' . "\n\r", htmlentities($metadata['conference_title'])); } if (!empty($metadata['book_journal_title'])) { printf('<meta name="citation_journal_title" content="%1$s">' . "\n\r", htmlentities($metadata['book_journal_title'])); } if (!empty($metadata['volume'])) { printf('<meta name="citation_volume" content="%1$s">' . "\n\r", htmlentities($metadata['volume'])); } if (!empty($metadata['issue'])) { printf('<meta name="citation_issue" content="%1$s">' . "\n\r", htmlentities($metadata['issue'])); } if (!empty($metadata['start_page'])) { printf('<meta name="citation_firstpage" content="%1$s">' . "\n\r", htmlentities($metadata['start_page'])); } if (!empty($metadata['end_page'])) { printf('<meta name="citation_lastpage" content="%1$s">' . "\n\r", htmlentities($metadata['end_page'])); } if (!empty($metadata['doi'])) { printf('<meta name="citation_doi" content="%1$s">' . "\n\r", htmlentities($metadata['doi'])); } if (!empty($metadata['handle'])) { printf('<meta name="citation_handle_id" content="%1$s">' . "\n\r", htmlentities($metadata['handle'])); } if (!empty($metadata['issn'])) { printf('<meta name="citation_issn" content="%1$s">' . "\n\r", htmlentities($metadata['issn'])); } if (!empty($metadata['chapter'])) { printf('<meta name="citation_chapter" content="%1$s">' . "\n\r", htmlentities($metadata['chapter'])); } if (!empty($metadata['isbn'])) { printf('<meta name="citation_isbn" content="%1$s">' . "\n\r", htmlentities($metadata['isbn'])); } if (!empty($metadata['subject'])) { $full_subject_list = $metadata['subject']; foreach ($full_subject_list as $subject) { printf('<meta name="citation_keywords" content="%1$s">' . "\n\r", htmlentities($subject)); } } printf('<meta name="citation_abstract_html_url" content="%1$s/deposits/item/%2$s/">' . "\n\r", bp_get_root_domain(), htmlentities($metadata['pid'])); $post_metadata = json_decode(get_post_meta($metadata['record_identifier'], '_deposit_file_metadata', true), true); printf('<meta name="citation_pdf_url" content="%1$s/deposits/download/%2$s/%3$s/%4$s/">' . "\n\r", bp_get_root_domain(), htmlentities($post_metadata['files'][0]['pid']), htmlentities($post_metadata['files'][0]['datastream_id']), htmlentities($post_metadata['files'][0]['filename'])); }