Paragraphs and html integration.
sgbotsford at gmail.com
Tue Jun 19 09:41:07 EDT 2012
As a work around, look at Template Toolkit 2.
Here's the template for my home page:
[% INCLUDE header.inc
Title = "Sherwood's Forests Home"
Desc = "Sherwood's Forests Tree Farm home page, and site overview"
ExtraMetaContent = "<meta name=\"verify-v1\"
[% INCLUDE sidenav.inc %]
[% FILTER markdown %]
Regular MD stuff goes here.
[% INSERT Copyright.inc %]
[% END %]
[% INCLUDE footer.inc %]
One of the features I like about TT2 is that you can do substitutions on
Writing header.inc wasn't easy, as it also reads in an external file and
processes it into the navigation menu. But I never modify it, so that's a
Creating a new page consists of:
* Making a copy of an existing page.
* Putting in new markdown stuff in the middle of the file
* If I do nothing else, it will show up in alphabetical order in the
directory it's in. E.g. /Home/Trees/Leaf_Trees/Poplars/Swedish_Aspen.tt2
will show up in the menu system as
Home -> Trees -> Leaf Trees -> Poplars -> Swedish Aspen
run my update program, which rebuilds the entire site, and reposts it.
(Got burned by one of these spam trojans, so the site gets rebuilt twice a
There is a file where I can overwrite the the order for how names appear in
Sherwood of Sherwood's Forests
Sherwood's Forests -- http://Sherwoods-Forests.com
50042 Range Rd 31
Warburg, Alberta T0C 2T0
On 19 June 2012 04:40, Boris Le Ninivin <boris.leninivin at gmail.com> wrote:
> On 06/19/2012 02:00 AM, Waylan Limberg wrote:
>> On Mon, Jun 18, 2012 at 7:31 PM, Boris Le Ninivin
>> <boris.leninivin at gmail.com> wrote:
>>> On 06/18/2012 09:27 PM, Michel Fortin wrote:
>>> Le 2012-06-18 à 6:26, Boris Le Ninivin a écrit :
>>> In the end, on the df website, it is said that "Markdown is smart enough
>>> to add extra (unwanted) |<p>| tags around HTML block-level tags.". So I
>>> don't know if it's an implementation problem (related to the PHP port,
>>> maybe?), or if it's a design problem, but as far as I know, Markdown is
>>> smart enough to not add unwanted<p> tags.
>>> That's only true for known HTML tags, and only the block-level ones.
>>> Does that mean that<html> and<!doctype> tags will be enclosed
>> Yes. More specifically, known block-level tags that would only ever
>> appear inside the<body> of a valid HTML4/XHTML1 document are
>> recognized by Markdown. So any new tags introduced by HTML5 would also
>> not be recognized - although some implementations may be starting to
>> add them.
> I guess there are valid reasons for that behavior, even if I don't see
> them already.
> Also remember that those tags must begin at the start of a line. No
>> indentation allowed - or they not recognized as block level tags. Yes,
>> this is documented - so most implementations follow it.
> Okay. That seems to match what I've seen in the code.
> If your adding<html> stuff to your documents, that is generally
>> handled after markdown is run on the body. For example, most
>> frameworks and template systems will use a template which generates
>> all the stuff outside the<body> and perhaps a header/footer inside
>> the body, and then use a template variable to insert the already
>> converted markdown into the document.
> Well, I really want to have the markdown document containing inclusion
> tags. So I'll try the method that Sir Fortin pointed out.
> Markdown does not generally
>> expect to have the already generated document run through it -
>> although I know some people have had success using it that way in
>> specific controlled environments.
> I guessed that, that's why I gave up with the idea of replacing any
> non-markup content before running the markdown process.
> Many thanks you for your help, I'll try to correct my code using your help
> and ideas, and I'll tell you if it works :)
> Markdown-Discuss mailing list
> Markdown-Discuss at six.pairlist.**net <Markdown-Discuss at six.pairlist.net>
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Markdown-Discuss