Search Results

Search found 1371 results on 55 pages for 'cgi'.

Page 4/55 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • cgi.FieldStorage translating unicode strangely

    - by trydyingtolive
    I have a form that is on a UTF-8 encoded page. When I submit the form cgi.FieldStorage converts any non-ascii character to an odd format. For example if I submit the value c. The browser will send %c4%87. I want to convert that to the string \xc4\x87. However, cgi.FieldStorage is converting it to \\xc4\\x87. post = cgi.FieldStorage(fp=env['wsgi.input'], environ=env, keep_blank_values=True) Python 2.6 on Ubuntu 9.10SE, Apache2, mod_wsgi.

    Read the article

  • Running a python script in background from a CGI

    - by Cagey
    I have a python CGI which runs some script in the background and shows the stdout in the html page. I run the script when the user clicks some button in the page. My problem is when the script starts running the page becomes busy and the user can't use the other client side features in the page. What I want is: The script should run in background when the user clicks the button and should notify the CGI when run is complete. Then the CGI show should the stdout of the script run. How can this be done?

    Read the article

  • CGI site , moscow ml problem

    - by Krewie
    Hello , i'm using Moscow ML combined with CGI. I have a site that calculates simple arithmetics. When the submit button i pushed, the site is redirected to the actual CGI file that outputs the result of the calculation. Although in my case, it outputs the html code in raw form rather then actually outputting the result in html. Anybody that knows a solution to this problem ? // thx beforehand

    Read the article

  • Tornado or Django works with CGI ?

    - by xRobot
    Hi at all, Tornado is a webserver + framework like Django but for real-time features. On my server I don't have a python module or wsgi module so I thought CGI. Is there a way to get Tornado ( or Django ) works by using CGI folder ? If yes, Could you explain me how do I do that ?

    Read the article

  • Why is Perl commonly used as CGI scripts?

    - by Michael Vasquez
    I plan to add a better search feature to my site, so I thought that I would write it in C and use the CGI as a means to access it. But it seems that Perl is the most popular language when it comes to CGI-based stuff. Why is that? Wouldn't it be faster programmed in C or machine code? What advantages, if any, are there to writing it in a scripting language? Thanks.

    Read the article

  • How to call cgi script from ruby

    - by Maddy
    Hello, I've a remote cgi script hosted on Apache using SSL. It takes in two input variables a and b. I want to call call the cgi script with right input variables using ruby. Any clues would be appreciated.

    Read the article

  • CGI Buffering issue

    - by Punit
    I have a server side C based CGI code as: cgiFormFileSize("UPDATEFILE", &size); //UPDATEFILE = file being uploaded cgiFormFileName("UPDATEFILE", file_name, 1024); cgiFormFileContentType("UPDATEFILE", mime_type, 1024); buffer = malloc(sizeof(char) * size); if (cgiFormFileOpen("UPDATEFILE", &file) != cgiFormSuccess) { exit(1); } output = fopen("/tmp/cgi.tar.gz", "w+"); printf("The size of file is: %d bytes", size); inc = size/(1024*100); while (cgiFormFileRead(file, b, sizeof(b), &got_count) == cgiFormSuccess) { fwrite(b,sizeof(char),got_count,output); i++; if(i == inc && j<=100) { ***inc_pb*** = j; i = 0; j++; // j is the progress bar increment value } } cgiFormFileClose(file); retval = system("mkdir /tmp/update-tmp;\ cd /tmp/update-tmp;\ tar -xzf ../cgi.tar.gz;\ bash -c /tmp/update-tmp/update.sh"); However, this doesn't work the way as is seen above. Instead of printing 1,2,...100 to progress_bar.txt one by one it prints at ONE GO, seems it buffers and then writes to the file. fflush() also didn't work. Any clue/suggestion would be really appreciated.

    Read the article

  • How do I do a postback to a CGI service

    - by TheLearner
    I am building a C# client for a CGI service (not sure what its called exactly). It accepts a bunch of XML and spits out a response. I have tested it straight in Firefox and it works (see below). Now I am not sure how to do this in C# code though? Does anyone have a helpful snippet of code, I can't imagine it would be that difficult? http://www.travelcommunications.co.uk/cgi-bin/d3web_gzip.ssh?%3CTCOML%20version=%22NEWFORMAT%22%3E%3CTransferOnly%3E%3CAvailability%3E%3CRequest%3E%3CAgentCode%3ETEST%3C/AgentCode%3E%3CAgentType%3ETA%3C/AgentType%3E%3CDeparturePointCode%3EALC%3C/DeparturePointCode%3E%3CDeparturePointType%3EAIRPORT%3C/DeparturePointType%3E%3CArrivalPointCode%3EBEN%3C/ArrivalPointCode%3E%3CArrivalPointType%3ERESORT%3C/ArrivalPointType%3E%3CSectorType%3ERETURN%3C/SectorType%3E%3CArrDate%3E10.10.10%3C/ArrDate%3E%3CArrTime%3E10:00%3C/ArrTime%3E%3CRetDate%3E17.10.10%3C/RetDate%3E%3CRetTime%3E10:00%3C/RetTime%3E%3CBrochure%3E001%3C/Brochure%3E%3CAdults%3E2%3C/Adults%3E%3CChildren%3E0%3C/Children%3E%3CInfants%3E0%3C/Infants%3E%3CCurrencyCode%3EUKL%3C/CurrencyCode%3E%3C/Request%3E%3C/Availability%3E%3C/TransferOnly%3E%3C/TCOML%3E

    Read the article

  • How do you run a uncompiled CGI?

    - by Toast
    I'm going to get right to it. iPage shared hosting. Trying to use mimetex.cgi to render math. Source code is at the link. After preparing everything just as I had with a different shared host (which worked), I get errors. Tech support tells me I need to upload the uncompiled source and use that instead. ??? Rather than going with them just being ignorant and wrong, I'm going to assume I'm missing something. How am I supposed to execute and make use of the uncompiled source code? What the hell is wrong with a hosting service that doesn't support running compiled CGI written in C (as far as I can tell)?

    Read the article

  • Stopping httpd causes a process started from perl CGI script to receive SIGTERM

    - by Pranav Pal
    I am running a shell script from a perl CGI script: #!/usr/bin/perl my $command = "./script.sh &"; my $pid = fork(); if (defined($pid) && $pid==0) { # background process system( $command ); } The shell script looks like this: #!/bin/sh trap 'echo trapped' 15 tail -f test.log When I run the CGI script from browser, and then stop httpd using /etc/init.d/httpd stop, the script receives a SIGTERM signal. I was expecting the script to run as a separate process and not be tied in anyway to httpd. Though I can trap the SIGTERM, I would like to understand why the script is receiving SIGTERM at all. What wrong am I doing here? I am running RHEL 5.8 and Apache HTTP server 2.4. Thanks, Pranav

    Read the article

  • Limit calls to external database with Python CGI

    - by Matt Ball
    I've got a Python CGI script that pulls data from a GPS service; I'd like this information to be updated on the webpage about once every 10s (the max allowed by the GPS service's TOS). But there could be, say, 100 users viewing the webpage at once, all calling the script. I think the users' scripts need to grab data from a buffer page that itself only upates once every ten seconds. How can I make this buffer page auto-update if there's no one directly viewing the content (and not accessing the CGI)? Are there better ways to accomplish this?

    Read the article

  • 404 Not Found for a PL script that exists!

    - by Abs
    Hello all, I make a GET request to a CGI script and I get a 404 error. However, I am 100% sure that script is present and it has permissions: -rwxr-xr-x 1 apache apache 6520 Sep 7 03:01 uu_ini_status_audios.pl The request URL is: http://mysite.com/cgi-bin/uu_ini_status_audios.pl?tmp_sid=893facacc5dc392ad0f4c91e6a9e8d40&rnd_id=0.12266222834382812 The error I get: The requested URL /cgi-bin/uu_ini_status_audios.pl was not found on this server. This use to work for me before, but I think it stopped working after I restarted apache so maybe it means its a configuration I changed?? I checked the error logs for apache and php and nothing useful was found to help me with my problem! I appreciate any help on this!

    Read the article

  • configuring cgi-bin using .htaccess

    - by Alexandru
    I'm trying to configure a directory as cgi-bin using .htaccess, but when I try to access the executables, the files are downloaded. I'm using apache2.2. What is the problem? My .htaccess looks like: # cat www/cgi-bin/.htaccess Options +ExecCGI AddHandler cgi-script cgi pl File permissions are # ls -1la www/cgi-bin/ total 60 drwxr-xr-x 2 root root 4096 iun 10 19:22 . drwxr-xr-x 5 root root 4096 iun 10 19:18 .. -rw-r--r-- 1 root root 46 iun 10 19:23 .htaccess -rwxr-xr-x 1 root root 15358 iun 10 19:23 paperload.cgi -rwxr-xr-x 1 root root 12728 iun 10 19:23 papers.cgi -rwxr-xr-x 1 root root 12593 iun 10 19:23 paperview.cgi

    Read the article

  • How to Implement Grep into CGI script Please?

    - by Joey jie
    Hi all! I am having difficulty figuring out how to implement grep into my CGI script. Basically I will receive a value of eg. 1500 from a HTML page. The CGI script then runs and compares 1500 to a text file. When it finds 1500 it prints the entire line and displays it on the webpage. I would like some tips and pointers on how to do this please. I understand that this involves grep but I don't really know how to put it in. #include <stdio.h> #include <stdlib.h> int main(void) { char *data; long m,n; printf("%s%c%c\n", "Content-Type:text/html;charset=iso-8859-1",13,10); printf("<TITLE>Webpage of Results</TITLE>\n"); printf("<H1>Temperatures</H1>\n"); data = getenv("QUERY_STRING"); The HTML passes the variable time=1500. I understand (correct me if I am wrong) that QUERY_STRING will contain 1500?

    Read the article

  • How to include frameset under CGI.pm

    - by neversaint
    I want to have a cgi-script that does two things. Take the input from a form. Generate results base on the input values on a frame. Primarily I want the frame exist only after the results is generated/printed. Below is the simplified code of what I want to do. But somehow it doesn't work. What's the right way to do it? #!/usr/local/bin/perl use CGI ':standard'; print header; print start_html('A Simple Example'), h1('A Simple Example'), start_form, "What's your name? ",textfield('name'), p, "What's the combination?", p, checkbox_group(-name=>'words', -values=>['eenie','meenie','minie','moe'], -defaults=>['eenie','minie']), p, "What's your favorite color? ", popup_menu(-name=>'color', -values=>['red','green','blue','chartreuse']), p, submit, end_form, hr; if (param()) { # begin create the frame print <<EOF; <html><head><title>$TITLE</title></head> <frameset rows="10,90"> <frame src="$script_name/query" name="query"> <frame src="$script_name/response" name="response"> </frameset> EOF # Finish creating frame print "Your name is: ",em(param('name')), p, "The keywords are: ",em(join(", ",param('words'))), p, "Your favorite color is: ",em(param('color')), hr; } print end_html;

    Read the article

  • Simple CGI server

    - by Egor Makarov
    How can I run my perl CGI script without apache? This is for testing purposes, so some kind of single-process server that processes only one request at time should be enough for me.

    Read the article

  • collecting a "+" via CGI

    - by Dr.Dredel
    I'm collecting text through a web form and noticing that when it is collected by my PERL CGI all instances of "+" are transformed into " ". I run the text through a javascript escape before submission, but escape seems to leave + unaltered. There must be something really obvious that I'm missing... how do I send the string "2 + 2 = 4" through and not have it arrive as "2 2 = 4" ??

    Read the article

  • Passwordless SSH using cgi-perl script

    - by AV
    Hello, This is my first shot at trying out cgi-perl scripts. I have SSH keys set up between my (root user) local machine and a remote machine. I'm trying to run a command on the remote box and display the output on a webpage hosted from my local machine. The script runs fine from command line however, it throws SSH key error when called from the webpage because the user running the script is apache and not root. Is there a way to get around this issue?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >