Search Results

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

Page 10/55 | < Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >

  • Firing through HTTP a Perl script for sending signals to daemons

    - by Eric Fortis
    Hello guys, I'm using apache2 on Ubuntu. I have a Perl script which basically read the files names of a directory, then rewrites a text file, then sends a signal to a daemon. How can this be done, as secure as possible through a web-page? Actually I can run the code below, but not if I remove the comments. I'm looking for advise considering: Using HTTP Requests? How about Apache file permissions on the directory shown in code? Is htaccess enough to enable user/pass access to the cgi? Should I use a database instead of writing to a file and run a cron querying the db with permission granted to write and send the signal? Granting as less permissions as possible to the webserver. Should I set a VPN? #!/usr/bin/perl -wT use strict; use CGI; #@fileList = </home/user/*>; #read a directory listing my $query = CGI->new(); print $query->header( "text/html" ), $query->p( "FirstFileNameInArray" ), #$query->p( $fileList[0] ), #output the first file in directory $query->end_html;

    Read the article

  • Problem making system calls with PHP scripts

    - by mazin k.
    I have the following PHP script: <?php $fortune = `fortune`; echo $fortune; ?> but the output is simply blank (no visible errors thrown). However, if I run php -a, it works: php > echo `fortune`; Be careful of reading health books, you might die of a misprint. -- Mark Twain php > Am I missing a config directive or something that would cause this? Edit: So, I tried running my script using $ php-cgi fortunetest.php and it worked as expected. Maybe the issue is with Apache2?

    Read the article

  • Generate TFTP Content on the fly?

    - by andyortlieb
    I know this isn't the purpose of TFTP, but I'm working in an environment where a lot of different types of devices pull provisioning info from a TFTP server. What I'm developing is a provisioning system that tracks and maintains device configurations, and I would like to have the requested files generated on the fly, much like you could do with any web application. Yes some of these devices can support HTTP for provisioning, but not all of them do, and we want things to be consistent. Are there any TFTP daemons that can provide something analogous to CGI?

    Read the article

  • Temporarily Utilizing 304 Header on Apache for Crawlers

    - by Volomike
    I have a client who has a hosting arrangement with 400 customer sites all hosted through SuPHP in CGI mode on Apache. The sysop is now gone and the client is calling on me for rolling out a new PHP thing. Trouble is -- server load is very high right now and we have found that it's due to the crawlers. We had one customer in particular who complained of slow websites, and we engaged a 304 header plugin in his site against most crawlers, and his site perked right up. We'd like to lower that load by issuing a global 304 header to all the crawlers, letting human visitors through. I have a long list of user agent keywords to trap for. What's the best way to temporarily engage that global 304 header, while allowing human visitors to get right on through? I mean, I could roll out 400 .htaccess file changes, but it would be ideal to make this change in like one central Apache config and then it automatically affect all the sites at once.

    Read the article

  • Wordpress multisite and redirect

    - by Dr I
    I come to you because I'm facing a really strange effect on my hosting. I currently manage a server contening a NGINX/PHP-CGI and a wordpress multisite in it. My sites are created using subsite.domaine.tld, for now, my three subsites are correctly accessibles through the url: subsite.domain.tld. My goal is to allow my subsite on the host domain to be access through their respective unique domain. For exemple: www.domainA.com would redirect to subsite1.host.domain.tld. If I do that using the following setting on the domainA Public DNS: www 10800 IN CNAME subsite1.host.domain.tld. When I try to access www.domainA.com I don't go to subsite1.host.domain.tld but instead I'm redirect to the Wordpress ROOT site where I create my Network (host.domain.tld). Is there a trick to deal with?

    Read the article

  • iis php internal server error

    - by user1633206
    I developed a website, using php/mysql running at IIS Server as CGI Server API. Suddenly it gives me error 500 after two weeks. It has lot of scripts but index.php home is working. But other script that has header redirection What's wrong with my scripts. livehttp addon of firefox says.. GET /allplans.php?lang=ar&cat=1 HTTP/1.1 Host: www.myhost.com... [edited] User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip, deflate Connection: keep-alive Cache-Control: max-age=0 HTTP/1.1 500 Internal Server Error Content-Type: text/html Server: Microsoft-IIS/7.5 X-Powered-By: ASP.NET Date: Mon, 03 Sep 2012 08:09:13 GMT Content-Length: 1208 Connection: Keep-Alive

    Read the article

  • Why doesnt file uploads work for a specific customer?

    - by nimo9367
    We have for some time now experienced some unexplainable behavior when a certain customer is trying to upload files to our web based application using a standard web form. It's a CGI based application and the server is running IIS6. However it works fine for all of our other customers using the same server and application so this must be a client side related issue? The request basically times out and you get to "page cannot be displayed". Does anyone have any idea of what might be the source of this problem?

    Read the article

  • Setting the server to look for index.php file by default

    - by ????? ???????
    I am a web developer and I've requested our Sys-Admin to setup a server for my team that will be used as a development environment. The PHP is running as a CGI. When i try to open http://myaddress/ I receive 403 Forbidden. When I try to open http://myaddress/index.php everything is fine. How do I set the server to look for index.php file by default? P.S The sysadmin is not currently here, so he cannot do it for me.

    Read the article

  • Should I use .pl or .cgi for Perl web script files?

    - by Nano HE
    HI. I created two files 'hello.pl' and 'hello.cgi' with the code below. #!/usr/bin/perl print "Content-type:text/html\n\n"; print "hello world"; I can view the page via both http://www.mydomain.com/cgi-bin/hello.pl and http://www.mydomain.com/cgi-bin/hello.cgi. Which one is more sense in Perl web dev? BTW, the directory of 'cgi-bin' created by my VPS server, Do I need contact with my VPS support to remove it or just remain it like this URL style? Maybe http://www.mydomain.com/perDev/hello.cgi is better?

    Read the article

  • .pl or .cgi for perl web script file,which one is more popular?

    - by Nano HE
    HI. I created two files 'hello.pl' and 'hello.cgi' with the code below. #!/usr/bin/perl print "Content-type:text/html\n\n"; print "hello world"; I can view the page via both http://www.mydomain.com/cgi-bin/hello.pl and http://www.mydomain.com/cgi-bin/hello.cgi. Which one is more sense in Perl web dev? BTW, the directory of 'cgi-bin' created by my VPS server, Do I need contact with my VPS support to remove it or just remain it like this URL style? Maybe http://www.mydomain.com/perDev/hello.cgi is better?

    Read the article

  • PHP to C/C++ through CGI script

    - by Peterim
    Hi guys! I realize it's probably something strange, but here is what I have. I have an application (handwriting recognition engine) written in C/C++. This application has Perl wrapper which was made by application's authors using SWIG. My website is written in PHP, so I'm looking for some ways to make PHP work with C/C++ application. The only way I can think of now is to create a CGI script (perl script) which accepts POST request from my website (AJAX request), sends it to the recognition engine through it's Perl wrapper, gets the required data and returns the required data as a response to AJAX request. Do you think it could be done this way? Are there any better solutions? Thank you!

    Read the article

  • Perl: getting handle for stdin to be used in cgi-bin script

    - by Daniel
    Using perl 5.8.8 on windows server I am writing a perl cgi script using Archive::Zip with to create on fly a zip that must be download by users: no issues on that side. The zip is managed in memory, no physical file is written to disk using temporary files or whatever. I am wondering how to allow zip downloading writing the stream to the browser. What I have done is something like: binmode (STDOUT); $zip->writeToFileHandle(*STDOUT, 0); but i feel insecure about this way to get the STDOUT as file handle. Is it correct and robust? There is a better way? Many thanks for your advices

    Read the article

  • How to redirect on apache after running a script through cgi

    - by Yotam
    I have an ubuntu machine which I have installed apache on. I want to use a web page to run some simple shell script through cgi and then go back to my home screen. I also want to the go-back step to be automatic. I have set a redirect in my apache.conf which works fine but the script doesn't run at all. Is there a way to run the script and only then apply the redirect? Comment: I think this may be the answer but I'm not sure.

    Read the article

  • Python script to get the datas from the flex application

    - by nimmyliji
    Hi, I am making a simple Python CGI script that collects data(in xml format) from a flex application and I want to insert it into the mysql database . In perl The script is looks like the following... my @samplexml=$cgi-param("Items"); my $data=$xml-XMLin("@samplexml"); foreach my $e(@{$data-{Group}}) { my $sample="Insert into details(title,Parent,Istreeitem) Values('$e-{title}','$e-{Parent}','$e-{IsTreeItem}')"; my $sam=$dbo-prepare($sample); $sam-execute(); } But I want to know how to write these codes in pytrhon script.... Any one can help me? Thanks in advance. Nimmy.

    Read the article

  • Python script to get the data from the flex application

    - by nimmyliji
    Hi, I am making a simple Python CGI script that collects data(in xml format) from a flex application and I want to insert it into the mysql database . In perl The script is looks like the following... my @samplexml=$cgi->param("Items"); my $data=$xml->XMLin("@samplexml"); foreach my $e(@{$data->{Group}}) { my $sample="Insert into details(title,Parent,Istreeitem) Values('$e->{title}','$e->{Parent}','$e->{IsTreeItem}')"; my $sam=$dbo->prepare($sample); $sam->execute(); } But I want to know how to write these codes in pytrhon script.... Any one can help me? Thanks in advance. Nimmy.

    Read the article

  • Perl Catalyst -- Is this helpful to use for images/graphs display

    - by Octopus
    I have simple perl/cgi scripts based web server which is mainly used to display graphs and Images. I am looking to make it more technical and come to know about Catalyst. I have installed all the required perl modules on my test platform and created an application called myweb. Also, I am going through the catalyst documents to reach my goal but nothing helpful yet. Is Catalyst helpful to display images/graphs on web? How to use my existing cgi/perl scritps with Catalyst? Any example would be really appreciated.

    Read the article

  • Are fopen/fread/fgets PID-safe in C ?

    - by Jane
    Various users are browsing through a website 100% programmed in C (CGI). Each webpage uses fopen/fgets/fread to read common data (like navigation bars) from files. Would each call to fopen/fgets/fread interefere with each other if various people are browsing the same page ? If so, how can this be solved in C ? (This is a Linux server, compiling is done with gcc and this is for a CGI website programmed in C.) Example: FILE *DATAFILE = fopen(PATH, "r"); if ( DATAFILE != NULL ) { while ( fgets( LINE, BUFFER, DATAFILE ) ) { /* do something */ } }

    Read the article

  • Ajax based progress bar

    - by Punit
    I am developing a progress bar using Ajax. My client side code is working fine, but I have issue at server side. I am using C based CGI. if(i == inc && pb_inc<=100) { fptr = fopen("progress_bar.txt", "w"); fprintf(fptr,"%d", j); fclose(fptr); pb_inc++; } basically I am increasing progress bar after certain number of bytes. What I see here is that the CGI doesn't let display any data to text file until it has sent all the data to file one by one. i have referred to http://www.redips.net/javascript/ajax-progress-bar/ Any idea whats happening here?

    Read the article

  • Can I use Catalyst to display images or graphs?

    - by Octopus
    I have simple Perl/CGI scripts based web server which is mainly used to display graphs and images. I am looking to make it more technical and come to know about Catalyst. I have installed all the required Perl modules on my test platform and created an application called myweb. Also, I am going through the Catalyst documents to reach my goal but nothing helpful yet. Is Catalyst helpful to display images/graphs on web? How can I use my existing CGI/Perl scritps with Catalyst? Any example would be really appreciated.

    Read the article

  • interactive login on cgi script

    - by raindrop18
    I am new for perl-cgi script. and my objective is to create user/pass interactive script to log and get information from multiple device at once. instead of add the user/pass credential on the script itself. since i am new if some one show me how to write the interactive part of the script. thanks much!!! here is the current code usr/local/bin/perl -wl use CGI ':standard'; use Net::Telnet::Cisco; ### set the error fields to nulls $selerror = ""; ### Input from the screen - make sure data was input if (param() and param('Switches') ne "" and (param('Mac') ne "" or param('Interface Description') ne "" or param('VLAN') ne "" )) { ### Put the input devices into an array. @devices = param('Switches'); ### format the header data print header(); print start_html(-title=>"ShowSwitches",-BGCOLOR=>'aqua'); print "\n",h1("<CENTER>Show Switches</CENTER>"); print "\n",hr(),"\n"; ### Go thru the device array. foreach(@devices) { $error_msg = ""; $TAC_login_error = ""; $open_error = ""; $retry_open_error = ""; $prompt_error = ""; $password_error = ""; ### Take input host and use to send to Telnet $host = $_; $session = Net::Telnet::Cisco->new(Errmode => 'return', Timeout => 30); ### Connect to the host $session->open(Host =>"$host", Timeout => 15); $open_error = $session->errmsg; ### Login with TACACS if host can be connected to if ($open_error eq "") { $session->login('USER', 'PASS'); $TAC_login_error = $session->errmsg; ### Login with TACACS failed - try standard login if ($TAC_login_error ne "") { ### Connect to host $session->open(Host =>"$host", Timeout => 15); $retry_open_error = $session->errmsg; ### Wait for password prompt - multiple matches - devices may have different device prompts. if ($retry_open_error eq "") { $session->waitfor(Match => '/Password:.*$/', Match => '/Enter password:.*$/', Timeout => 20); $prompt_error = $session->errmsg; if ($prompt_error eq "") { ### Input password $session->print('getmeout'); $password_error = $session->errmsg; $session->waitfor('/.*>$/'); $password_error = $session->errmsg; } } } } ### No errors, then issue "show commands". if ($open_error eq "" and ($TAC_login_error eq "" or $retry_open_error eq "") and $prompt_error eq "" and $password_error eq "") { ### Show Mac if (param('Mac')) { $cmd = 'sh mac'; @output = $session->cmd("$cmd"); $show_error = ""; $show_error = $session->errmsg; print "\n",h2($host . ' - ' . $cmd); if ($show_error ne "") { $error_msg = 'Error for show mac - ' . $show_error; print b($error_msg),(br); print hr(),"\n"; $error_msg = ''; } else { print pre(@output); print hr(),"\n"; } } ### Show Interface Description if (param('Interface Description')) { $cmd = 'sh interface description'; @output = $session->cmd("$cmd"); $show_error = ""; $show_error = $session->errmsg; print "\n",h2($host . ' - ' . $cmd); if ($show_error ne "") { $error_msg = 'Error for show mac - ' . $show_error; print b($error_msg),(br); print hr(),"\n"; $error_msg = ''; } else { print pre(@output); print hr(),"\n"; } } ### Show VLAN if (param('VLAN')) { $cmd = 'sh vlan'; @output = $session->cmd("$cmd"); $show_error = ""; $show_error = $session->errmsg; print "\n",h2($host . ' - ' . $cmd); if ($show_error ne "") { $error_msg = 'Error for show vlan - ' . $show_error; print b($error_msg),(br); print hr(),"\n"; $error_msg = ''; } else { print pre(@output); print hr(),"\n"; } } } elsif ($TAC_login_error ne "" and $password_error ne "") { $error_msg = "Error - $host " . $TAC_login_error . ' - possible incorrect TACACS or standard password parameters on device.'; } elsif ($open_error ne "") { $error_msg = "Error - $host " . $open_error . ' - cannot connect to host - is it down??'; } elsif ($prompt_error ne "") { $error_msg = "Error - $host " . $prompt_error . ' - password prompt not recognized - invalid TACACS (or user) password.'; } elsif ($password_error ne "") { $error_msg = "Error - $host " . $password_error . ' - possible incorrect user/password parameters on device.'; } if ($error_msg ne "" ) { print b($error_msg),(br); print hr(),"\n"; } print hr(),"\n"; print end_html(),"\n"; } } else { ### No Show command was selected. if (param('Submit') and param('Mac') eq "" and param('Interface Description') eq "" and param('VLAN') eq "" ) { $selerror = 'No Show Displays were selected. Try again please!!'; } elsif ### No switch was selected. (param('Submit') and param('Switches') eq "") { $selerror = 'No devices were selected. Try again please!!'; } ### This formats the initial Show Web page. print header(-Pragma='no-cache'), start_html(-title=>"Show Displays",-BGCOLOR=>'aqua'), h1("<CENTER>Show Switches</CENTER>"),hr(), start_form(), b("Select Show Commands:"), br(), br(), checkbox(-name=>'Mac'), checkbox(-name=>'Interface Description'), checkbox(-name=>'VLAN'), br(),br(),hr(),br(), b("Select One or More Devices:"), br(), br(), scrolling_list (-name => 'Switches', -default=> "NONE", -values => ['cs6a', 'cs7a', 'cs7b', 'cs8b', 'cs9a', 'c9b', 'csa' ], -multiple => 'true', -size => 7, ), p(submit('Submit'),reset('Reset')), b($selerror), end_form(),hr(), end_html(); } #

    Read the article

  • interactive login on perl cgi script- updated question [closed]

    - by raindrop18
    I am new for perl-cgi script. and my objective is to create user/pass interactive script to log and get information from multiple device at once. instead of add the user/pass credential on the script itself. since i am new if some one show me how to write the interactive part of the script. thanks much!!! here is the current code usr/local/bin/perl -wl use CGI ':standard'; use Net::Telnet::Cisco; # ### set the error fields to nulls $selerror = ""; # ### Input from the screen - make sure data was input if (param() and param('Switches') ne "" and (param('Mac') ne "" or param('Interface Description') ne "" or param('VLAN') ne "" )) { # ### Put the input devices into an array. @devices = param('Switches'); # ### format the header data print header(); print start_html(-title=>"ShowSwitches",-BGCOLOR=>'aqua'); print "\n",h1("<CENTER>Show Switches</CENTER>"); print "\n",hr(),"\n"; # ### Go thru the device array. foreach(@devices) { $error_msg = ""; $TAC_login_error = ""; $open_error = ""; $retry_open_error = ""; $prompt_error = ""; $password_error = ""; # ### Take input host and use to send to Telnet $host = $_; $session = Net::Telnet::Cisco->new(Errmode => 'return', Timeout => 30); # ### Connect to the host $session->open(Host =>"$host", Timeout => 15); $open_error = $session->errmsg; # ### Login with TACACS if host can be connected to if ($open_error eq "") { $session->login('USER', 'PASS'); $TAC_login_error = $session->errmsg; # ### Login with TACACS failed - try standard login if ($TAC_login_error ne "") { # ### Connect to host $session->open(Host =>"$host", Timeout => 15); $retry_open_error = $session->errmsg; # ### Wait for password prompt - multiple matches - devices may have different device prompts. if ($retry_open_error eq "") { $session->waitfor(Match => '/Password:.*$/', Match => '/Enter password:.*$/', Timeout => 20); $prompt_error = $session->errmsg; if ($prompt_error eq "") { # ### Input password $session->print('getmeout'); $password_error = $session->errmsg; $session->waitfor('/.*>$/'); $password_error = $session->errmsg; } } } } # ### No errors, then issue "show commands". if ($open_error eq "" and ($TAC_login_error eq "" or $retry_open_error eq "") and $prompt_error eq "" and $password_error eq "") { # ### Show Mac if (param('Mac')) { $cmd = 'sh mac'; @output = $session->cmd("$cmd"); $show_error = ""; $show_error = $session->errmsg; print "\n",h2($host . ' - ' . $cmd); if ($show_error ne "") { $error_msg = 'Error for show mac - ' . $show_error; print b($error_msg),(br); print hr(),"\n"; $error_msg = ''; } else { print pre(@output); print hr(),"\n"; } } # ### Show Interface Description if (param('Interface Description')) { $cmd = 'sh interface description'; @output = $session->cmd("$cmd"); $show_error = ""; $show_error = $session->errmsg; print "\n",h2($host . ' - ' . $cmd); if ($show_error ne "") { $error_msg = 'Error for show mac - ' . $show_error; print b($error_msg),(br); print hr(),"\n"; $error_msg = ''; } else { print pre(@output); print hr(),"\n"; } } # ### Show VLAN if (param('VLAN')) { $cmd = 'sh vlan'; @output = $session->cmd("$cmd"); $show_error = ""; $show_error = $session->errmsg; print "\n",h2($host . ' - ' . $cmd); if ($show_error ne "") { $error_msg = 'Error for show vlan - ' . $show_error; print b($error_msg),(br); print hr(),"\n"; $error_msg = ''; } else { print pre(@output); print hr(),"\n"; } } } elsif ($TAC_login_error ne "" and $password_error ne "") { $error_msg = "Error - $host " . $TAC_login_error . ' - possible incorrect TACACS or standard password parameters on device.'; } elsif ($open_error ne "") { $error_msg = "Error - $host " . $open_error . ' - cannot connect to host - is it down??'; } elsif ($prompt_error ne "") { $error_msg = "Error - $host " . $prompt_error . ' - password prompt not recognized - invalid TACACS (or user) password.'; } elsif ($password_error ne "") { $error_msg = "Error - $host " . $password_error . ' - possible incorrect user/password parameters on device.'; } if ($error_msg ne "" ) { print b($error_msg),(br); print hr(),"\n"; } print hr(),"\n"; print end_html(),"\n"; } } else { # ### No Show command was selected. if (param('Submit') and param('Mac') eq "" and param('Interface Description') eq "" and param('VLAN') eq "" ) { $selerror = 'No Show Displays were selected. Try again please!!'; } elsif # ### No switch was selected. (param('Submit') and param('Switches') eq "") { $selerror = 'No devices were selected. Try again please!!'; } # ### This formats the initial Show Web page. print header(-Pragma=>'no-cache'), start_html(-title=>"Show Displays",-BGCOLOR=>'aqua'), h1("<CENTER>Show Switches</CENTER>"),hr(), start_form(), b("Select Show Commands:"), br(), br(), checkbox(-name=>'Mac'), checkbox(-name=>'Interface Description'), checkbox(-name=>'VLAN'), br(),br(),hr(),br(), b("Select One or More Devices:"), br(), br(), scrolling_list (-name => 'Switches', -default=> "NONE", -values => ['cs6a', 'cs7a', 'cs7b', 'cs8b', 'cs9a', 'c9b', 'csa' ], -multiple => 'true', -size => 7, ), p(submit('Submit'),reset('Reset')), b($selerror), end_form(),hr(), end_html(); } #

    Read the article

  • Getting the responseText from XMLHttpRequest-Object

    - by Sammy46
    I wrote a cgi-script with c++ to return the query-string back to the requesting ajax object. I also write the query-string in a file in order to see if the cgi script works correctly. But when I ask in the html document for the response Text to be shown in a messagebox i get a blank message. here is my code: js: <script type = "text/javascript"> var XMLHttp; if(navigator.appName == "Microsoft Internet Explorer") { XMLHttp = new ActiveXObject("Microsoft.XMLHTTP"); } else { XMLHttp = new XMLHttpRequest(); } function getresponse () { XMLHttp.open ("GET", "http://localhost/cgi-bin/AJAXTest?" + "fname=" + document.getElementById('fname').value + "&sname=" + document.getElementById('sname').value,true); XMLHttp.send(null); } XMLHttp.onreadystatechange=function(){ if(XMLHttp.readyState == 4) { document.getElementById('response_area').innerHTML += XMLHttp.readyState; var x= XMLHttp.responseText alert(x) } } </script> First Names(s)<input onkeydown = "javascript: getresponse ()" id="fname" name="name"> <br> Surname<input onkeydown = "javascript: getresponse();" id="sname"> <div id = "response_area"> </div> C++: int main() { QFile log("log.txt"); if(!log.open(QIODevice::WriteOnly | QIODevice::Text)) { return 1; } QTextStream outLog(&log); QString QUERY_STRING= getenv("QUERY_STRING"); //if(QUERY_STRING!=NULL) //{ cout<<"Content-type: text/plain\n\n" <<"The Query String is: " << QUERY_STRING.toStdString()<< "\n"; outLog<<"Content-type: text/plain\n\n" <<"The Query String is: " <<QUERY_STRING<<endl; //} return 0; } I'm happy about every advice what to do! EDIT: the output to my logfile works just fine: Content-type: text/plain The Query String is: fname=hello&sname=world I just noticed that if i open it with IE8 i get the query-string. But only on the first "keydown" after that IE does nothing.

    Read the article

  • I can't upload a file with CGIHTTPServer

    - by sdemingo
    Hi all, I'm using the CGIHTTPServer to implement a simple cgi server. I'm trying to upload a file by a form with the post method and the multipart/form-data enctype but I have problems when I recover the value of the fields in the cgi script. When the script catch the form fields, the value of the file is a MiniFieldStorage with two fields only (key and file name), and I can't recover the content of the file. As the API doc shows, this content is in value field of a StorageField but in the MiniFieldStorage this field isn't exits. ¿How can I recover a StorageField with the content of the file instead a MiniStorageField? ¿There are other method to upload a file using CGIHTTPServer? Thanks a lot

    Read the article

  • What's the fastest way to get CRUD over CGI on a database handle in Perl?

    - by mithaldu
    TL;DR: Want to write CGI::CRUD::Simple (a minimalist interface module for CGI::CRUD), but I want to check first if i overlooked a module that already does that. I usually work with applications that don't have the niceties of having frameworks and such already in place. However, a while ago i found myself in a situation where i was asking myself: "Self, i have a DBI database handle and a CGI query object, isn't there a module somewhere that can use this to give me some CRUD so i can move on and work on other things instead of spending hours writing an interface?" A quick survey on CPAN gave me: CGI::Crud Catalyst::Plugin::CRUD Gantry::Plugins::CRUD Jifty::View::Declare::CRUD CatalystX::CRUD Catalyst::Controller::CRUD CatalystX::CRUD::REST Catalyst::Enzyme Now, I didn't go particularly in-depth when looking at these modules, but, safe the first one, they all seem to require the presence of some sort of framework. Please tell me if i was wrong and i can just plug any of those into a barebones CGI script. CGI::CRUD seemed to do exactly what i wanted, although it did insist on being used through a rather old and C-like script that must be acquired on a different site and then prodded in various ways and manners to produce something useful. I went with that and found that it works pretty neat and that it should be rather easy to write a simple and easy-to-use module that provides a very basic [dbh, cgi IN]-[html OUT] interface to it. However, as my previous survey was rather short and i may have been hasty in dismissing modules or missed others, i find myself wondering whether that would only be duplication of work already done. As such i ponder the question in the title. PS: I tend to be too short in some of my explanations and make too many assumptions that others think about things similarly as me, resulting in leaving out critical details. If you find yourself wondering just what exactly I am thinking about when i say CRUD, please poke me in comments and I'll amend the question.

    Read the article

< Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >