From 18050d88638760fe82515afde470994c5f569e48 Mon Sep 17 00:00:00 2001 From: mitty Date: Wed, 27 Oct 2010 06:15:15 +0000 Subject: [PATCH] * FIX warning error on no language is chosen ('clear' button pressed) git-svn-id: https://lab.mitty.jp/svn/lab/trunk@77 7d2118f6-f56c-43e7-95a2-4bb3031d96e7 --- genshi/index.php | 1 + 1 file changed, 1 insertion(+) diff --git a/genshi/index.php b/genshi/index.php index 7817396..e73d21d 100755 --- a/genshi/index.php +++ b/genshi/index.php @@ -30,6 +30,7 @@ if (isset($_POST['submit'])) { $_POST['source'] = stripslashes($_POST['source']); } if (!strlen(trim($_POST['source']))) { + if(! isset($_POST['language'])) { $_POST['language'] = 'php'; } $_POST['language'] = preg_replace('#[^a-zA-Z0-9\-_]#', '', $_POST['language']); $_POST['source'] = implode('', @file($path . 'geshi/' . $_POST['language'] . '.php')); $_POST['language'] = 'php'; -- 1.7.9.5