| 148 |
lars |
1 |
\$compile\_dir {#variable.compile.dir}
|
|
|
2 |
==============
|
|
|
3 |
|
|
|
4 |
This is the name of the directory where compiled templates are located.
|
|
|
5 |
By default this is `./templates_c`, meaning that Smarty will look for
|
|
|
6 |
the `templates_c/` directory in the same directory as the executing php
|
|
|
7 |
script. **This directory must be writeable by the web server**, [see
|
|
|
8 |
install](#installing.smarty.basic) for more info.
|
|
|
9 |
|
|
|
10 |
> **Note**
|
|
|
11 |
>
|
|
|
12 |
> This setting must be either a relative or absolute path. include\_path
|
|
|
13 |
> is not used for writing files.
|
|
|
14 |
|
|
|
15 |
> **Note**
|
|
|
16 |
>
|
|
|
17 |
> It is not recommended to put this directory under the web server
|
|
|
18 |
> document root.
|
|
|
19 |
|
|
|
20 |
> **Note**
|
|
|
21 |
>
|
|
|
22 |
> As of Smarty 3.1 the attribute \$compile\_dir is no longer accessible
|
|
|
23 |
> directly. Use [`getCompileDir()`](#api.get.compile.dir) and
|
|
|
24 |
> [`setCompileDir()`](#api.set.compile.dir) instead.
|
|
|
25 |
|
|
|
26 |
See also [`getCompileDir()`](#api.get.compile.dir),
|
|
|
27 |
[`setCompileDir()`](#api.set.compile.dir),
|
|
|
28 |
[`$compile_id`](#variable.compile.id) and
|
|
|
29 |
[`$use_sub_dirs`](#variable.use.sub.dirs).
|