Re: Problem with Apache::ASP under Apache 2.4
Hi Andrew, Sorry for the ridiculous delay here! I was just looking at getting mod_perl + apache 2.4 running and it seems to be a work in progress still, and the latest status seems to be here dated April 2014: http://mail-archives.apache.org/mod_mbox/perl-modperl/201404.mbox/browser The latest release of mod_perl doesn't yet support httpd-2.4, but we are working on it and getting close to making a new release that does. In the meantime you might like to try out the httpd24threading branch at https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24threading which is largely working and is what will (hopefully soon) become mod_perl-2.09. How did you get mod_perl working then with Apache 2.4, and do you in fact have a working installation? Regards, Josh Josh Chamas Skol Labs LLC On 7/10/13 12:41 PM, Koebrick, Andrew (MNIT) wrote: Sorry for the misdirected reply. I have changed all reference from remote_ip to client_ip in the following Apache::ASP files on our system: Load.pm (1 occurrence) CGI.pm (2 occurrences) StateManager.pm (3 occurrences) That seems to have solved the problem. I hesitate however to post a patch since this fix is only good for Apache2.4 and I believe would break instances running on earlier version. Perhaps a wiser programmer can add the appropriate server version checks in a conditional so that it will work appropriately for all versions of Apache. Thanks again for the reply. Happy to see that people are still monitoring this list. Incidentally, what is the current project home? http://sourceforge.net/projects/apache-asp or http://www.apache-asp.org/? Andrew -Original Message- From: Warren Young [mailto:war...@etr-usa.com] Sent: Tuesday, July 09, 2013 6:15 PM To: Apache-ASP List Subject: Re: Problem with Apache::ASP under Apache 2.4 Please send replies to the mailing list, not direct to the one who replied to your post. On 7/9/2013 15:32, Koebrick, Andrew (MNIT) wrote: httpd-2.4 has changed it's API somewhat, the Apache2::Connection::remote_ip method is now Apache2::Connection::client_ip. So what happens if you change the reference on line 85 of Apache/ASP/StateManager.pm from remote_ip to client_ip? If it works, post a patch and someone with a commit bit will apply it for you. And, if there's anyone reading this from the Perl Apache API documentation team, why are the Apache 2.0 docs still the only ones on your site? - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org
Re: Problem with Apache::ASP under Apache 2.4
The sourceforge is more current if I remember correctly (I was trying to participate in the project a year ago but eventually was not able to, hope I will have a chance...) Anyway ,I guess that to make it work for multiple Apache version you should just check for function being declared (exists or defined would do that) Evgeny On Wed, Jul 10, 2013 at 10:41 PM, Koebrick, Andrew (MNIT) andrew.koebr...@state.mn.us wrote: Sorry for the misdirected reply. I have changed all reference from remote_ip to client_ip in the following Apache::ASP files on our system: Load.pm (1 occurrence) CGI.pm (2 occurrences) StateManager.pm (3 occurrences) That seems to have solved the problem. I hesitate however to post a patch since this fix is only good for Apache2.4 and I believe would break instances running on earlier version. Perhaps a wiser programmer can add the appropriate server version checks in a conditional so that it will work appropriately for all versions of Apache. Thanks again for the reply. Happy to see that people are still monitoring this list. Incidentally, what is the current project home? http://sourceforge.net/projects/apache-asp or http://www.apache-asp.org/? Andrew -Original Message- From: Warren Young [mailto:war...@etr-usa.com] Sent: Tuesday, July 09, 2013 6:15 PM To: Apache-ASP List Subject: Re: Problem with Apache::ASP under Apache 2.4 Please send replies to the mailing list, not direct to the one who replied to your post. On 7/9/2013 15:32, Koebrick, Andrew (MNIT) wrote: httpd-2.4 has changed it's API somewhat, the Apache2::Connection::remote_ip method is now Apache2::Connection::client_ip. So what happens if you change the reference on line 85 of Apache/ASP/StateManager.pm from remote_ip to client_ip? If it works, post a patch and someone with a commit bit will apply it for you. And, if there's anyone reading this from the Perl Apache API documentation team, why are the Apache 2.0 docs still the only ones on your site? - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org
RE: Problem with Apache::ASP under Apache 2.4
Sorry for the misdirected reply. I have changed all reference from remote_ip to client_ip in the following Apache::ASP files on our system: Load.pm (1 occurrence) CGI.pm (2 occurrences) StateManager.pm (3 occurrences) That seems to have solved the problem. I hesitate however to post a patch since this fix is only good for Apache2.4 and I believe would break instances running on earlier version. Perhaps a wiser programmer can add the appropriate server version checks in a conditional so that it will work appropriately for all versions of Apache. Thanks again for the reply. Happy to see that people are still monitoring this list. Incidentally, what is the current project home? http://sourceforge.net/projects/apache-asp or http://www.apache-asp.org/? Andrew -Original Message- From: Warren Young [mailto:war...@etr-usa.com] Sent: Tuesday, July 09, 2013 6:15 PM To: Apache-ASP List Subject: Re: Problem with Apache::ASP under Apache 2.4 Please send replies to the mailing list, not direct to the one who replied to your post. On 7/9/2013 15:32, Koebrick, Andrew (MNIT) wrote: httpd-2.4 has changed it's API somewhat, the Apache2::Connection::remote_ip method is now Apache2::Connection::client_ip. So what happens if you change the reference on line 85 of Apache/ASP/StateManager.pm from remote_ip to client_ip? If it works, post a patch and someone with a commit bit will apply it for you. And, if there's anyone reading this from the Perl Apache API documentation team, why are the Apache 2.0 docs still the only ones on your site? - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org - To unsubscribe, e-mail: asp-unsubscr...@perl.apache.org For additional commands, e-mail: asp-h...@perl.apache.org
Re: Problem with PDF files
Jonathan Dixon wrote: I am running a website where I want to control access to the various files. I have the directory setup in httpd.conf with: ... This works well for the .doc, .css, .html, and .asp files, but the pdf files always crash with an error along the lines of: [error] error compiling blah.pdf: Unrecognized character \\xF9 at (eval 37) line 265. -- , /usr/lib/perl5/site_perl/5.8.3/Apache/ASP.pm line 1462 In fact, even if I change the global.asa script to die at the beginning of Script_OnStart, I still get the same error for PDF files (unlike the other file types, where I get the error from the die command). This indicates to me that the PDF file is getting processed somehow differently from the other file types. What am I overlooking here? How do I get my site to follow the global.asa directives for the PDF file just the same as it does for the DOC files? The others gave you great work arounds. If you really had to make this work, you might try using the Script_OnParse event instead of Script_OnStart. Script_OnStart occurs after the script has been compiled, but just before execution. With Script_OnParse, you might rewrite the script to do something like a read/binary write of the file you are dealing with. Regards, Josh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem
hezi wrote: Hi i install apache::asp on windows apache_2.0.48-win32-x86-no_ssl.msi ActivePerl-5.8.6.811-MSWin32-x86-122208.msi And mod perl I have uploaded a new version of Apache::ASP to CPAN, 2.59, which should fix this error. Regards, Josh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem
i install apache::asp on windows apache_2.0.48-win32-x86-no_ssl.msi ActivePerl-5.8.6.811-MSWin32-x86-122208.msi And mod perl When I try to get tha page I get No valid request object (Apache2::RequestRec Any one has an idea why this is happening? Hi, if you are using the newest mod_perl (RC6) you should rename everything (at least) in ...site/lib/Apache/ApacheCommon.pm according to http://perl.apache.org/docs/2.0/rename.html HTH Helmut - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem
Helmut Zeilinger schrieb: i install apache::asp on windows apache_2.0.48-win32-x86-no_ssl.msi ActivePerl-5.8.6.811-MSWin32-x86-122208.msi And mod perl When I try to get tha page I get No valid request object (Apache2::RequestRec Any one has an idea why this is happening? Hi, if you are using the newest mod_perl (RC6) you should rename everything (at least) in ...site/lib/Apache/ApacheCommon.pm according to http://perl.apache.org/docs/2.0/rename.html HTH Helmut - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] sorry should be Path_to_Perl\site\lib\Apache\ASP\ApacheCommon.pm - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with PDF files
Jonathan Dixon wrote: This declares *.pdf files as being ASP files. Apache::ASP is trying to interpret them directly! What you want to do cannot be accomplished with this mechanism. Try looking at the various Apache modules. I understand that this forces the PDF files to be handled through Apache::ASP. But shouldn't the Script_OnStart section in the global.asa file short-circuit the processing of the file itself and send it out as a straight binary file? This is what seems to happen for the Word files in the directory that are treated the same way. Do you (or anyone else) have suggestions for modules to look at that can check for a valid ASP session before allowing access to files on the server? I would attempt this a bit differently. Instead of referencing the file directly and inject the code voodoo-like, how about you use a dedicated download script, hide it behind a plain name of download with the handler settings and then use $PATHINFO to get to the requested file, which can then be located elsewhere, too. This is how this would look for the user: http://foo.bar/download/file.ext where download is the name for your download script which then gets file.ext (or /file.ext, I am unsure right now) as $PATHINFO which you can then use to retrieve the file from the real location to which you can apply more restrictive access rights, too, as additional benefit. regards, Marko - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with PDF files
Jonathan Dixon wrote: Files ~ (\.pdf) SetHandler perl-script PerlHandler Apache::ASP PerlSetVar Global /storage/t212 PerlSetVar StateDir /tmp/asp PerlSetVar RequestBinaryRead On /Files This declares *.pdf files as being ASP files. Apache::ASP is trying to interpret them directly! What you want to do cannot be accomplished with this mechanism. Try looking at the various Apache modules. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with PDF files
This declares *.pdf files as being ASP files. Apache::ASP is trying to interpret them directly! What you want to do cannot be accomplished with this mechanism. Try looking at the various Apache modules. I understand that this forces the PDF files to be handled through Apache::ASP. But shouldn't the Script_OnStart section in the global.asa file short-circuit the processing of the file itself and send it out as a straight binary file? This is what seems to happen for the Word files in the directory that are treated the same way. Do you (or anyone else) have suggestions for modules to look at that can check for a valid ASP session before allowing access to files on the server? Thanks, Jon Dixon [EMAIL PROTECTED] http://dixonjon.tripod.com/ -- ___ NEW! Lycos Dating Search. The only place to search multiple dating sites at once. http://datingsearch.lycos.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with function from file included by 'require functions.pl'
Oleg Kobyakovskiy wrote: Hello everybody, I have a .pl file with 2 function definitions. I include this file in global.asa to use defined functions through: require 'file.pl'; . It works fine. But some time I get the error like: [Wed Feb 19 13:28:01 2003] [error] [asp] [4391] [error] Undefined subroutine Apache::ASP::Compiles::__ASP__usr_local_apache_2_servers_lensesx::cc_decrypt called at /usr/local/apache-2/servers/lenses/private/show-invoice.pl line 40. -- , /opt/perl/lib/site_perl/5.8.0/Apache/ASP.pm line 1491 If you have multiple file.pl that your code will require, this will mess with Perl's %INC, and you may get the wrong results. There can be only one unique file.pl per web server, even across virtual hosts. You might be better off having them be directly in the global.asa, or making a real unique perl module out of it that you can use like use My::Unique::Module::Functions; Regards, Josh Josh Chamas, Founder phone:925-552-0128 Chamas Enterprises Inc.http://www.chamas.com NodeWorks Link Checkinghttp://www.nodeworks.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with global.asa
Oleg Kobyakovskiy wrote: Hello Everybody, I have next problem: I have 2 sites example.com and admin.example.com. They are under Apache::ASP both, placed in differert path and each of then has own global.asa file. Sometime when I'm trying to look at admin.example.com it runs the Application_OnStart function from example.com site and fills the $Application by example.com site values. So I can work with admin.example.com site after application finished only or after I restart apche and remove state folders. I use Apache/2.0.44 (Unix) mod_perl/1.99_08 Perl/v5.8.0 mod_ssl/2.0.44 OpenSSL/0.9.6g DAV/2. I had the same problem with apache-1.3.x, mod_perl-1.27 and perl-5.6.1. Apache::ASP version is 2.49, OS Linux. All ASP settings are in the .htaccess files in both sites. Does somebody know what is wrong. Make sure they use different GlobalPackage settings, as that is the package that events like Application_OnStart are compiled into. So using different global.asa with the same GlobalPackage settings should be avoided generally. If you are not using GlobalPackage config, it would be helpful if you could post your .htaccess files PerlSetVar settings from httpd.conf to figure out what the problem might be. Regards, Josh Josh Chamas, Founder phone:925-552-0128 Chamas Enterprises Inc.http://www.chamas.com NodeWorks Link Checkinghttp://www.nodeworks.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with global.asa
Hello Josh, Thank you very much. I've removed GlobalPackage from .htaccess and it looks like all work correct now. Thank you one more time. Josh Chamas wrote: Oleg Kobyakovskiy wrote: Hello Everybody, I have next problem: I have 2 sites example.com and admin.example.com. They are under Apache::ASP both, placed in differert path and each of then has own global.asa file. Sometime when I'm trying to look at admin.example.com it runs the Application_OnStart function from example.com site and fills the $Application by example.com site values. So I can work with admin.example.com site after application finished only or after I restart apche and remove state folders. I use Apache/2.0.44 (Unix) mod_perl/1.99_08 Perl/v5.8.0 mod_ssl/2.0.44 OpenSSL/0.9.6g DAV/2. I had the same problem with apache-1.3.x, mod_perl-1.27 and perl-5.6.1. Apache::ASP version is 2.49, OS Linux. All ASP settings are in the .htaccess files in both sites. Does somebody know what is wrong. Make sure they use different GlobalPackage settings, as that is the package that events like Application_OnStart are compiled into. So using different global.asa with the same GlobalPackage settings should be avoided generally. If you are not using GlobalPackage config, it would be helpful if you could post your .htaccess files PerlSetVar settings from httpd.conf to figure out what the problem might be. Regards, Josh Josh Chamas, Founder phone:925-552-0128 Chamas Enterprises Inc.http://www.chamas.com NodeWorks Link Checkinghttp://www.nodeworks.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Best regards. Oleg [EMAIL PROTECTED] (nic-hdl) OKU11 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem passing complex structure in XMLSubs args...
Brat Wizard wrote: Josh, I have a quick question-- is there a problem passing a complex (non-scalar) variable in the arguments of an XMLSubs function?? I am having problems passing hashes to the function. Ex. my $hash = { blah blah blah }; my:sub args=$hash some stuff /my:sub This should work: % my $hash = { key = 'value' }; % my:sub args=$hash some stuff /my:sub The trick with XMLSubs is that the argument values are treated as raw perl code. This will change in 3.0 with the new syntax of args=%= $hash % to do the same thing. But the current method will have a XMLSubsPerlArgs flag that can be set to keep backwards compatible. Regards, Josh Josh Chamas, Founder phone:925-552-0128 Chamas Enterprises Inc.http://www.chamas.com NodeWorks Link Checkinghttp://www.nodeworks.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem passing complex structure in XMLSubs args...
Yup, that did it, thanks John On Wednesday 18 September 2002 10:19 pm, Josh Chamas spewed into the ether: Brat Wizard wrote: Josh, I have a quick question-- is there a problem passing a complex (non-scalar) variable in the arguments of an XMLSubs function?? I am having problems passing hashes to the function. Ex. my $hash = { blah blah blah }; my:sub args=$hash some stuff /my:sub This should work: % my $hash = { key = 'value' }; % my:sub args=$hash some stuff /my:sub The trick with XMLSubs is that the argument values are treated as raw perl code. This will change in 3.0 with the new syntax of args=%= $hash % to do the same thing. But the current method will have a XMLSubsPerlArgs flag that can be set to keep backwards compatible. Regards, Josh Josh Chamas, Founder phone:925-552-0128 Chamas Enterprises Inc.http://www.chamas.com NodeWorks Link Checkinghttp://www.nodeworks.com -- Check out http://www.Wizard.Org for great deals on Electronic Parts *NEW* Computer Parts Accessories - Drives - LCD - Systems - Linux ** Affordable Online Store w/Merchant Card Processing Paypal ** Write to us: [EMAIL PROTECTED] -- Get your Store Online Today! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem installing Apache::PHP on Windows
aplessers wrote: I've installed the perl-win32-bin-0.7.exe. I've three folders apache, perl and open ssl. When I want to run apache it is saying that it cannot load the module mod_perl.so into the server. The module path is correctly set in the http.conf and the file is present. What could be wrong? Try restarting your computer. This is often necessary on windows computers for the changes to PATH to take effect. Make sure that you did update PATH according to the directions provided with the perl-win32-bin-0.7.exe distribution ( last I remember anyway ). If you continue to have problems, please write what the error message is exactly regarding cannot load the module mod_perl.so. Often with the PATH problem for example, there is a dialog box that will pop up saying some kind of loading problem. Regards, Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem Sending Cookies
Mike Martinet wrote: Well, after days of fighting with this, I've given up and am using JavaScript to set and expire 'permanent' or 'hard' cookies. If anyone has does come up with a suggestion, or can offer some sample code, I'd still really appreciate seeing it - I'd prefer to do this in ASP/Perl, but I have to move on. Thanks, Sorry, this thread got buried in my email. I would like to help. Can you provide a snippet of code that sets the cookies, and the results of running lwp-request -ed $URL --Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem Sending Cookies
Well, after days of fighting with this, I've given up and am using JavaScript to set and expire 'permanent' or 'hard' cookies. If anyone has does come up with a suggestion, or can offer some sample code, I'd still really appreciate seeing it - I'd prefer to do this in ASP/Perl, but I have to move on. Thanks, MjM [EMAIL PROTECTED] wrote: I have searched the archives and an't find anything like this... I have two servers, a Dev server and a Test server. They both have: Linux 2.4.7-10 Apache 1.3.24 mod_perl 1.26 mod_ssl 2.8.8 Apache::ASP 2.35 Identical application ASP pages. Both machines are on the same subnet. My Logon.asp page attempts to set two cookies, a Session cookie and a Hard or Disk cookie. By my understanding, the difference between a Session and a Hard cookie is the lack of an expiration date in the former. No matter what I've tried, I can't get the Test server to set the hard cookie on client machines. If I turn on cookie prompting in the browser (IE), I get prompted for two cookies being sent from the Dev server, but only one cookie, the Session cookie, being sent from the Test server. I can't understand what could be different between the two implementations which would cause this behavior. As always, any help greatly appreciated. Thanks, MjM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with Binaryread
Mike Martinet wrote: Greetings, Please excuse me if this message is a duplicate. I've been trying to post on various mailing lists and not quite sure how to do it. I may be missing something fundamental here, but I can't find an explanation for what I'm doing wrong. If I specify enctype=multipart/form-data in my FORM tag, then I get boundaries, but I get no data with $Request-ServerVariables( CONTENT_TYPE ); $Request-BinaryRead( $Request-{ TotalBytes } ); You cannot get BinaryRead data with file uploads. This is deficiency in the Apache::ASP API. File uploads are processed via CGI.pm internally, and access to the data is provided via: $Request-FileUpload() Please see http://www.apache-asp.org/cgi.html#File%20Upload for more info on this topic. I have added a note about this to the API documentation. Regards, Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem installing asp.. mldbm-sync and more...
Tyler Worman wrote: thanks for responding. I tried that distribution before thats why i set off to get it working from scratch that distro has everything i need except when i tried to start apache from it it said that it could not load the ssl or perl So i tried again now but i still get the same error. It is Syntax error on line 203 of c:/apache/conf/httpd.conf: Cannot load /apache/modules/mod_ssl.so into server (126) The Specified module cannot be found: Did specifying the full path to the module help as Ruggero suggested? On NT, I did not have to do this, since the path was set correctly relative to the apache server root. I remember when I installed it that I had to pay special attention to the PATH environment variable being set so that perl openssl libraries got picked up correctly, did you do this? XP kernel is based on NT, so I imagine this would not be done in the config.ini, but in the system control panel if XP has it still. I would think it odd that the error would be cannot be found, if really a shared library could not be loaded, but this might be it. Failing further progress on this to help you, you might contact the package maintainer directly, Randy. He might know of issues specific to XP. Finally, whatever the solution is, be sure you post it here for the benefit of all! --Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with asp module and apache on win98
Giorgio D'Anna wrote: before I got another error too: flock() unimplemented on this platform at /apache/lib/perl/ MLDBM/Sync.pm line xxx but I commented out some lines in sync.pm and so I fixed that. Anyway, since I have read on the documentation that it is possible to disable use of flock() on Win95/98 where it is unimplemented I'd want to know how I can do this (instead of commenting out). Install a fresh MLDBM::Sync, and then add this to your httpd.conf file: Perl *CORE::GLOBAL::flock = sub { 1 }; /Perl This is to define a flock to effectively nothing, which will be fine on win98 for now since mod_perl is serialized on this platform. I believe this will only work with perl 5.6, but when working things out with someone else recently, this seems to do the trick. If you plan any network communications on win32 apache/mod_perl via perl I would also recommend that you set MaxThreadsPerChild to 1 which will get rid of odd socket problems. --Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with SessionCount
Kreuzer, Harald wrote: hello! first of all thanks for this great piece of software!! i changed my site from ms-asp to apache::asp and i am very happy with it. now my problem: i updated some days ago to asp 2.27 and it seems as if i don't get Session_OnEnd events anymore. i have a statistics page on my site where i can see the current number of session (with $Application-SessionCount() ), and since i have installed the new version it's getting higher and higher but never decreases. did there change something that i missed? I use asp 2.27, mod_perl 1.26 perl 5.6.1 and apache 1.3.22. I believe this is due to an optimization made in either 2.25 or 2.27 wherein a $Session would only get a Session_OnEnd event there was something actually written to it. The problem is that the current session garbage collector relies on session files on disk, but these empty sessions have no files on disk associated with them, just entries in the internal database. As a temporary workaround, you could do this: sub Session_OnStart { $Session-{MARK} = 1; } This would create the session files on disk. I believe then that Session_OnEnd events would fire as normal, and your SessionCount would keep current. The performance penalty of always writing to a $Session would be little more than what was in 2.21. I will fix this ASAP in my dev 2.29 version by reading in sessions for garbage collection from the internal database instead of files on disk, which will account for the prior optimization. This is a change I need to make anyway for the session garbage collector before creating a SQL db backed implementation of $Session / $Application storage. --Josh - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Problem with Apache::ASP and HTTP::Date::time2iso()
I frequently use the HTTP::Date functions time2str and str2time. Do you have other, lower-overhead suggestions? JL -Original Message- From: Joshua Chamas [mailto:[EMAIL PROTECTED]] Sent: Monday, November 12, 2001 2:35 PM To: ross scanlon Cc: [EMAIL PROTECTED] Subject: Re: Problem with Apache::ASP and HTTP::Date::time2iso() ross scanlon wrote: Hi all, Am having a problem with part of Apache::ASP and was wondering if anyone can helpout. Undefined subroutine HTTP::Date::time2iso called at ... You can see the full output at http://test.theinternethost.com.au/site/eg Did you just upgrade Apache::ASP ? As of 2.27, Apache::ASP no longer uses HTTP::Date, but the examples from an old install still would. So for there to not be an error when using HTTP::Date functions, now one must add something like: PerlModule HTTP::Date to the httpd.conf/.htaccess file. But I believe I took out all references to HTTP::Date out of the examples that ship with 2.27, so maybe these are old examples, but you upgraded to the latest Apache::ASP? I removed the dependency of Apache::ASP on HTTP::Date because HTTP::Date requires the installation of the perl libwww libraries which are quite huge unnecessary. -- Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with Apache::ASP and HTTP::Date::time2iso()
John D. Leonard II wrote: I frequently use the HTTP::Date functions time2str and str2time. Do you have other, lower-overhead suggestions? Well, its undocumented, and will remain so, but I just moved the HTTP::Date module into Apache::ASP as Apache::ASP::Date, so if you want to use it there you may. I don't think HTTP::Date is high in overhead, and just wanted to make the installation process easier on people when first installing Apache::ASP. If you did something like: # global.asa *time2str = *Apache::ASP::Date::time2str; Then you could just reference time2str() in your scripts, and if Apache::ASP::Date disappears just point it somewhere else. --Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks Founder Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem with multiple select
JC Fant IV wrote: So here is what I cam up with. Looks to me like you will not be able to do both at the same time. Multiple select boxes are not pulling in with a from ENCTYPE==multipart/form-data. I have this fixed in my dev version 2.15. If anyone wants it, let me know. The diff was: diff ASP.pm~ ASP.pm 2911c2911,2912 $form{$_} = $q-param($_); --- my @params = $q-param($_); $form{$_} = @params 1 ? [ @params ] : $params[0]; --Josh _ Joshua Chamas Chamas Enterprises Inc. NodeWorks - Web Link Checking Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem with multiple select
you can do two different things.. Hi, I'm having problem to get the result of a SELECT ... MULTIPLE field in a form. something like this works file : 1.) change the form from method=post to method=get FORM name=FormName method=get and the code should work. However if you want to upload a file you are going to need to use the second example. FORM name=FormName method=post SELECT name=aSelectField size=4 multiple OPTION value=onefirst/OPTION OPTION value=twosecond/OPTION OPTION value=threethird/OPTION /SELECT /FORM PaSelectField2 : % 2. to grab the incoming post information Use $Request-Form('aSelectField'); this will pull in the posting form. @selectFields = $Request-Params('aSelectField'); print join ',', @selectFields % /P I tried this code on my server and works fine. test1.html = FORM action=test2.html name=FormName method=post SELECT name=aSelectField size=4 multiple OPTION value=onefirst/OPTION OPTION value=twosecond/OPTION OPTION value=threethird/OPTION /SELECT input type=submit name=submit value=submit /FORM test2.html = PaSelectField2 : % @selectFields = $Request-Form('aSelectField'); print join ',', @selectFields % /P test2.html returned aSelectField2 : one,two,three # for uploading a file try http://www.nodeworks.com/asp/cgi.html at the bottom of the page this contains all of the info on using ASP and CGI to upload a file. But I also need to upload a file with this form. When I add ENCTYPE=multipart/form-data to the form tag, I can only retrieve the first selected item from aSelectField. It's like the wantarray doesn't work anymore. Does anybody know how to fix this ? Anton. - - WestSite NV - I N T E R N E T S O L U T I O N S - - Torhoutse Steenweg 337 8200 Brugge BELGIUM T.+32 50 39 41 41 F.+32 50 39 41 43 mailto:[EMAIL PROTECTED] - http://www.westsite.be http://wap.westsite.be - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ___ J.C. Fant IV PlanetofMusic.com Perl Guru ? 818 517 4879 mailto:[EMAIL PROTECTED] ___ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem with multiple select
There may be a bug here ... Apache::ASP handles file uploads with different logic from other forms by using CGI.pm for the underlying file upload parsing. I'll look into this ( early next week ) and see if I can't make multiple select values behave properly in this context. --Josh --- Anton Slabbinck [EMAIL PROTECTED] wrote: Hi, I'm having problem to get the result of a SELECT ... MULTIPLE field in a form. something like this works file : FORM name=FormName method=post SELECT name=aSelectField size=4 multiple OPTION value=onefirst/OPTION OPTION value=twosecond/OPTION OPTION value=threethird/OPTION /SELECT /FORM PaSelectField2 : % @selectFields = $Request-Params('aSelectField'); print join ',', @selectFields % /P But I also need to upload a file with this form. When I add ENCTYPE=multipart/form-data to the form tag, I can only retrieve the first selected item from aSelectField. It's like the wantarray doesn't work anymore. Does anybody know how to fix this ? Anton. - - WestSite NV - I N T E R N E T S O L U T I O N S - - Torhoutse Steenweg 337 8200 Brugge BELGIUM T.+32 50 39 41 41 F.+32 50 39 41 43 mailto:[EMAIL PROTECTED] - http://www.westsite.be http://wap.westsite.be - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail - only $35 a year! http://personal.mail.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem with multiple select
Seems to me that its not the fileupload part that's messed up... its in the ENCTYPE=multipart/form-data . I tried even to submit the multiple select with out using the file upload with a form tag.. form name=doattach id=doattach action=test2.html method=post ENCTYPE=multipart/form-data and I get the same thing, only one select value comes in... I really don't think its on the Apache-ASP side Hey I have been wrong before and am probably wrong again!!! - Original Message - From: Joshua Chamas [EMAIL PROTECTED] To: Anton Slabbinck [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Thursday, June 07, 2001 2:24 PM Subject: Re: problem with multiple select There may be a bug here ... Apache::ASP handles file uploads with different logic from other forms by using CGI.pm for the underlying file upload parsing. I'll look into this ( early next week ) and see if I can't make multiple select values behave properly in this context. --Josh --- Anton Slabbinck [EMAIL PROTECTED] wrote: Hi, I'm having problem to get the result of a SELECT ... MULTIPLE field in a form. something like this works file : FORM name=FormName method=post SELECT name=aSelectField size=4 multiple OPTION value=onefirst/OPTION OPTION value=twosecond/OPTION OPTION value=threethird/OPTION /SELECT /FORM PaSelectField2 : % @selectFields = $Request-Params('aSelectField'); print join ',', @selectFields % /P But I also need to upload a file with this form. When I add ENCTYPE=multipart/form-data to the form tag, I can only retrieve the first selected item from aSelectField. It's like the wantarray doesn't work anymore. Does anybody know how to fix this ? Anton. - - WestSite NV - I N T E R N E T S O L U T I O N S - - Torhoutse Steenweg 337 8200 Brugge BELGIUM T.+32 50 39 41 41 F.+32 50 39 41 43 mailto:[EMAIL PROTECTED] - http://www.westsite.be http://wap.westsite.be - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail - only $35 a year! http://personal.mail.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ___ J.C. Fant IV PlanetofMusic.com Perl Guru ? Don't Think So!!! 818 517 4879 mailto:[EMAIL PROTECTED] ___ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: problem with multiple select
So here is what I cam up with. Looks to me like you will not be able to do both at the same time. Multiple select boxes are not pulling in with a from ENCTYPE==multipart/form-data. I would be curious to know if anyone else has gotten this to work. I attached an asp file for you to try. below is the code. I had to a.) either post the information to two different pages. or b.) I chose to post the file upload to itself and send the multiple select to a separate page. If you want to see this in action try http://www.planetofmusic.com/test1.html sorry I'm not actually loading any of your files to my server, but I did test it and it worked correctly. All files uploaded were placed in the select box then multiple selects could then be shown on the second page. try it??? % my $filehandle = $Request-Form('attfile'); my $name; my $hidden; my $option; if ($filehandle){ print $filehandle . br; # will get you the file name #will give you a name for the file; $filehandle =~ /(\w+)\.(\w+)/; $name = $1.$2; $hidden .= 'input type=hidden name=' . $name . ' value=' . $name . '' . \n; $option .= 'OPTION value=' . $name . '' . $name . '/OPTION' . \n; print This is the name $namebr; my $data; while($filehandle) { $data .= $_; }; #don't really want people uploading thing right now. #uncomment this to store them for yourself. #open (fh, $name); #print fh $data; #close fh; my $form = $Request-Form(); foreach (keys %$form){ if ($_ =~ /(\w+)\.(\w+)/){ $hidden .= 'input type=hidden name=' . $_ . ' value=' . $form-{$_} . '' . \n; $option .= 'OPTION value=' . $form-{$_} . '' . $_ . '/OPTION'; } } } % !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN html head titleUntitled/title /head body br Notice the first form posts to itself.br FORM name=doattach id=doattach action=test1.html method=post ENCTYPE=multipart/form-data %= $hidden %br I posted hidden variable here.br Attach File: input name=attfile type=filebrbr input type=submit name=submit value=Attach File /form br br The second form posts to the second page. form name=doattach id=doattach action=test2.html method=post %= $hidden %br I posted hidden variable here.br and all options below. SELECT name=aSelectField size=4 multiple %= $option % /SELECTbr input type=submit name=submit value=submit /FORM - Original Message - From: Anton Slabbinck [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, June 07, 2001 6:48 AM Subject: problem with multiple select Hi, I'm having problem to get the result of a SELECT ... MULTIPLE field in a form. something like this works file : FORM name=FormName method=post SELECT name=aSelectField size=4 multiple OPTION value=onefirst/OPTION OPTION value=twosecond/OPTION OPTION value=threethird/OPTION /SELECT /FORM PaSelectField2 : % @selectFields = $Request-Params('aSelectField'); print join ',', @selectFields % /P But I also need to upload a file with this form. When I add ENCTYPE=multipart/form-data to the form tag, I can only retrieve the first selected item from aSelectField. It's like the wantarray doesn't work anymore. Does anybody know how to fix this ? Anton. - - WestSite NV - I N T E R N E T S O L U T I O N S - - Torhoutse Steenweg 337 8200 Brugge BELGIUM T.+32 50 39 41 41 F.+32 50 39 41 43 mailto:[EMAIL PROTECTED] - http://www.westsite.be http://wap.westsite.be - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ___ J.C. Fant IV PlanetofMusic.com Perl Guru ? Don't Think So 818 517 4879 mailto:[EMAIL PROTECTED] ___ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]