Having trouble finding the correct syntax for creating a Definition List via Perl to create output as follows:
<dt>One</dt>
<dd><p>Testing 1</p></dd>
<dt>Two</dt>
<dd><p>Testing 2</p></dd>
<dt>Three</dt>
<dd><p>Testing 3</p></dd>
</dl>
I can't seem to find any documentation on the usage. I tried $cgi->d...
virtual() can be used only when running PHP as an apache module. My shared hosting runs it as CGI so it doesn't work. Is there any other method to do it?
Note: the subrequest is for static files that I'd like to let Apache serve (for performance, HTTP-headers caching, etc.). Right now this is handled by using an HTTP redirect (that I wa...
I have a Ruby on Rails application that uses Apache as web server and my application calls a CGI for some time. This was installed in Windows Server 2008 R2 64-bit. My problem is, the CGI is not working as expected, Apache says 'premature end of script'. I am sure that there is no problem with my CGI nor in my Ruby application because it...
Hi everyone,
I've been trying to solve a little problem for quite a while now but it seems I'm not able to.
I wrote an HTML page which calls a perl CGI script upon submitting a form. This CGI executes a certain number of tasks server-side and I made the script print the steps of these tasks into an iframe on the HTML page. The thing i...
I'm considering moving from PHP to Python (for personal projects), and I really don't like seeing /cgi-bin/ in my URL.
I got the Python to execute outside of cgi-bin, but I just wanted to make sure there were no possible security issues that could pop up, and that there were no major impacts on the speed.
So are there any major issues ...
I have a cgi code that is being called by AJAX from clientside javascript. However, the result of the call is discarded by the client.
On the backend this code occurs:
$|=1;
my $i = 0;
while (<$fh_echo>)
{
#To prevent apache timing out the cgi script.
print "." if $i % 100 == 0;
#Do stuff
$i++;
}
Despite the period...
I have a perl CGI that needs to report some information back to the browser before it goes into a really lengthy process that frequently takes several minutes.
Currently I print the message but it doesn't show up till the entire process exits.
So, my question is:
Is it possible to get the message back to browser mid stream and if not
...
I have here embedded device with linux.
There is a webserver boa. http://www.boa.org/
I am trying to start sh cgi script.
#!/bin/sh
echo "Content-type: text/html\n"
echo "Hello world !"
./script.cgi works, but in webbrowser I get
502 Bad Gateway
The CGI was not CGI/1.1 compliant.
Can anyone help me?
...
Hi
I have a perl script (Cgi / Apache / Windows) which executes some programs on the computer, and formats the output for the web. The script takes about 4-5 minutes to completely run.
My problem is that when someone cancels page load (or closes the web browser) while the script is running, the perl process in the server will keep runni...
In a HTML form, if we give names to input boxes with [], like this
<input name="foo[]" type="text" />
<input name="foo[]" type="text" />
In PHP, we can obtain values of these input boxes in an array, with $_POST['foo'].
How to do the similar in Perl? I use CGI.pm
...
TFMail was a popular CGI Form Mail script at one time.
Unfortunately, my client insists on continuing to use it. I hope that there are people who still use it and are experts in using it. The best documentation I can find is someone's home made reference sheet.
In my HTML form, I have an input named attachment1 :
<input type="file"...
TFMail was a popular PERL CGI Form Mail script at one time. So far it has served our purposes. It is very easy to set up and configure.
Unfortunately, it only has basic functionality. It works well when you want users to fill in a form and have the result emailed to a specified email address.
Can someone recommend a script ( maybe...
I want to send a binary file to the user and have some HTML display on the browser. I'm using a CGI-BIN script with apache2. I found this example on page 4. The link also shows details about the multipart/related content-type. Here's what I tried so far:
Content-Type: Multipart/Related; boundary="boundary-content"; start=""; type=\...
I want my .pl to execute a function at the end of every day, week and month. What the function will do is grab an integer from an html at the end of the day and store it in a .txt to be used to create a graph.
I already know how to implement CGI and JS with a perl script, so that is no issue. I'm just not clear on whether or not DateTi...
I recently discovered that CGI scripts can be written in pretty much any language that can print to stdout. I've written a small guile cgi script that works on my local apache install, but not on my shared host:
#!/usr/local/bin/guile -s
!#
(display "Content-Type: text/html")
(newline)
(newline)
(display "hi")
(newline)
This is the o...
Javascript CSS issue:
I am using a textarea box to write to a div. I get the textarea box to do this by using the following javascript:
<script type="text/javascript">
function process_input(){
document.getElementById("description").innerHTML = document.getElementById("message").value;
return true;
}
</script>
I style...
Nowadays when running WAMP or MAMP (or the default web server on a Mac), whenever there is error from the CGI file (such as Ruby or PHP), the error message is not shown (and no line number either). Is there a way to run the web server in a shell so that any error message is shown?
The one I am trying to show is on a Mac's built-in web ...
I'm trying to figure out the right way to serve icon files for our site listings. Basically an icon for a listing can come from an image file from a handful of different services (Flickr, Picasa, Google Static Maps, our own internal image hosting service, etc). The URL of the icon is stored in our database so I'd like to enable each list...
The variables $_SERVER['PHP_AUTH_USER'] and $_SERVER['PHP_AUTH_PW'] are returned as empty because of the setup my hosting has (Running on a CGI interface). Is there any work around to get them to work as I need to use them for auth. I can't move hosting or change the interface.
I am sending auth requests via curl to a url /api/projects/...
I have a CGI script which takes about 1 minute to run. Right now Apache only returns results to the browser once the process has finished.
How can I make it show the output like it was run on a terminal?
Here is a example which demonstrates the problem.
I want to see the numbers 1 to 5 appear as they are printed.
...