Skip to content
Snippets Groups Projects
Unverified Commit 603f0fd9 authored by orestis.malaspin's avatar orestis.malaspin
Browse files

added course template and modified archive

parent be2bcf63
No related branches found
No related tags found
No related merge requests found
...@@ -78,7 +78,7 @@ main = hakyllWith config $ do ...@@ -78,7 +78,7 @@ main = hakyllWith config $ do
compile $ do compile $ do
posts <- recentFirst =<< loadAll ("cours/isc_physics/*.markdown" .&&. hasNoVersion) posts <- recentFirst =<< loadAll ("cours/isc_physics/*.markdown" .&&. hasNoVersion)
makeItem "" makeItem ""
>>= loadAndApplyTemplate "templates/archive.html" (courseCtx posts "Physique appliquée" "cours/isc_physics/cours.pdf") >>= loadAndApplyTemplate "templates/course.html" (courseCtx posts "Physique appliquée" "cours/isc_physics/cours.pdf")
>>= relativizeUrls >>= relativizeUrls
-- Math Tech Info posts -- Math Tech Info posts
...@@ -104,7 +104,7 @@ main = hakyllWith config $ do ...@@ -104,7 +104,7 @@ main = hakyllWith config $ do
compile $ do compile $ do
posts <- recentFirst =<< loadAll ("cours/math_tech_info/*.markdown" .&&. hasNoVersion) posts <- recentFirst =<< loadAll ("cours/math_tech_info/*.markdown" .&&. hasNoVersion)
makeItem "" makeItem ""
>>= loadAndApplyTemplate "templates/archive.html" (courseCtx posts "Mathématiques en technologie de l'information" "cours/math_tech_info/cours.pdf") >>= loadAndApplyTemplate "templates/course.html" (courseCtx posts "Mathématiques en technologie de l'information" "cours/math_tech_info/cours.pdf")
>>= relativizeUrls >>= relativizeUrls
-- Phys app posts -- Phys app posts
...@@ -167,7 +167,7 @@ main = hakyllWith config $ do ...@@ -167,7 +167,7 @@ main = hakyllWith config $ do
compile $ do compile $ do
posts <- recentFirst =<< loadAll "posts/bachelor/*.md" posts <- recentFirst =<< loadAll "posts/bachelor/*.md"
makeItem "" makeItem ""
>>= loadAndApplyTemplate "templates/archive.html" (pagesCtx posts "Bachelor projects") >>= loadAndApplyTemplate "templates/page.html" (pagesCtx posts "Bachelor projects")
>>= relativizeUrls >>= relativizeUrls
-- Render some static pages -- Render some static pages
......
...@@ -23,10 +23,6 @@ ...@@ -23,10 +23,6 @@
<div class="container"> <div class="container">
<h1>$title$</h1> <h1>$title$</h1>
$if(pdfurl)$
<h3><a href="$pdfurl$">Le polycopié en entier [pdf]</a></h3>
$endif$
<h2>Les chapitres</h2>
<ul> <ul>
$for(posts)$ $for(posts)$
<li> <li>
......
<!DOCTYPE HTML>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">
<title>$title$</title>
<link href="/css/bootstrap.css" rel="stylesheet">
<link href="/css/syntax.css" rel="stylesheet">
<link href="/css/carousel.css" rel="stylesheet">
<link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css'>
<style>
body {
font-family: 'Open Sans', sans-serif;
}
body { margin-top: 80px; }
footer { margin-top: 80px; }
</style>
</head>
<body>
$partial("templates/nav.html")$
<div class="container">
<h1>$title$</h1>
$if(pdfurl)$
<h3><a href="$pdfurl$">Le polycopié en entier [pdf]</a></h3>
$endif$
<h2>Les chapitres</h2>
<ul>
$for(posts)$
<li>
<a href="$url$">$title$</a> - $date$
</li>
$endfor$
</ul>
$partial("templates/footer.html")$
</div>
</div><!-- /.container -->
<script src="/js/jquery.js"></script>
<script src="/js/bootstrap.js"></script>
<script src="/js/holder.js"></script>
</body>
</html>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment