6月 272009
 

生成したファイルは、以下のようにしてテキストにすることができます。
$text = $smarty->fetch(“index.tpl”);
print $text;
これを、file_put_contents();で保存します。
file_put_contents(ファイルの絶対パス,$text);
参考ページ:
fetch
file_put_contents

よく読まれている記事

この記事を読んだ人は次の記事も読んでいます:

このエントリーをはてなブックマークに追加
はてなブックマーク - smartyで表示したページをファイルとして保存する fetch
[`google_buzz` not found]
[`yahoo` not found]
[`livedoor` not found]
[`friendfeed` not found]
[`tweetmeme` not found]
[`grow` not found]
[`evernote` not found]

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)