Hello! I'm developing a little CGI application (in C, with CGIC, http://www.boutell.com/cgic/). My application needs to create a temporary
file (the user upload an images, it is saved, modified in various ways, and
then shown back to the user).
What precautions should I take while creating temporary files?
The modified image is provide...
Using the examples from the CGI::Session::Auth::DBI and CGI::Session::Auth pages, I have attempted to implement the _login function with no success. I'm using Windows 7 and Apache 2.
#!/usr/bin/perl -w
use strict;
use CGI::Carp qw(fatalsToBrowser);
use CGI;
use CGI::Session;
use CGI::Session::Auth::DBI;
my $cgi = new CGI;
# using '....
Hello folks,
I have a little apache2 CGI application on the Ubuntu. The CGI handler is bash shell script.
My client application is search.html:
<html>
<body>
<form action="/cgi-bin/search.sh" method="post">
<input type="text" name="searchKey" size="10"></input>
<input type=SUBMIT value="search">
<form>
</body>
</html>
firstly...
I have a simple python CGI script where I query a MySQL database and then prints the result to the screen/webpage.
My problem is that the "cursor.execute()" function returns a list of tuples. I use a simple for loop to iterate through this list and extract each tuple. This was working great until.....I got the bright idea to use jquery t...
I'm trying to compose a .zip file in a CGI program and send that as the content response. I'm getting stuck in that whenever I spawn a program that prints to stdout, that somehow doesn't get accepted by Apache. It seems to be something to do with spawning a program that writes to stdout. The snippet below reproduces this problem. I ...
Hello All,
I have a C/CGI application. In order to redirect to the same page
const char * redirect_page_format =
"<html>\n"
"<head>\n"
"<meta http-equiv=\"REFRESH\"\n"
"content=\"0;url=%s\">\n"
"</head>\n"
"</html>\n";
printf (redirect_page_format, getenv (URL));
Before this the url is like this "http://ipaddress/page.html".
For so...
I want to load an applet from a server side script, eg. a Perl CGI program, etc. Can this be done? how?
<applet code=A21 width=256 height=256 archive="http://url/cgi-bin/test.cgi?R=applet">
thanks in advance for all help.
...
Hi,
I made a awk script to do stuff on some input files but as I want to avoid installing gawk on the windows machines I want this awk script to be available as a webservice or just a form where I can either upload a file or just copy the text of the file in a box and run the script on it and get back the result of the awk script.
How ...
I am trying to print a XML file in the browser using a perl script. While I am trying to run the script in my browser I am having the following error.
Server error!
The server encountered an internal error and was unable to complete your request.
Error message:
Premature end of script headers: get_data.pl
If you think this is a server...
For my college project, I want to create a simple application server in C that runs over Apache. Like .php, .asp, .jsp, the extension of my files would be .sas.
I have already written a parser which reads the .sas files and generates the output. For example, consider a file index.sas with the below code:
<%
echo "Hello";
%>
...
I am in a Web Scripting class at school and am working on my first assignment. I tend to overdo things and delve deeper into my subject than what is required in my classes. Right now I am researching CGI.pm to do my HTTP requests and it says there are two programming styles for CGI.pm:
An object-oriented style
A function-oriented style...
CGI is a Comman Gateway Interface. As the name says, it is a "common" gateway interface for everything. It is so trivial and naive from the name. I feel that I understood this and I felt this every time I encountered this word. But frankly, I didn't. I'm still confused.
I am a PHP programmer. I did lot of web development.
user (clien...
I have a CGI script I'm writing that's handling a streaming file upload. I'm also using Apache. If a certain size limit is reached, I have the CGI script finish things up, then it sends an HTTP redirect and exit. What I'd like to have happen at this point is for Apache to close the connection. Instead, what Apache does is keep the co...
If I'm using the CGI module in Perl, I can do this
$cgi = CGI->new();
$cgi->header(-type=>"text/html");
Or go for the classic
print "Content-Type: text/html\r\n\r\n";
Does it matter which we use? Is there any difference between the two? Both seem to work.
For me I'd go for the first if I was using CGI anyway, but if not then I wou...
I use Dreamweaver as my editor of choice for web development, and often find old projects have a few Perl files.
For some reson the Dreamweaver find and replace dialog does not seem to recognise these Perl files e.g. .pl or .cgi as searchable files, so when I use the "find in folder" on a folder I know contains only Perl files it retur...
Is it possible to configure lighttpd so that a request for a file succeeds if the file exists, but is handled and redirected, for example to a cgi script, if the file does not exist?
What I'm trying to achieve is having a set of image files on disk which are generated by a script and served directly. On a request, if the file does not e...
I'm sure we (I'm referring to web developers) have at one time or another used a web scripting language like php, perl, python, or asp.
But, we know you can also write cgi applications in languages like C.
So, has anyone used an unusual language for writting CGI applications? By unusual, I mean a language that is not generally known fo...
Hey guys,
so i have a couple of sites on paid shared hosting, my host limits the mail to 300 per hour.
One of my sites has more than 500 subscribers.
My question is how can i send the newsletter to all my subscribers? is there a way or a script that i can use to send the first 300 users the email and after an hour to send the rest...?
...
All,
My host supports Perl CGI scripts, how do I use a compiled CGI script on the host?
I tried setting execute permissions via chmod, but when I try and run it via the browser, I get a server error.
Thanks in advance for all help.
...
I need to have a Python CGI script do some stuff (a little bit of security checking), and then end up calling a Perl CGI script, passing anything it received (e.g., POST info) onto the Perl script.
For background, my reason for doing this is that I'm trying to integrate Swish searching with Mailman list archives.
Swish searching uses s...