Saludos...
Necesito ayuda con un Script XFileSharingPro, lo he subido por ftp para instalarlo ya, a dos dominios diferentes y siempre cuando voy a instalarlo no me aparece con el diseño adecuado siempre deformado con codigo asi:
#!/usr/bin/perl use strict; use CGI::Carp qw(fatalsToBrowser); use lib \'.\'; use DBI; use XFileConfig; use Session; use CGI qw(param); my $ok = \"
OK\"; my $ses = Session->new; my $f = $ses->f; if($f->{site_settings}) { my @fields = qw(temp_dir upload_dir htdocs_dir); $f->{temp_dir} = \"$f->{cgi_path}/temp\"; $f->{upload_dir} = \"$f->{cgi_path}/uploads\"; $f->{htdocs_dir} = \"$f->{site_path}/files\"; my $conf; open(F,\"XFSConfig.pm\")||$ses->message(\"Can\'t read XFSConfig\"); $conf.=$_ while ; close F; for my $x (@fields) { my $val = $f->{$x}; $conf=~s/$xs*=>s*(S+)s*,/\"$x => \'$val\',\"/e; } open(F,\">XFSConfig.pm\")||$ses->message(\"Can\'t write XFSConfig\"); print F $conf; close F; } if($f->{save_sql_settings} || $f->{site_settings}) { my @fields = $f->{save_sql_settings} ? qw(db_host db_login db_passwd db_name pasword_salt) : qw(site_url site_cgi site_path); my $conf; open(F,\"XFileConfig.pm\")||$ses->message(\"Can\'t read XFileConfig\"); $conf.=$_ while ; close F; $f->{pasword_salt} = $ses->randchar(12); $f->{dl_key} = $ses->randchar(10); for my $x (@fields) { my $val = $f->{$x}; $conf=~s/$xs*=>s*(S+)s*,/\"$x => \'$val\',\"/e; } open(F,\">XFileConfig.pm\")||$ses->message(\"Can\'t write XFileConfig\"); print F $conf; close F; $ses->redirect(\'install.cgi\'); } if($f->{create_sql}) { my $db = $ses->db; open(FILE,\"install.sql\")||$ses->message(\"Can\'t open create.sql\"); my $sql; $sql.=$_ while ; $sql=~s/CREATE TABLE/CREATE TABLE IF NOT EXISTS/gis; $db->Exec($_) for split(\';\',$sql); $db->Exec(\"INSERT INTO Users (usr_login,usr_email,usr_password,usr_created,usr_ adm) VALUES (?,?,ENCODE(?,?),NOW(),1)\",$f->{usr_login},$f->{usr_email},$f->{usr_password},$c->{pasword_salt}); $ses->redirect(\'install.cgi\'); } print\"Content-type:text/htmlnn\"; print\"
XFileSharingPro Installation Script
\"; print\"1) Permissions Check
\"; my $perms = { \'logs.txt\' => 0666, \'ipn_log.txt\' => 0666, \'fs.cgi\' => 0755, \'index.cgi\' => 0755, \'ipn.cgi\' => 0755, \'cron.pl\' => 0755, \'dl.pl\' => 0755, \'upload.cgi\' => 0755, \'upload_status.cgi\' => 0755, \'api.cgi\' => 0755, \'XFileConfig.pm\' => 0666, \'XFSConfig.pm\' => 0666, \'temp\' => 0777, \'uploads\' => 0777, \"$c->{site_path}/files\" => 0777, \"$c->{site_path}/captchas\" => 0777, }; my @arr; for(keys %{$perms}) { next unless -e $_; chmod $perms->{$_}, $_; my $chmod = (stat($_))[2] & 07777; my $chmod_txt = sprintf(\"%04o\", $chmod); push @arr, \"$_ : $chmod_txt : \".( $chmod == $perms->{$_} ? \'OK\' : \"ERROR: should be \".sprintf(\"%04o\",$perms->{$_}).\"\" ); } chmod 0666, \"$c->{site_path}/.htaccess\" if -f \"$c->{site_path}/.htaccess\"; print join \'
\', @arr; if( grep{/ERROR/}@arr ) { print\"
Fix errors above and refresh this page\"; } else { print\"
All permissions are correct.$ok\"; } print\"\"; print\"2) MySQL Settings
\"; my $dbh=DBI->connect(\"DBI:mysql:database=$c->{db_name};host=$c->{db_host}\",$c->{db_login},$c->{db_passwd}) if $c->{db_name} && $c->{db_host}; if($dbh) { print\"MySQL Settings are correct. Can connect to DB.$ok\"; } else { print<
MySQL Host:
MySQL DB Username:
MySQL DB Password:
MySQL DB Name:
EOP ; } print\"\"; print\"3) MySQL tables create & Admin account
\"; if(!$dbh) { print\"Fix MySQL settings above first.\"; } else { my $sth=$dbh->prepare(\"DESC Files\"); my $rc=$sth->execute(); if($rc) { print\"Tables created successfully.$ok\"; } else { print<
Admin login:
Admin password:
Admin E-mail:
EOP ; } } print\"4) Site URL / Path Settings
\"; if($c->{site_url} && $c->{site_cgi} && -d $c->{site_path}) { print\"Settings are correct.$ok\"; print\"
Login as admin and add FileServer now: $c->{site_url}/login.html\"; } else { my $path = $ENV{DOCUMENT_ROOT}; my ($cgipath) = $ENV{SCRIPT_FILENAME}=~/^(.+)//; my $url_cgi = \'http://\'.$ENV{HTTP_HOST}.$ENV{REQUEST_URI}; $url_cgi=~s//[^/]+$//; my $url = \'http://\'.$ENV{HTTP_HOST}; $url = $c->{site_url}||$url; $url_cgi = $c->{site_cgi}||$url_cgi; $path = $c->{site_path}||$path; print<
htdocs folder URL:
No trailing slash
cgi-bin folder URL:
No trailing slash
cgi-bin disk path:
htdocs disk path:
EOP ; } print\"
Espero que me ayuden, necesito eso, por favor, recomienden que puedo hacer.