Example: PHP 2
<?php
</*
* With embedded HTML
*/
function show_metabox_syntax() {
global $post;
extract( $this->metaboxes['syntax']['field'] );
$meta = get_post_meta($post->ID, $id, true);
// echo $meta;
?>
<input type="hidden" name="codesnips_syntax_metabox_nonce" value="<?php
echo wp_create_nonce(basename(__FILE__)) ?>" />
<div class="lang-syntax-wrap">
<div class="codesnips_field_type_<?php echo str_replace(' ', '_', $type) ?>">
<?php foreach ($options as $key => $option) { ?>
<span class="lang-syntax <?php echo $key ?>">
<input id="<?php echo $key ?>" type="radio" name="<?php
echo $id ?>" value="<?php echo $key ?>"<?php
echo ($meta == $key ? ' checked="checked"' : '') ?> />
<label for="<?php echo $key ?>"><?php echo $option ?></label>
</span>
<?php }// end foreach ?>
<?php echo $desc != '' ? '<br><span class="desc">' . stripslashes($desc) . '</span>' : '' ?>
<div class="clr"></div>
</div>
</div>
<?php
}
Example: WP
define( 'DS', DIRECTORY_SEPARATOR ); // DIRECTORY_SEPARATOR
define( 'OZ_CONTENT_DIR', 'assets' ); //
define( 'WP_CONTENT_DIR', ABSPATH .OZ_CONTENT_DIR ); // /svr-root/path-to/site-root/assets
define( 'WP_CONTENT_URL', WP_SITEURL.DS.OZ_CONTENT_DIR ); // http://site.dev/assets
define( 'WP_PLUGIN_DIR', WP_CONTENT_DIR.DS.'plugins' ); // /svr-root/path-to/site-root/assets/plugins
define( 'WP_PLUGIN_URL', WP_CONTENT_URL.DS.'plugins' ); // http://site.dev/assets/plugins
define( 'UPLOADS', OZ_CONTENT_DIR.DS.'files' ); // http://site.dev/assets/files
Example: PHP
define( 'THISHOMEY', 'this is a homey');
echo THISHOMEY;
require_once 'Zend/Uri/Http.php';
namespace Location\Web;
interface Factory
{
static function _factory();
}
abstract class URI extends BaseURI implements Factory
{
abstract function test();
$num_var = (4 * $num) / 27 + $num2 - 6.3;
$num_var=(4*$num)/27+$num2-6.3;
$this->object->item = 0;
$concat = 'This string get\'s to ';
$concat .= 'be added to by another line';
$morect = "Another for \"me\" and you!";
/**
* Returns a URI
*
* @return URI
*/
static public function _factory($stats = array(), $uri = 'http')
{
echo __METHOD__;
$uri = explode(':', $uri, 0b10);
$schemeSpecific = isset($uri[1]) ? $uri[1] : '';
$desc = 'Multiline
description == | = | != | === | !== | description
description';
// Security check
if (!ctype_alnum($scheme)) {
throw new Zend_Uri_Exception('Illegal scheme');
}
return [
'uri' => $uri,
'value' => null,
];
}
if ( $var == 'timed' || $var != '' ( $var === '' && $var !== '' ) ) {}
if ($var=='timed'||$var!=''($var===''&&$var!=='')){}
if ( $var < '' || $var > '' || $var <= '' || $var => '' ) {}
if ($var<''||$var>''||$var<=''||$var=>''){}
}
__halt_compiler ();
/*
datahere
datahere
datahere
datahere
*/