Incidentally, the "http://otala.com/snoop.jsp" is a very useful page --
it allows you to see all the available JSP parameters.
You will find the actual file at /home/httpd/otala.com/snoop.jsp
JSP pages are basically HTML, with Java thrown in-between. The performance is very good as the page gets [automatically] compiled when it has changed and subsequently runs as a memory resident Java Servlet.
Current installed Java version is JDK 1.1.7
There is a common shared location /home/httpd/servlets which is shared
transparently between all the domains. Just write your Java Servlet page
into that directory, for example /home/httpd/servlets/Hello2.java
Remember to compile the page (in the directory) with "javac Hello2.java"
And then you can execute it with "http://otala.com/Hello2" (note
that you do not identify any extensions to the Servlet pages).
More text needed about packages... and beans... soon.
Current installed Java version is JDK 1.1.7
Some good books are:
- Java Servlets, second edition by Karl Moss
Standard Perl is simple; write your page (anywhere in your web directory structure), file extension should be either ".pl" or ".cgi", remember to set the X bit (chmod +x ping.pl) then just call it with "http://otala.net/ping.pl"
Apache mod_perl is a mean & lean version of Perl, sitting all the time in
memory, keeping your code and variables ready to go. Much more efficient
than plain Perl, but comes with a few quirks...
For mod_perl pages, you must store the pages into /home/httpd/perl, and
you still have to do the X bit (chmod +x ping.pl).
Another quirk is that STDIN and STDOUT behave quite differently for
mod_perl.
The three most common errors with Perl are:
1) You forgot that the first line must read: #!/usr/bin/perl
2) You forgot that the second line must read: print "Content-type: /text/html\n\n";
3) You forgot the eXecute bit (chmod +x ping.pl)
Just write a page with ".shtml" extension instead of ".html" and Apache will
execute any embedded SSI statements. A good example of an SHTML page is
http://otala.net/domains.shtml (can be found at /home/httpd/otala.net/domains.shtml).
This page collects a lot of dynamic information about files, dates and such
and presents it to the user.
The combination of SHTML and Perl pages is pretty efficient.
If you want access control for a directory structure, you need to write a file ".htaccess" describing the access restriction type.
More writing needed on ACLs...
All the JDBC drivers are readily available to JSP and Servlet pages, using Thin drivers. Performance is really good and there's quite a bit storage available.
I recommend writing a database access Bean (in Java) and then using that
from your web pages. A good example is the GrandPeyrot site and its
bean /home/httpd/jsp/beans/dbBean.java
The beans get automatically compiled with JSPs, while you have to manually
compile them when using Servlets.
Before you can use the database access, I need to set up an Oracle account for you... So, send me email and we can get this started.