fixed path problem

git-svn-id: http://yolanda.mister-muffin.de/svn@28 7eef14d0-6ed0-489d-bf55-20463b2d70db
This commit is contained in:
josch 2007-10-11 17:06:08 +00:00
parent d906ad3f31
commit ba33884b1a
8 changed files with 19 additions and 13 deletions

View file

@ -1,5 +1,5 @@
#!/usr/bin/perl #!/usr/bin/perl
require "/var/www/perl/include.pl"; require "include.pl";
#get tags from database and fill $page with xml #get tags from database and fill $page with xml
sub fill_tagcloud { sub fill_tagcloud {

View file

@ -4,6 +4,10 @@ use CGI::Session;
use DBI; use DBI;
use XML::Simple qw(:strict); use XML::Simple qw(:strict);
use Digest::SHA; use Digest::SHA;
$gnutube_root = '/var/www/perl';
use lib qw($gnutube_root);
#use Digest::SHA qw(sha256_hex); #use Digest::SHA qw(sha256_hex);
#set global variables #set global variables

View file

@ -1,13 +1,13 @@
#!/usr/bin/perl #!/usr/bin/perl
require "/var/www/perl/include.pl"; require "include.pl";
require "/var/www/perl/functions.pl"; require "functions.pl";
#create or resume session #create or resume session
CGI::Session->name($session_name); CGI::Session->name($session_name);
my $session = new CGI::Session; my $session = new CGI::Session;
#read xml #read xml
$page = XMLin('/var/www/perl/index.xml', ForceArray => 1, KeyAttr => {} ); $page = XMLin("$gnutube_root/index.xml", ForceArray => 1, KeyAttr => {} );
#if a username is associated with session id, username is nonempty #if a username is associated with session id, username is nonempty
$page->{username} = get_username_from_sid($session->id); $page->{username} = get_username_from_sid($session->id);
@ -19,3 +19,5 @@ print $session->header(-type=>'text/xml');
#print xml #print xml
print XMLout($page, KeyAttr => {}, XMLDecl => '<?xml version="1.0" encoding="ISO-8859-1" ?><?xml-stylesheet type="text/xsl" href="./xsl/xhtml.xsl" ?>', RootName => 'page'); print XMLout($page, KeyAttr => {}, XMLDecl => '<?xml version="1.0" encoding="ISO-8859-1" ?><?xml-stylesheet type="text/xsl" href="./xsl/xhtml.xsl" ?>', RootName => 'page');

View file

@ -1,5 +1,5 @@
#!/usr/bin/perl #!/usr/bin/perl
require "/var/www/perl/include.pl"; require "include.pl";
#initialize session data #initialize session data
CGI::Session->name($session_name); CGI::Session->name($session_name);

View file

@ -1,5 +1,5 @@
#!/usr/bin/perl #!/usr/bin/perl
require "/var/www/perl/include.pl"; require "include.pl";
#initialize session data #initialize session data
CGI::Session->name($session_name); CGI::Session->name($session_name);

View file

@ -1,5 +1,5 @@
require "/var/www/perl/include.pl"; require "include.pl";
require "/var/www/perl/functions.pl"; require "functions.pl";
#initialize session data #initialize session data
CGI::Session->name($session_name); CGI::Session->name($session_name);
@ -10,7 +10,7 @@ $session = new CGI::Session;
if($query->param('query')) { if($query->param('query')) {
my $search_query = $query->param('query'); my $search_query = $query->param('query');
$page = XMLin('/var/www/perl/search.xml', ForceArray => 1, KeyAttr => {} ); $page = XMLin('$gnutube_root/search.xml', ForceArray => 1, KeyAttr => {} );
#if a username is associated with session id, username is nonempty #if a username is associated with session id, username is nonempty
$page->{username} = get_username_from_sid($session->id); $page->{username} = get_username_from_sid($session->id);

View file

@ -1,6 +1,6 @@
#!/usr/bin/perl #!/usr/bin/perl
require "/var/www/perl/include.pl"; require "include.pl";
require "/var/www/perl/functions.pl"; require "functions.pl";
#create or resume session #create or resume session
CGI::Session->name($session_name); CGI::Session->name($session_name);

View file

@ -1,6 +1,6 @@
#!/usr/bin/perl #!/usr/bin/perl
require "/var/www/perl/include.pl"; require "include.pl";
require "/var/www/perl/functions.pl"; require "functions.pl";
CGI::Session->name($session_name); CGI::Session->name($session_name);
$query = CGI->new(\&hook); $query = CGI->new(\&hook);