PSP
As of version 0.2, Pike ScriptRunner can be used to run Pike Server Pages (PSP) files. PSP is similar to JSP in that it allows you to mix code and content on the same page. The PSP markup format is:Expressions <%= someexpression %> gives you some expression cast as a string. <%= random(100) %> is a positive random number less than 100. <% somepikecode %> inserts some pike code fragments in page (aka scriptlet) <% for(int a = 99; a > 0; a--) { out+= (a + " bottles of beer on the wall.n<p>"); } %> <% if(id->variables->somevar) %> all this appears if somevar is present and non-zero. <% else %> all of this appears otherwise, until we hit another <% %> (ie this shows up regardless) block. <%! some pike code %> <%@ include file="" %> Powered by PikeWiki2 |
|||
gotpike.org | Copyright © 2004 - 2009 | Pike is a trademark of Department of Computer and Information Science, Linköping University |