== Short installation overview ==
Check out the rdfhomepage package:
{{{
cd ~homer/public_html/whereever/
svn co https://rdfhomepage.opendfki.de/repos/rdfhomepage/trunk/rdfhomepage
}}}
The rdfhomepage package also contains a directory myrdfhomepage providing you with some initial files you can use to view, edit, and replace.
Copy or move the contents (not the folder!) of the myrdfhomepage/ directory to your public html space.
Before you start something else, you should call '''{{{install.sh}}}''' if you are installing rdfhomepage on a UNIX machine.
Then, you should edit the files (especially '''{{{config.php}}}''' and '''{{{homepage.rdf}}}'''), and then test and play around
a bit.
Well, and you MUST have several RDF files for rdfhomepage to work:
* a FOAF file specifying yourself and your "friends" and colleagues
* a bibtex files, that is, the text version PLUS the RDF version(!) of your publications
* an organizational model, that is, your organizational properties and relations (your projects, department(s), roles...)
----
=== FOAF / RDF ===
First of all: You MUST have a FOAF file for rdfhomepage to work! [[BR]]
But: Care has to be taken when creating a FOAF file.
There are a lot of tools out there for creation and management of your foaf file, however, (nearly) all of them produce a more or less crappy/ugly/bad/impractical RDF file. I am sorry, but I must advise to use a text editor for that concern. If you adapt the foaf RDFS to contain the right domain and range constraints, then Protege may also be useful, but a text editor together with disciplined(!) indentation is the best, fastest and easiest way. [[BR]]
The easiest way to come up with a good foaf file is to copy mine: http://www.dfki.uni-kl.de/~schwarz/foaf.xml open it in some text editor and edit everything ;)
For all RDF files to be used in rdfhomepage you have to follow the following rules (btw, you should follow these rules for all software using RDF). This holds especially for your FOAF file:
* Resources to be referenced from outside the RDF file need a URI => Your foaf:Person needs a URI.
* Blank/anonymous nodes can't be referenced from outside the RDF file. => Your foaf:Person needs a URI, no blank/anonymous node! So: don't use nodeID="...", but use rdf:about="...".
* Some (most!) RDF parsers do not like relative URIs (or NodeIDs). => It is generally better to use ABSOLUTE URIs. So: don't use rdf:about="#me" in your foaf file, better use something like rdf:about="http://www.dfki.uni-kl.de/~schwarz/foaf.xml#me".
* Generally, every thing described in an RDF file, that could be relevant and/or referenced outside the RDF file, should have an absolute URI. However, the foaf:Persons I link with foaf:knows do not have a URI, because so many people out there do not have a URI for their foaf:Person.
If you have a FOAF file and a foaf description of your foaf:Person, then the URI of that foaf:Person has to be set in your {{{config.php}}}:
{{{
// The location of your FOAF file on the web (This is also the data source)
$MY_FOAF_FILE_URL = "http://www.dfki.uni-kl.de/~schwarz/foaf.xml";
// Your URI in your FOAF file - Look this one up!
$MY_FOAF_URI = "http://www.dfki.uni-kl.de/~schwarz/foaf.xml#me";
}}}
----
=== BIBTEX ===
We used bibtex2rdf from L3S (Hannover) to convert a text bibtex file to some RDF representation.
Unfortunately the bibtex2rdf tool is NOT (YET?) open-source, and therefore the jar-file is not includes in the rdfhomepage package. But if you install rdfhomepage and drop me (Sven) an email, and you will get the jar-file.
Using the bibtex2jar tool, you can call the following to create/update your bibtex RDF file:
{{{
set BIBFILE=ss.bib
set URI=http://www.dfki.uni-kl.de/~schwarz/rdf/ss_bib.rdf#
set OUT=bib_ss.rdf
java -jar bibtex2rdf.jar -baseuri %URI% %BIBFILE% %OUT%
}}}
At the END of the bibtex-file there is a rdf:Seq like this
{{{
. . .
}}}
Take the URI of that rdf:Seq (here this is http://www.dfki.uni-kl.de/~schwarz/rdf/ss_bib.rdf#referenceList ) and paste that URI in your {{{config.php}}}:
{{{
// The name (not path) of your bibtex.rdf
define("BIBTEX_FILE_NAME", "bib_ss.rdf");
// The URL of your BibTeX file. (real BibTeX format, not RDF!)
$MY_BIB_TEX_URL = "http://www.dfki.uni-kl.de/~schwarz/ss.bib";
// The URI of a sequence of all the articles in your bibtex file
$MY_BIB_TEX_SEQ_URI = "http://www.dfki.uni-kl.de/~schwarz/rdf/ss_bib.rdf#referenceList";
}}}
----
=== OrgRep ===
The !OrgRep models our/your organizational structure, that is, your organizational properties and relations, your projects, project leaders, department, research groups, etc. Especially the relations between people and projects will be used for rdfhomepage.
You may have a look at our !OrgRep -> see {{{{rdfhomepage/vocabulary/OrgRepDFKI.*}}} -> best viewed with [http://protege.stanford.edu/ Protege], http://protege.stanford.edu/
There is also a better, nearly-empty Protege-Projekt + RDF + RDFS, which you could use to model your own organizational structure(s): {{{{rdfhomepage/vocabulary/OrgRep.*}}} [[BR]]
I advise you take the following steps:
1. Open {{{OrgRep.pprj}}} with Protege
2. Save it again (File/Save as), maybe use other filenames like {{{OrgRepACME.*}}} - the important thing here is: choose an OTHER default namespace -> last edit field in the "Save as" dialog (initially, the value will be http://rdfhomepage.opendfki.de/please_choose_another_namespace#).
3. Open it again (with Protege) and add your people, projects, etc. therein.
4. There are some inverse properties, which may need manual care, e.g. between org:Project <--> org:Person
I would suggest better URIs than the automatically generated ones by Protege, but as Protege does not provide a GUI component to edit the URI (or does it?), you would have to edit/replace the URIs later using a text editor or shell command or whatever.
Anyway, you've got to look up the URI of your org:Person and enter that in the {{{config.php}}}:
{{{
// Your URI in the OrgRep ontology
// If in doubt, look it up in the OrgRep RDF File or ask somebody!
$MY_ORGREP_URI = "http://km.dfki.de/model/org#OrganisationalModel_00077";
}}}
----
=== homepage.rdf ===
This RDF contains your personal, *homepage relevant*(!) information, that is, your Curriculum Vita, your personal interpretation of your job in your projects, etc.
The most important thing is - again - that your hp:Homepage resource has got a URI. We use the URL of the homepage without the trailing slash as the URI, but that is not obligatory, you can choose whatever URI you like as long as it is unique and differs from the other URIs you use!
Copy the URI of your hp:Homepage resource to the {{{config.php}}} file:
{{{
// The URI of the RDF node anchoring the homepage data
// as it can be found in the rdfhomepage.rdf file.
// You may commit to the default URI scheme, which is like
// http://www.dfki.uni-kl.de/~schwarz <-- note: no trailing slash!!!
// or change this value
$MY_HOMEPAGE_URI= "http://www.dfki.uni-kl.de/~schwarz";
}}}
Another important thing in the homepage.rdf is the information about the name that is used in your bibtex. Unfortunately this information should be better stored in config.php, but it is in homepage.rdf for several reasons... ;)
{{{
Sven Schwarz
}}}
Edit this to match the name (or abbreviation!) you use IN YOUR BIBTEX FILE. Currently, you have to decide on exactly ONE version! So: do not mix full names with abbreviations in your bibtex file!
==== short bio (homepage.rdf) ====
There could be a chunk containing short information about yourself:
{{{
My name is Bob. I am a researcher aiming at...
I like tennis and swimming...
]]>
}}}
==== projects (homepage.rdf) ====
Most probably, there will be one or more chunks about projects you work for:
{{{
This is one of two projects I work for.
I took talk hours about this project...
]]>
And this is the second of the two projects I work for.
]]>
}}}
We see several things here:
1. homepage.rdf contains your PERSONAL INTERPRETATION of the project. In contrast, the orgrep contains a SHARED description.
2. The projects's URIs should be exactly the same as in the orgrep file.
3. The project descriptions in homepage.rdf are ordered and chained like a linked list using a property hp:next. This list has to be normal, one-dimensional list, i.e.:
* there should be exactly one first project (no project is pointing at the first one with hp:next)
* there should be exactly one last project (this project has no hp:next project)
* every project inbetween (project 2 to project n-1) has exactly one hp:next project
==== interests (homepage.rdf) ====
There can be one or more chunks about your (research) interest.
As "interests" are quite manifold, each interest belongs to (exactly!) one "section".
I personally distinguish between "research contributions" and "research applications" (however, you do not have to do so as well):
{{{
My mayor research questions:
- research in ABC: ABC is my personal dream...
- DEF for GHI: In the next 2 months, ...
]]>
I'm also interested in
- JKL, and
- MNO
]]>
I'm heavily allying and relying of the following research areas:
- XXX: nobody can't without...
- XYY: also very important, because...
- XYZ: very interesting, but not yet really applicable...
]]>
}}}
We see several things here:
1. Like the projects, also the interests are linked/chained using the hp:next property with the same chaining constraints.
2. As already said, each interest MUST be assigned to exactly(!) one section. The section could be created in one interest chunk once and referenced in other interest chunks - see example RDF snippet above.
----
=== nice URLs via htaccess ===
This paragraph is about having "nice" URLs, i.e., we want to allow the following TWO possible versions to access rdfhomepage pages:[[BR]]
{{{old version:}}} http://www.dfki.uni-kl.de/~schwarz/index.php?page=projects [[BR]]
{{{new version:}}} http://www.dfki.uni-kl.de/~schwarz/projects
For this to work, you first have to copy or rename the {{{htaccess}}} to {{{.htaccess}}} in your myrdfhomepage directory (i.e., the directory where your config.php, homepage.rdf, etc. is in).
Then for each page you have in rdfhomepage, you have to
1. Edit the .htaccess file and add one mappings there. For each index.php?page=xxx, you will have an entry in .htaccess for xxx. Example for pages "projects" and "interests":
{{{
ForceType application/x-httpd-php
ForceType application/x-httpd-php
}}}
2. Create a symbolic link to index.php with the name of the page. Following the example with the "projects" page, you have to execute (unix/linux)
{{{
ln -s index.php projects
ln -s index.php interests
}}}
----
=== own CSS (style sheet) ===
You can customize the look and feel of your rdfhomepage as you like. There are at least three possibilities for your look and feel:
1. You can just take the predefined look and feel that comes with rdfhomepage.
For this, there is actually nothing to do.
2. You can have your own style sheet and use the predefined rdfhomepage style sheet and override some of the styles.
This would be done by creating a file {{{homepage.css}}} in your myrdfhomepage directory (the directory where your config.php resides).
In that CSS file you would include the homepage.css of the rdfhomepage package. Example:
{{{
@import url("rdfhomepage/homepage.css");
a {
background:red;
}
}}}
3. You can, of course have you very own style sheet without depending on predefined styles.
This would be done by creating a file {{{homepage.css}}} in your myrdfhomepage directory.
In that CSS file you will have to specify the style for every class (div) generated by the rdfhomepage scripts.
However, this alternative is in no way better than the 2nd alternative... [[BR]]
['''TODO:''' We shall provide a documentation about the used classes.]
The style sheet of rdfhomepage is divided into three style sheets. [[BR]]
homepage.css includes color_and_font.css and template.css.
* template.css defines the layout for the multi-column layout. [[BR]]
* color_and_font.css defines the colors and fonts to be used.
* homepage.css defines ordering and spacing of the s.
If you just like to override the coloring or some fonts, then you could create an own {{{homepage.css}}} in your myrdfhomepage directory containing
{{{
@import url("rdfhomepage/homepage.css");
@import url("color_and_font.css"); // <--- private color_and_font.css
a {
background:red;
}
}}}
Then you can also create an own {{{color_and_font.css}}} in that directory containing
{{{
@import url("rdfhomepage/color_and_font.css");
a.menuItem:hover {
font-weight:bold;
background: red;
text-decoration: none;
}
}}}
You see, that both CSS files include and override the predefined style sheet that comes with rdfhomepage.
Note, that for the examples above it is assumed, that the rdfhomepage package can be found directly inside your myrdfhomepage directory. If you put the rdfhomepage package to let's say {{{/home/share/rdfhomepage}}} to share the rdfhomepage core, then the import statements have to be modified in the code above, i.e., changed to
{{{
@import url("/home/share/rdfhomepage/homepage.css");
. . .
@import url("/home/share/rdfhomepage/color_and_font.css");
. . .
}}}