SR2 SupportCenterCaps

Contact Support
 

Email:
support@refreshsoftware.com

Phone:
508-318-4480


  Link to this page

Home >  Publishing Examples >  Hypertext Preprocessor (PHP)

Hypertext Preprocessor (PHP)

PHP is a popular general-purpose scripting language that is especially suited for Web development and can be embedded into HTML.


Download the SR2 PHP Publishing Kit.




The following are examples of SiteRefresh code in PHP:

Header/Includes:
SiteRefresh includes several valuable PHP functions which can easy be included into any SiteRefresh template by using the standard PHP include statement. These functions make it easy to include SiteRefesh content.

<?
require("globals.php");
require(
"siteRefresh.php");
?>

Echo Page Contents
You can easily display the contents of a page by using the getPageContent function.

<?
$thispage
=getPageContent( "", getPageName(), $g_versionnum );
echo
$thispage["content"];
?>

In the next section, 'Basic Output', you see a sample PHP script that demonstrates how easy it is to pull data from SiteRefresh.

Basic Output >