You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can find the specific commit that incorporates these details on my site at commit 5b00f74, but here it is broken down a little.
Step 1: Copy and paste
Copy the about.html file in themes/academic/layouts/partials/widgets/about.html into the folder /layouts/partials/widgets/. This is the HTML code that controls the About widget of your page.
Step 2: Add some HTML
Modify the About widget to include some code for the certificate option.
{{ with $person.education }}
<divclass="col-md-7"><h3>{{ i18n "education" | markdownify }}</h3><ulclass="ul-edu fa-ul">
{{ range .courses }}
<li><iclass="fa-li fas fa-graduation-cap"></i><divclass="description"><pclass="course">{{ .course }}{{ with .year }}, {{ . }}{{ end }}</p><pclass="institution">{{ .institution }}</p></div></li>
{{ end }}
</ul></div>
{{ end }}
You can see the original layout has .courses. We're going to tweak that part a little bit and add a new option .certificate
You can name the new option whatever you like as long as you're consistent when you refer to it later on
You get to pick the icon. In my case I picked the "certificate" icon from Fontawesome and specified it using fas fa-certificate which is code provided on the Fontawesome website. This is how it gets incorporated into the "after the modification" code chunk below:
{{ with $person.education }}
<divclass="col-md-7"><h3>{{ i18n "education" | markdownify }}</h3><ulclass="ul-edu fa-ul">
{{ range .courses }}
<li><!--https://github.com/catrincm/personal-website/blob/e06b3525f51a3dd2653578a29c9b5b253596ab1a/layouts/partials/widgets/about.html-->
{{ if .course }}
<iclass="fa-li fas fa-graduation-cap"></i><divclass="description"><pclass="course">{{ .course }}{{ with .year }}, {{ . }}{{ end }}</p><pclass="institution">{{ .institution | markdownify }}</p><!--https://github.com/gcushen/hugo-academic/issues/1094#issuecomment-622200594--></div>
{{ end }}
{{ if .certificate }}
<iclass="fa-li fas fa-certificate"></i><divclass="description"><pclass="course">{{ .certificate }}{{ with .year }}, {{ . }}{{ end }}</p><pclass="institution">{{ .institution | markdownify }}</p><!--https://github.com/gcushen/hugo-academic/pull/951#issue-255104712--></div>
{{ end }}
</li>
{{ end }}
</ul></div>
{{ end }}
Note I reference where I got these ideas within the code (in between the <!----> notation). That way I'll have a record I can go back to and credit folks for sharing their knowledge.
Step 3: Add your certificates
In the Education section of your _index.md file, you can use your newly created .certificate option to add your certificates. This is where you need to be consistent with whatever name you decided on in Step 2.
education:
courses:
- certificate: RStudio Tidyverse Instructor Certification
institution: RStudio
url_institution: ""
year: 2020 (expected)
- certificate: Certificate in Biomedical Informatics
institution: University of Pennsylvania
url_institution: ""
year: 2020
Hi there! π
I've received this question recently so I figured I would document an answer publicly.
π©βπ» If you'd like another example of how this is done I recommend Catrin Campbell-Moore's website which is where I borrowed the code from!
You can find the specific commit that incorporates these details on my site at commit 5b00f74, but here it is broken down a little.
Step 1: Copy and paste
Copy the
about.html
file inthemes/academic/layouts/partials/widgets/about.html
into the folder/layouts/partials/widgets/
. This is the HTML code that controls the About widget of your page.Step 2: Add some HTML
Modify the About widget to include some code for the certificate option.
Before the modification to the
{{ with $person.education }}
section:You can see the original layout has
.courses
. We're going to tweak that part a little bit and add a new option.certificate
using
fas fa-certificate
which is code provided on the Fontawesome website.This is how it gets incorporated into the "after the modification" code chunk below:
After the modification to the
{{ with $person.education }}
section:Step 3: Add your certificates
In the Education section of your
_index.md
file, you can use your newly created.certificate
option to add your certificates. This is where you need to be consistent with whatever name you decided on in Step 2.References
The text was updated successfully, but these errors were encountered: