Joomla!, Wordpress tips for building your site

global variables can not handle runPHP

Published on| November 29th, 2009 | No Comment.

runPHP seems to handle global variables.
runPHP usage in the pages that have a global scope does not work.
Have not read in detail, I like that.

Try code 1
<?php
$aaa = 'test';
function displayAAA()
{
	global $aaa;
	echo $aaa;
}
displayAAA();
?>

Please try to see the above code to embed in the article.
Not display the marvelous.()

Of course, the above code and save the file php, WEB from direct, php files would start,
test
Makes it appears.

Try code 2
<?php
function displayAAA()
{
	$aaa = 'test';
	echo $aaa;
}
displayAAA();
?>

Please try to see the above code to embed in the article.
But of course, the dazzling display.()

To find it, I took a hell of time.()
exec php?I was also in the other plug-ins, this behavior does not change.
The first written usage as well "eval () function is limited."Rashii?Is.

Should not use global've been stupid of me to rely on.(Serious soul-searching.)






Comments

Leave a Reply








Transrator

Recent Posts

Categories

Tag Cloud

execute remove フロントページ 投稿ページ トップページ install WIndows Note Convert META generator 日付 donwload file manage multibyte utf-8 unicode shiftjis euc console サイトマップ 問題 ParmaLink Redirect パーマリンク はみ出る pre テンプレート テーマ タグクラウド マルチランゲージ リダイレクト PHP(タグ) タグ table control HTML(タグ) コマンド 国際化(翻訳) SQLite(タグ) MySQL(タグ) qTranslate プラグイン(タグ) Wordpress(タグ)

Links

Site Description

Joomla!, Wordpress as CMS using a site building, site management, software usage to describe the development tips.

  • はてなブックマークへ追加する
  • Facebookでシェアする
  • twitter でつぶやく
  • Google Plusでシェアする
  • Pocketでシェアする
ページトップへ