コード例 #1
0
ファイル: Test.php プロジェクト: artovenry/haml
 function testRenderSomething()
 {
     $haml = new Artovenry\Haml();
     $this->assertEquals($haml->renderSomething(), "renderSomething");
 }
コード例 #2
0
ファイル: functions.php プロジェクト: showtarow/scaffold-1
<?php

define('ART_ENV', 'development');
require TEMPLATEPATH . "/vendor/autoload.php";
define('ART_VIEW', TEMPLATEPATH . '/view');
define('ART_VERSION_YAML', TEMPLATEPATH . '/version.yml');
Artovenry\Wp\Version::run();
Artovenry\Wp\Helpers::run();
Artovenry\Haml::run();
remove_buildin_scripts();
add_theme_support('title-tag');
if (ART_ENV !== "production") {
    add_action('init', function () {
        add_filter("redirect_canonical", function () {
            return false;
        });
    });
}
if (!is_page("contact")) {
    remove_action('wp_enqueue_scripts', 'wpcf7_do_enqueue_scripts');
}
コード例 #3
0
ファイル: index.php プロジェクト: artovenry/haml
<?
require dirname(__DIR__) . "/vendor/autoload.php";
Artovenry\Haml::init("", ["debug"=>true]);
render("index", "hoge", ["var"=>safe_html("<i>hoge</i>")]);