Browse Source

explain how to embed Bibtexbrowser into a website

pull/48/head
Martin Monperrus 10 years ago
parent
commit
d2929c37c4
  1. 27
      bibtexbrowser-documentation.wiki

27
bibtexbrowser-documentation.wiki

@ -83,6 +83,33 @@ Create a bib file with the publication records (e.g. csgroup2008.bib) and upload
=====FAQ=====
====How to embed Bibtexbrowser into a website?====
To embed Bibtexbrowser into a website, you need to use it as a library:
<pre>
&lt;?php
$_GET['library']=1;
require_once('bibtexbrowser.php');
global $db;
$db = new BibDataBase();
$db->load('biblio.bib');
?>
</pre>
Then, you have to call bibtexbrowser on you own:
<pre>
&lt;?php
// printing all 2014 entries
$query = array('year'=>'2014');
$entries=$db->multisearch($query);
uasort($entries, 'compare_bib_entries');
foreach ($entries as $bibentry) {
echo $bibentry->toHTML();
}
?>
</pre>
====How to embed a publication list in an home page?====
<table border="1">

Loading…
Cancel
Save