Lesson 10: Read The Data File

This example uses the [[READ_FILE]] shortcode to load the data into a variable for printing to the screen.

Create a node and paste one of the following code samples into it’s landing page editor.  Goto the node’s address and test with browser.

[[READ_FILE:comments.txt|content]]
[[PRINT:content]]

or

[[INITIALIZE:filename|"comments.txt"]]
[[READ_FILE:$filename|content]]
[[PRINT:content]]

Leave a Reply