Coder Social home page Coder Social logo

pvnt's Introduction

PVNT

Introduction

PVNT is a simple, open source template utility written in Java.

  • Version: 0.92 (beta)
  • Author: pvnhome

Features

In very simple case we need one template file and several HTML-files that use this template (for example A.html and B.html).

Template file (in templates subdirectory):

<!DOCTYPE html>
<html lang="ru">
<!--pvnTmplBeg-->
<head>
   <meta charset="utf-8">
   <!--pvnEditBeg title-->
   <title>PageTemplate</title>
   <!--pvnEditEnd title-->
</head>
<body>
   <h1>Site1 (A,B)</h1>
   <h2>Part1</h2>
   <!--pvnEditBeg part1-->
   <p>Palceholder for Part1</p>
   <!--pvnEditEnd part1-->
   <h2>Part2</h2>
   <!--pvnEditBeg part2-->
   <p>Palceholder for Part2</p>
   <!--pvnEditEnd part2-->
</body>
<!--pvnTmplEnd-->
</html>

HTML-file A.html:

<!DOCTYPE html>
<html lang="ru">
<!--pvnTmplBeg templates/template.html-->
<head>
   <meta charset="utf-8">
   <!--pvnImplBeg title-->
   <title>PageA</title>
   <!--pvnImplEnd title-->
</head>
<body>
   <h1>Site1 (A,B)</h1>
   <h2>Part1</h2>
   <!--pvnImplBeg part1-->
   <p>Content for Part1 on PageA.</p>
   <!--pvnImplEnd part1-->
   <h2>Part2</h2>
   <!--pvnImplBeg part2-->
   <p>Content for Part2 on PageA.</p>
   <!--pvnImplEnd part2-->
</body>
<!--pvnTmplEnd-->
</html>

HTML-file B.html:

<!DOCTYPE html>
<html lang="ru">
<!--pvnTmplBeg templates/template.html-->
<head>
   <meta charset="utf-8">
   <!--pvnImplBeg title-->
   <title>PageB</title>
   <!--pvnImplEnd title-->
</head>
<body>
   <h1>Site1 (A,B)</h1>
   <h2>Part1</h2>
   <!--pvnImplBeg part1-->
   <p>Content for Part1 on PageB.</p>
   <!--pvnImplEnd part1-->
   <h2>Part2</h2>
   <!--pvnImplBeg part2-->
   <p>Content for Part2 on PageB.</p>
   <!--pvnImplEnd part2-->
</body>
<!--pvnTmplEnd-->
</html>

We can use only three types of tags:

  • pvnTmpl - used to define template file.
  • pvnEdit - used to define editable region in template file.
  • pvnImpl - used to override editable region.

Installation

Installation as simple as 1-2-3:

  • Download pvnt-x.xx.zip and extract it into the directory of your choice.
  • Add the [PVNT]/bin directory to your PATH environment variable.
  • Change [PVNT]/examples/site/templates/template.html file.
  • Execute pvnt command in [PVNT]/examples/site directory.
  • Look at A.html and B.html files for changes.

Website

pvnt's People

Contributors

pvnhome avatar

Stargazers

Anatoliy Chesnokov avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.