Skip to content

Instantly share code, notes, and snippets.

@kurozumi
Last active August 29, 2015 14:22
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save kurozumi/a94737b95360897a1178 to your computer and use it in GitHub Desktop.
【CodeIgniter3】コントローラーでtwigライブラリを設定
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Welcome extends CI_Controller {
public function index()
{
$this->load->library('twig');
$data = array('test_value' => 'こんにちは');
$this->twig->display("twig.html", $data);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment