Hi,
I need to have the filename and the comment somehow be accessible to a php script created by myself so that I can update a database on what has just been uploaded.
I don't care if it uses POST OR GET. I just the variable. How can I do this?
I have commented out the following in XUploadconfig.pm
# URL to send all input values from upload page
#url_post => '......../cgi-bin/UPLOAD/post.cgi',
The webpage is redirected to the page:
# The link to redirect after complete upload
# This setting can be submitted from HTML form, then it will have priority
redirect_link => 'http://somedomainname.com/audio/processinfo.php',
I'd like to have access the filename and comment fields in processinfo.php.
How can I do this?
XUpload - Filename and Comment Access via PHP
Filename and Comment Access via PHP
Last edited by kendan on Oct 18, 2007 2:55 pm, edited 1 time in total.
- PilgrimX182
- Posts: 2186
- Joined: Mar 22, 2006 1:39 pm
Hi,
Thanks for your reply. I am not able to find post.php .
I don't see an archive on the site or in the forum.
I don't know perl but I have made progress by using the code below in php.cgi I realize, that my modification is not 'tidy' but it works. Only the filename and the comment are collected and a redirect is used. On the receiving end, $_GET is used by php.
Ken
#!/usr/bin/perl
use CGI;
my $cgi = CGI->new();
my @param = $cgi->param();
#print"Content-type: text/html\n\n";
$i=0;
for(@param)
{
my @arr = $cgi->param($_);
if ($i==1) {
$a= '?name=' . join(':',@arr);
}
if ($i==3) {
$a.= '&title=' . join(':',@arr);
}
$i++;
}
print "Status: 301 Moved Permanantly\n";
print "Location: http://mydomain.com/audio/uploadfile.php$a\n\n";
exit;
Thanks for your reply. I am not able to find post.php .
I don't see an archive on the site or in the forum.
I don't know perl but I have made progress by using the code below in php.cgi I realize, that my modification is not 'tidy' but it works. Only the filename and the comment are collected and a redirect is used. On the receiving end, $_GET is used by php.
Ken
#!/usr/bin/perl
use CGI;
my $cgi = CGI->new();
my @param = $cgi->param();
#print"Content-type: text/html\n\n";
$i=0;
for(@param)
{
my @arr = $cgi->param($_);
if ($i==1) {
$a= '?name=' . join(':',@arr);
}
if ($i==3) {
$a.= '&title=' . join(':',@arr);
}
$i++;
}
print "Status: 301 Moved Permanantly\n";
print "Location: http://mydomain.com/audio/uploadfile.php$a\n\n";
exit;