[vhffs-dev] [1026] Fixed utf8 on descriptions |
[ Thread Index |
Date Index
| More vhffs.org/vhffs-dev Archives
]
Revision: 1026
Author: gradator
Date: 2007-10-25 20:26:53 +0000 (Thu, 25 Oct 2007)
Log Message:
-----------
Fixed utf8 on descriptions
Modified Paths:
--------------
trunk/vhffs-panel/cvs/create.pl
trunk/vhffs-panel/dns/create.pl
trunk/vhffs-panel/git/create.pl
trunk/vhffs-panel/group/create.pl
trunk/vhffs-panel/mail/create.pl
trunk/vhffs-panel/mailinglist/create.pl
trunk/vhffs-panel/mysql/create.pl
trunk/vhffs-panel/pgsql/create.pl
trunk/vhffs-panel/repository/create.pl
trunk/vhffs-panel/svn/create.pl
trunk/vhffs-panel/web/create.pl
trunk/vhffs-panel/web/prefs.pl
trunk/vhffs-panel/web/prefs_save.pl
Modified: trunk/vhffs-panel/cvs/create.pl
===================================================================
--- trunk/vhffs-panel/cvs/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/cvs/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
@@ -74,7 +74,7 @@
if($submitted) {
$reponame = $cgi->param('REPOSITORY_NAME');
my $fullreponame = $groupname.'/'.$reponame;
- $description = $cgi->param('DESCRIPTION');
+ $description = Encode::decode_utf8( $cgi->param('DESCRIPTION') );
unless( defined $reponame && defined $description ) {
$panel->add_error( gettext('CGI error') );
Modified: trunk/vhffs-panel/dns/create.pl
===================================================================
--- trunk/vhffs-panel/dns/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/dns/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -1,5 +1,6 @@
#!%PERL% -w
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -7,7 +8,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -42,7 +43,7 @@
if( $submitted ) {
$domain_name = $cgi->param('DOMAIN_NAME');
- $description = $cgi->param('DESCRIPTION');
+ $description = Encode::decode_utf8( $cgi->param('DESCRIPTION') );
unless( defined $domain_name && defined $description ) {
$panel->add_error( gettext('CGI error') );
Modified: trunk/vhffs-panel/git/create.pl
===================================================================
--- trunk/vhffs-panel/git/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/git/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -30,7 +30,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -38,7 +38,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -74,7 +74,7 @@
if( $submitted ) {
$reponame = $cgi->param('reponame');
my $fullreponame = $groupname.'/'.$reponame.'.git';
- $description = $cgi->param('description');
+ $description = Encode::decode_utf8( $cgi->param('description') );
unless( defined $reponame && defined $description ) {
$panel->add_error( gettext('CGI error') );
} elsif( !Vhffs::Services::Git::check_name($fullreponame) ) {
Modified: trunk/vhffs-panel/group/create.pl
===================================================================
--- trunk/vhffs-panel/group/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/group/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -57,8 +57,8 @@
my $templatedir = $vhffs->get_config->get_templatedir;
my $submitted = defined($cgi->param('project_submit'));
my $groupname = $cgi->param('project_name');
-my $realname = $cgi->param('realname');
-my $description = $cgi->param('description');
+my $realname = Encode::decode_utf8( $cgi->param('realname') );
+my $description = Encode::decode_utf8( $cgi->param('description') );
if($submitted) {
# User posted the form, let's check it
@@ -95,6 +95,5 @@
$template->param( DESCRIPTION_VALUE => CGI::escapeHTML( $description ) );
$panel->build( $template );
-$panel->display;
+ $panel->display;
}
-
Modified: trunk/vhffs-panel/mail/create.pl
===================================================================
--- trunk/vhffs-panel/mail/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/mail/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::Panel::Main;
@@ -69,7 +69,7 @@
if( $submitted ) {
$domain = $cgi->param('domain');
- $description = $cgi->param('description');
+ $description = Encode::decode_utf8( $cgi->param('description') );
unless( defined $domain && defined $description ) {
$panel->add_error( gettext('CGI error') );
} elsif( !Vhffs::Functions::check_domain_name($domain) ) {
Modified: trunk/vhffs-panel/mailinglist/create.pl
===================================================================
--- trunk/vhffs-panel/mailinglist/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/mailinglist/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,13 +29,13 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template::Expr;
use locale;
use Locale::gettext;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -75,7 +75,7 @@
if( $submitted ) {
$localpart = $cgi->param( 'localpart' );
$domain = $cgi->param( 'domain' );
- $description = $cgi->param( 'description' );
+ $description = Encode::decode_utf8( $cgi->param( 'description' ) );
unless( defined $localpart && defined $domain && defined $description ) {
$panel->add_error( gettext('CGI error') );
Modified: trunk/vhffs-panel/mysql/create.pl
===================================================================
--- trunk/vhffs-panel/mysql/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/mysql/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -76,7 +76,7 @@
my $dbname = $groupname.'_'.$dbsuffix;
my $dbuser = $dbname;
$dbpass = $cgi->param('db_pass');
- $description = $cgi->param('description');
+ $description = Encode::decode_utf8( $cgi->param('description') );
unless( defined $dbpass && defined $dbsuffix && defined $description ) {
$panel->add_error( gettext('CGI error') );
Modified: trunk/vhffs-panel/pgsql/create.pl
===================================================================
--- trunk/vhffs-panel/pgsql/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/pgsql/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
Modified: trunk/vhffs-panel/repository/create.pl
===================================================================
--- trunk/vhffs-panel/repository/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/repository/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
@@ -71,7 +71,7 @@
my $description = '';
if( $submitted ) {
- $description = $cgi->param('description');
+ $description = Encode::decode_utf8( $cgi->param('description') );
unless( defined $description ) {
$panel->add_error( gettext('CGI error') );
Modified: trunk/vhffs-panel/svn/create.pl
===================================================================
--- trunk/vhffs-panel/svn/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/svn/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -73,7 +73,7 @@
if( $submitted ) {
$reponame = $cgi->param('reponame');
my $fullreponame = $groupname.'/'.$reponame;
- $description = $cgi->param('description');
+ $description = Encode::decode_utf8( $cgi->param('description') );
unless( defined $reponame && defined $description ) {
$panel->add_error( gettext('CGI error') );
Modified: trunk/vhffs-panel/web/create.pl
===================================================================
--- trunk/vhffs-panel/web/create.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/web/create.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -72,7 +72,7 @@
if( $submitted ) {
$servername = $cgi->param('servername');
- $description = $cgi->param('description');
+ $description = Encode::decode_utf8( $cgi->param('description') );
unless( defined $servername && defined $description ) {
$panel->add_error( gettext('CGI error') );
} elsif( !Vhffs::Functions::check_domain_name($servername) ) {
Modified: trunk/vhffs-panel/web/prefs.pl
===================================================================
--- trunk/vhffs-panel/web/prefs.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/web/prefs.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
Modified: trunk/vhffs-panel/web/prefs_save.pl
===================================================================
--- trunk/vhffs-panel/web/prefs_save.pl 2007-10-25 19:00:08 UTC (rev 1025)
+++ trunk/vhffs-panel/web/prefs_save.pl 2007-10-25 20:26:53 UTC (rev 1026)
@@ -29,7 +29,7 @@
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
-
+use strict;
use utf8;
use POSIX qw(locale_h);
use HTML::Template;
@@ -37,7 +37,7 @@
use Locale::gettext;
use CGI;
use CGI::Session;
-use strict;
+use Encode;
use lib '%VHFFS_LIB_DIR%';
use Vhffs::User;
@@ -86,7 +86,7 @@
}
else
{
- $description = $cgi->param("DESCRIPTION");
+ $description = Encode::decode_utf8( $cgi->param("DESCRIPTION") );
$web->set_description( $description );
$web->commit;
$message = gettext( "Modifications applied to your webarea" );