At 11:08 AM 12/8/00, tedd wrote: >Bruce wrote -- >>I just did it when I set up Apache under OS X. I have to say, BTW, that this >Thanks for your comments. I am really fuzzy about this "server >running on my machine so that I can test my cgi script" thing. >Please excuse my ignorance, but that is unimaginable to me at the >moment. > >If I hear you right, then you have a server running on your machine >so that you can set-up a client/server thing to test stuff? Wow! For a long time I've been following the example of others on this list of configuring my OS 9 Mac to enable personal web sharing, and running a small web server on my own machine (I use NetPresenz, others use Quid Pro Quo, or ...). Then, I have MacPerl (using BBEdit) convert my text-file CGI code to a Mac "CGI" executable. I can install this CGI in my local web directory, and run it via a web browser. Provides a fast way to debug CGI stuff, and I also use web/CGI as a quick and dirty user interface to stuff that isn't CGI-related. Search the archives of this list for plenty of discussion. David Steffen wrote the definitive article on how to set this up. See PerlMonth, Issue 11: http://www.perlmonth.com/index.html?issue=11 Very handy. Then comes Mac OS X Public Beta, which I've been running occasionally. Through a control pane you can activate your "server" and designate a directory for your web docs. The web server software, running in the underlying UNIX environment of OS X is -- full on Apache! And the Perl 5.6 distribution is installed, giving not only the advantages of v. 5.6 itself, but also updated versions of many great Perl modules, including CGI.pm. This was hard to resist. So, with some help I peered into the Apache.conf text file, and found the settings for HTML suffix, CGI directory & suffix, SSI activation, default index filename, and web 'root' directory. I configured these, leaving most of the Apache setup exactly as I found it. When I tried to save the revised Apache.conf file, the system told me that I had insufficient permissions. So, in the terminal, I had to change the ownership of the file to my login; then I was able to save the file. Finally, I had to learn to restart Apache from the command line in the Terminal window: "Apachectl restart" I have very little experience using UNIX with the usual command line interface, so don't ask me for much depth on this. I've heard there's a newer version of Apache that can be installed, but haven't done that yet. Anyway, I fired up OS X's copy of IE 5, typed in the URL of my "server", and there was the home page I'd dropped into the designated web directory. Clicked a link to a CGI I'd placed (text file format) in the designated CGI Executables directory (alias-named 'cgi-bin' for practical and sentimental reasons). Out came CGI output. Not as quickly as direct Perl/MacPerl output, but fast contrasted with web server output across a fast Internet connection. Cool. So, as I experiment with recreating my work environment in the OS X framework, I'm putting text copies of all my web-related scripts in the webserver's CGI directory. I can work in BBEdit (running in a "Classic" environment window), which is hooked up with MacPerl for syntax checking and direct execution. Two additional ways to execute are now available: I can open a terminal window and invoke Perl 5.6 to run the script file that I'm testing, and I can call the script in a web/CGI environment. Make a change in the BBEdit window, save, switch to the terminal or the web browser window, and test. Repeat as needed. I'm also testing the OS X beta version of Fetch for final installation on my client's server. BTW, thanks to OS X memory handling, running BBEdit & MacPerl under OS X Classic has allowed me to do some processing on much larger files than under plain OS 9. My database module switches into a memory-conserving subset of methods (subroutines) when digging into large source files, so I'm always stress-testing it to understand the optimal threshold for switching. Asked it to select all records and sort an entire 40 MB text file; this would normally cause MacPerl and/or BBEdit to cry "Uncle" or just run away. They'd be too wreaked to go on without restarting. Under OS X, there was a period when my machine went into a rather unresponsive but disk-active thinking mode, but then -- out popped the success message, and sure enough, there was a fresh new indexed and sorted data file. BBEdit and MacPerl were just standing there, dusting their hands off like no big deal. Got slightly better performance running the same script from the command line with Perl 5.6, but it was great to see the dynamic combo of BBedit and MacPerl doing fine under OS X. But back to the UNIX aspect, I'm starting to understand the comments of others that some sort of new era might be starting, with 10 million Mac users gaining access to excellent FreeBSD UNIX, excellent Perl 5.6, excellent Apache, etc., along with their beta-excellent Mac OS X GUI and soon-to-be excellent OS X versions of Mac software. I, for one, will be there. 1; - Bruce __Bruce_Van_Allen___Santa_Cruz_CA__ ==== Want to unsubscribe from this list? ==== Send mail with body "unsubscribe" to macperl-webcgi-request@macperl.org