Personal homepage with ETH Layout
One possible way to have a personal homepage at the Department of Mathematics with a corporate design is described below.
Configuration
Open a terminal (for OS X: Menu > Finder > Go > Utilities > Terminal) on a computer of D-MATH or on your private computer connected with VPN and login for instance on ion-4
i.e.:
ssh ion-4
and execute following command:
create-personal-homepage
Now you should have following files in you www
-folder:
-rw-r--r--. 1 username others 1247 Sep 14 14:48 about.md
-rw-r--r--. 1 username others 20047 Sep 14 14:48 avatar.png
-rw-r--r--. 1 username others 381 Sep 14 14:50 config.inc.php
-rw-r--r--. 1 username others 717 Sep 14 14:48 contact.md
-rw-r--r--. 1 username others 460 Sep 14 14:48 cv.md
-rw-r--r--. 1 username others 861 Sep 14 14:48 publications.md
-rw-r--r--. 1 username others 647 Sep 14 14:48 research.md
-rw-r--r--. 1 username others 298 Sep 14 14:48 teaching.md
Modify the file config.inc.php
according to your needs; change at least the variable $fullname
and the image file avatar.png
with a picture of you (the best format is a square).
Notes:
- If you want to extend the navigation, just add a new line in
config.inc.php
like this one and create a file with the extension.md
: (in this casetest1.md
)
['title' => 'My Test 1', 'url' => 'test1'],
- If you want to add a sub-navigation, for instance to the new navigation explained here above, add this to the
config.inc.php
:
['title' => 'My Test 1', 'url' => 'test1', sub => [ ['title' => 'Sub Menu 1', 'url' => 'test1.1'], ['title' => 'Sub Menu 2', 'url' => 'test1.2'], ['title' => 'Sub Menu 3', 'url' => 'test1.3'] ]],
Editing your pages
Each page of your website corresponds to file ending with .md
. The files are located in you www
-folder on the server that you can easily access. Here you find how to access your files on the server. The ending .md
is the abbreviation for MarkDown which is a lightweight markup language with plain text formatting syntax. No need to learn HTML! Just edit a .md
-sample-files according to the syntax and save it.
If you don’t need a particular page, just remove the corresponding .md
-file. If you need a new page just create a new .md
-file (or copy an existing on) and edit it.
Note that a file named for instance PAGE.md will be available online unter the URL https://people.math.ethz.ch/~USERNAME/PAGE
MarkDown Editors
- MacDown (macOS)
- Apostrophe (Linux) – already installed on our devices
See also
- MarkDown official website at daringfireball.net
- MarkDown basic writing and formatting syntax at github.com
- MarkDown demo parser at parsedown.org
Posted on
in Web