RE: mc & cgi: limiting users to one visit
Merci, Monsieur Sahores, Couple more questions if you don't mind... 1) Do you know of any current web applications running using MC-cgi? 2) What is "long running process" - is it a compiled MC app which acts as a server and is already loaded in memory on the server? 3) Can MC run on NT or 2000 as a cgi? If so, do you know where I can find info on how to set it up? I would like to run it on my laptop for building web apps, and then port to a Linux server. 4) What do you mean by "use PHP as one of the best MC apps compliant sockets listener." and some help if you like: Chris and I have created a stack called "altSAFileUp Library" which enables users to upload files via the to a server. If you have an MC client app and wish to upload a file to a server, you can use this library to do so. It creates the correct headers for all the form data on a page, including multiple files, and uploads them in binary mode to the server. While I've only tested it with the SAFileUp control, it should work with any other server file upload controls on Mac, PC and Linux. Use it if you like. -Chipp -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Pierre Sahores Sent: Monday, January 21, 2002 4:25 PM To: [EMAIL PROTECTED] Subject: Re: mc & cgi: limiting users to one visit Chipp Walters a écrit : > > Andu, > > Quick question. Have you done any speed/load tests using MC-cgi vs PHP or > ASP? Can one consider MC-cgi a robust, web-application development tool like > ASP and PHP? I know it doesn't do inline scripting like ASP and PHP, but I > was wondering if I could use it on a Windows System for building small web > apps. > > thx, > > Chipp Walters > > ___ > metacard mailing list > [EMAIL PROTECTED] > http://lists.runrev.com/mailman/listinfo/metacard Hi Chipp, MC is a perfect tool to build web applications and to link flat-files and sql-based databases to the internet (My prefered tools : PostGreSQL as the db, SQLBoss 1.1 as the db designing ide, PHP4 as the gateway between the MC "POST" queries and the PostGreSQL replies). I'm using MC (2.32 for yet) in this way since about the last tree years. I'm spending some time to build an example stack but it's not out for yet. In between the far "marketed dead" ColdFusion and the J2EE based web apps servers, MC is, at least, a "must know how to do with it" web development tool. About speed : using, last year, the same PII 300 laptop to run the same end-user app under WinNT4 SP5 and Suse-Linux 6.x, i founded that the ASP2 drived app was 4 times many slower on the NT platform than the PHP 3.0.16 same drived app on the Suse platform. The MC 2.32 issue of the same app is always many faster than the PHP3 issue is, on both the WinNT and the Suse platform. The difference will grow more and more with the length of the scripts to run : with small scripts, no big diffrence in speed between MC and PHP ; with long scripts, MC will be up to 100 times faster than PHP3 and 75 time faster than PHP4. You will find in the list archive ways to handle MC based web apps as long running processes. Don't forget that you can, if needed, use PHP as one of the best MC apps compliant sockets listener. Have fun. Regards, Pierre Sahores WEB & VPN applications & databases servers Inspection académique de Seine-Saint-Denis Qualifier & produire l'avantage compétitif ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: mc & cgi: limiting users to one visit
Chipp Walters a écrit : > > Andu, > > Quick question. Have you done any speed/load tests using MC-cgi vs PHP or > ASP? Can one consider MC-cgi a robust, web-application development tool like > ASP and PHP? I know it doesn't do inline scripting like ASP and PHP, but I > was wondering if I could use it on a Windows System for building small web > apps. > > thx, > > Chipp Walters > > ___ > metacard mailing list > [EMAIL PROTECTED] > http://lists.runrev.com/mailman/listinfo/metacard Hi Chipp, MC is a perfect tool to build web applications and to link flat-files and sql-based databases to the internet (My prefered tools : PostGreSQL as the db, SQLBoss 1.1 as the db designing ide, PHP4 as the gateway between the MC "POST" queries and the PostGreSQL replies). I'm using MC (2.32 for yet) in this way since about the last tree years. I'm spending some time to build an example stack but it's not out for yet. In between the far "marketed dead" ColdFusion and the J2EE based web apps servers, MC is, at least, a "must know how to do with it" web development tool. About speed : using, last year, the same PII 300 laptop to run the same end-user app under WinNT4 SP5 and Suse-Linux 6.x, i founded that the ASP2 drived app was 4 times many slower on the NT platform than the PHP 3.0.16 same drived app on the Suse platform. The MC 2.32 issue of the same app is always many faster than the PHP3 issue is, on both the WinNT and the Suse platform. The difference will grow more and more with the length of the scripts to run : with small scripts, no big diffrence in speed between MC and PHP ; with long scripts, MC will be up to 100 times faster than PHP3 and 75 time faster than PHP4. You will find in the list archive ways to handle MC based web apps as long running processes. Don't forget that you can, if needed, use PHP as one of the best MC apps compliant sockets listener. Have fun. Regards, Pierre Sahores WEB & VPN applications & databases servers Inspection académique de Seine-Saint-Denis Qualifier & produire l'avantage compétitif ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: mc & cgi: limiting users to one visit
Chipp Walters wrote: > > Andu, > > Quick question. Have you done any speed/load tests using MC-cgi vs PHP or > ASP? Can one consider MC-cgi a robust, web-application development tool like > ASP and PHP? I know it doesn't do inline scripting like ASP and PHP, but I > was wondering if I could use it on a Windows System for building small web > apps. Sure you can and it's fast. > > thx, > > Chipp Walters > > ___ > metacard mailing list > [EMAIL PROTECTED] > http://lists.runrev.com/mailman/listinfo/metacard -- __ Regards, Andu ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
RE: mc & cgi: limiting users to one visit
Andu, Quick question. Have you done any speed/load tests using MC-cgi vs PHP or ASP? Can one consider MC-cgi a robust, web-application development tool like ASP and PHP? I know it doesn't do inline scripting like ASP and PHP, but I was wondering if I could use it on a Windows System for building small web apps. thx, Chipp Walters ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: mc & cgi: limiting users to one visit
Andu wrote back: > > on startup > > if $REQUEST_METHOD is "POST" then > >put $REMOTE_ADDRESS into userAddress > > This should be $REMOTE_ADDR not $REMOTE_ADDRESS, my mistake and Apache's > inconsistency Thanks Andu. The following also works and was inspired by the echo.mt script: -- repeat for each item i in the globals if i = "$REMOTE_ADDR" or i = "$REMOTE_ADDRESS" then put value(i) into userAddress end if end repeat - As all can see, yes, the actual name is $REMOTE_ADDR and, yes, I'm on Apache. Hope this may be of use to someone else in future. Cheers. --- Nicolas Cueto| - Kinjo Gakuin University | ".. You may know KungFu, - Nagoya Keizai University |but I know sendmail! .." Takakura Jr/Sr High | - ETJ-Aichi, Sys Admin |http://kweto.com --- --- Outgoing mail is certified virus free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.314 / Virus Database: 175 - Release Date: 2002/01/11 ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: mc & cgi: limiting users to one visit
Nikorasu Kweto wrote: > > Andu (thankfully!) wrote: > > > That's right, you can keep track of the global $REMOTE_ADDRESS such as > > > > on startup > > put $REMOTE_ADDRESS into userAddress > > Sorry but this didn't work. > > Here's the relevant portion of my script: > > - > #!mc > global userAddress > > on startup > if $REQUEST_METHOD is "POST" then >put $REMOTE_ADDRESS into userAddress This should be $REMOTE_ADDR not $REMOTE_ADDRESS, my mistake and Apache's inconsistency. >read from stdin until empty >put it after buffer > end if > > put buffer & cr & userAddres into tData > put tData into url "file:results.txt" > > -- etc etc > end startUp > -- > > I tried re-positioning the $REMOTE_ADDRESS elsewhere in the script, but > always only "buffer" gets writ onto the file (plus a cr). > > Any idea where I've gone amiss? > > Cheers. > > --- > Nicolas Cueto| > - Kinjo Gakuin University | ".. You may know KungFu, > - Nagoya Keizai University |but I know sendmail! .." > Takakura Jr/Sr High | > - ETJ-Aichi, Sys Admin |http://kweto.com > --- > > --- > Outgoing mail is certified virus free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.314 / Virus Database: 175 - Release Date: 2002/01/11 > > ___ > metacard mailing list > [EMAIL PROTECTED] > http://lists.runrev.com/mailman/listinfo/metacard -- __ Regards, Andu ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: mc & cgi: limiting users to one visit
Andu (thankfully!) wrote: > That's right, you can keep track of the global $REMOTE_ADDRESS such as > > on startup > put $REMOTE_ADDRESS into userAddress Sorry but this didn't work. Here's the relevant portion of my script: - #!mc global userAddress on startup if $REQUEST_METHOD is "POST" then put $REMOTE_ADDRESS into userAddress read from stdin until empty put it after buffer end if put buffer & cr & userAddres into tData put tData into url "file:results.txt" -- etc etc end startUp -- I tried re-positioning the $REMOTE_ADDRESS elsewhere in the script, but always only "buffer" gets writ onto the file (plus a cr). Any idea where I've gone amiss? Cheers. --- Nicolas Cueto| - Kinjo Gakuin University | ".. You may know KungFu, - Nagoya Keizai University |but I know sendmail! .." Takakura Jr/Sr High | - ETJ-Aichi, Sys Admin |http://kweto.com --- --- Outgoing mail is certified virus free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.314 / Virus Database: 175 - Release Date: 2002/01/11 ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
Re: mc & cgi: limiting users to one visit
Nikorasu Kweto wrote: > > Hi, > > I've set up an online .mt-based survey. Now, I want to restrict > (mischievous!) people who may want to revisit the survey in order to vote > again and again. How could I script things so that .mt checks whether a > person/computer has already voted? > > I'm guessing the solution has something to do with user url info sent in the > http headers via a form during a "$REQUEST_METHOD = POST"... That's right, you can keep track of the global $REMOTE_ADDRESS such as on startup put $REMOTE_ADDRESS into userAddress ... > > In the meantime, back to the MC archives... > > Thank you. > > Cheers. > > --- > Nicolas Cueto| > - Kinjo Gakuin University | ".. You may know KungFu, > - Nagoya Keizai University |but I know sendmail! .." > Takakura Jr/Sr High | > - ETJ-Aichi, Sys Admin |http://kweto.com > --- > > --- > Outgoing mail is certified virus free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.314 / Virus Database: 175 - Release Date: 2002/01/11 > > ___ > metacard mailing list > [EMAIL PROTECTED] > http://lists.runrev.com/mailman/listinfo/metacard -- __ Regards, Andu ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
mc & cgi: limiting users to one visit
Hi, I've set up an online .mt-based survey. Now, I want to restrict (mischievous!) people who may want to revisit the survey in order to vote again and again. How could I script things so that .mt checks whether a person/computer has already voted? I'm guessing the solution has something to do with user url info sent in the http headers via a form during a "$REQUEST_METHOD = POST"... In the meantime, back to the MC archives... Thank you. Cheers. --- Nicolas Cueto| - Kinjo Gakuin University | ".. You may know KungFu, - Nagoya Keizai University |but I know sendmail! .." Takakura Jr/Sr High | - ETJ-Aichi, Sys Admin |http://kweto.com --- --- Outgoing mail is certified virus free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.314 / Virus Database: 175 - Release Date: 2002/01/11 ___ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard