Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2011-12-20 18:42:30

rivworks
New Member
Registered: 2011-12-20
Posts: 1

How can I safely post code in an article?

Looking to post articles about visual basic code. What is the safest way to post actual code samples that shows the code retaining its original formatting (indents etc.) and not to have the browser try to act on any parts of the code?

Offline

#2 2011-12-20 19:38:58

merz1
Member
From: Hamburg
Registered: 2006-05-04
Posts: 994
Website

Re: How can I safely post code in an article?

With textile you can use

@your code snippet goes here@

Example: Hello rivworks your code snippet goes here and the sentence continues.

Or bc. code ... (one dot) for a block of code.
Or bc.. code ... (two dots) for multiple paragraphs of code.

A p. or other explicit textile will end the multiple code paragraphs.

Check textile 2.2 out here: textile.sitemonks.com


Get all online mentions of Textpattern via OPML subscription: TXP Info Sources: Textpattern RSS feeds as dynamic OPML

Offline

Board footer

Powered by FluxBB