testing markdown
tables
Tables can be created by drawing them in the input using the below syntax: Example:
Name | Age |
---|---|
Bob | 27 |
Alice | 23 |
example fenced code
To insert code: you can use 3 or more backticks to mark the beginning of the block, and the same number to mark the end of the block. Output looks like:
# Heading Level 1
Some test
## Heading Level 2
Some more test
strikethrough
hen enabled, text wrapped with two tildes will be crossed out.
Example: crossed-out
link text highlight
code highlight shortcode
See config.toml for default syntax highlighter that is being used.
Using emacs as the style sheet but here code highlighted is python.
6#!/usr/bin/python3
7
8from engine import RunForrestRun
9
10"""Test code for syntax highlighting!"""
11
12class Foo:
13
14 def __init__(self, var):
15 self.var = var
16 self.run()
17
18 def run(self):
19 RunForrestRun() # run along!
another markdown example highlighting ‘C’
/**
* Dynamic shared object example.
*
* The function interfaces that are required for a dynamically registered shared
* object have the ability to have transport connectivity from the IXMDD layer.
*
* This example consumes CME messages from the IXMDD service. Here we are mixing
* both C and C++ to show flexibiliy in the callback interface.
*/
#include <iostream>
#include <fstream>
#include <string>
#include <cstring>
#include <sstream> // ostringstream
#include <iomanip> /* setw */
extern "C" {
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <sys/time.h>
#include <ixmdd.h>
#include <cme_messages.h>
}
#define timeval_to_float(tv_p) \
((double)(tv_p)->tv_sec + ((double)(tv_p)->tv_usec) / 1000000L)
#define timeval_sub(xtv, ytv, ztv) do { \
(ztv)->tv_sec = (xtv)->tv_sec - (ytv)->tv_sec; \
(ztv)->tv_usec = (xtv)->tv_usec - (ytv)->tv_usec; \
if ((ztv)->tv_usec < 0) { \
(ztv)->tv_sec--; \
(ztv)->tv_usec += 1000000L; \
} \
} while (0)
std::string out_fs = ": ";
std::string out_us = "\n";
int padding = 20;
void cme_dump_packet_type (int packet_type) {
footnotes
Pandoc-style footnotes will be supported. The footnote marker in the text that will become a superscript text; the footnote definition will be placed in a list of footnotes at the end of the document.
Example: This is a footnote.1
including an image
Pencil sketch of Narinder
- here the image link text not displayed
inserting an alert at note level
This is an alert note that sends you home.
inserting an alert at warning level
This is an alert warning that sends you home.
some bullets
These are bullets.
- hello 1
- world 2
- goodbye
- hello again
Adding links to pdf file
{{% staticref “files/cv.pdf” %}}Download my CV{{% /staticref %}}
Adding images to a post
If you want to include an image the recommended method is to:
- Add the image to your
/static/img/
folder, then - Reference the image using the relative file path as follows:
![my-image](/img/my-image.png)
Changing look & feel - Custom CSS
The default theme settings like colors and fonts can be controlled via the config.toml
file entry:
# Link custom CSS and JS assets
# (relative to /static/css and /static/js respectively)
custom_css = ["blue.css"]
Forms - Formspree
By default using Formspree to make a contact form, which is an online service (managed on GitHub) that allows you to add an HTML form to your static site. No registration, just use the form and confirm your email address once. Add the following code into my contact widget:
<form action="https://formspree.io/your@email.com" method="POST">
<label for="name">Your name: </label>
<input type="text" name="name" required="required" placeholder="here"><br>
<label for="email">Your email: </label>
<input type="email" name="_replyto" required="required" placeholder="here"><br>
<label for="message">Your message:</label><br>
<textarea rows="4" name="message" id="message" required="required" class="form-control" placeholder="I can't wait to read this!"></textarea>
<input type="hidden" name="_next" value="/html/thanks.html" />
<input type="submit" value="Send" name="submit" class="btn btn-primary btn-outline">
<input type="hidden" name="_subject" value="Website message" />
<input type="text" name="_gotcha" style="display:none" />
</form>
- the footnote text. ^