Skip to content

Instantly share code, notes, and snippets.

@kurozumi
Last active Aug 29, 2015
Embed
What would you like to do?
【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