Changeset 665
- Timestamp:
- 05/08/07 21:28:03 (1 year ago)
- Files:
-
- trunk/examples/index.php (modified) (1 diff)
- trunk/examples/variants (added)
- trunk/examples/variants/variants.php (moved) (moved from trunk/docroot/variants.php) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/examples/index.php
r658 r665 71 71 <li><a href="foreignClassLoaders/">Loading classes from foreign resources with the Stubbles class loader</a></li> 72 72 <li><a href="logging/">Logging data</a></li> 73 <li><a href="variants/variants.php">Using variants</a> (<a href="showsource.php?group=variants&example=variants">show PHP source</a>)</li> 73 74 <li> 74 75 XML handling trunk/examples/variants/variants.php
r524 r665 1 1 <?php 2 require '../config/php/config.php'; 3 require '../lib/stubbles.php'; 2 /** 3 * Example for variants 4 * 5 * @author Frank Kleine <mikey@stubbles.net> 6 * @author Stephan Schmidt <schst@stubbles.net> 7 * @see http://www.stubbles.net/wiki/Docs/MVC/Variant 8 */ 9 require '../../config/php/config.php'; 10 require '../bootstrap-stubbles.php'; 11 4 12 stubClassLoader::load('net.stubbles.websites.variantmanager.stubVariantXJConfFactory', 5 13 'net.stubbles.ipo.request.stubWebRequest', … … 10 18 public static function main() 11 19 { 12 echo '<pre>';13 20 $factory = new stubVariantXJConfFactory(stubConfig::getConfigPath() . '/xml/variantmanager.xml'); 14 21 $request = new stubWebRequest(); 15 22 $session = new stubPHPSession($request, 'web'); 23 echo '<pre>'; 16 24 var_dump($factory->getVariantsMap()->getVariant($session, $request)->getFullQualifiedName()); 25 echo '</pre>'; 17 26 } 18 27 }
