Annotation of parser3/bin/auto.p.dist.in, revision 1.7

1.7     ! paf         1: #$Id: auto.p.dist.in,v 1.6 2002/08/12 08:19:37 paf Exp $
1.1       paf         2: 
                      3: @conf[]
                      4: $charsetsdir[@charsetsdir@]
                      5: $sqldriversdir[@sqldriversdir@]
                      6: 
                      7: $CHARSETS[
                      8: @commentcharset_koi8r@    $.koi8-r[$charsetsdir/koi8-r.cfg]
                      9: @commentcharset_windows1250@    $.windows-1250[$charsetsdir/windows-1250.cfg]
                     10: @commentcharset_windows1251@    $.windows-1251[$charsetsdir/windows-1251.cfg]
                     11: @commentcharset_windows1257@    $.windows-1257[$charsetsdir/windows-1257.cfg]
                     12: ]
                     13: #change your client libraries paths to 
those on your system
                     14: $SQL[
                     15:        $.drivers[^table::set{protocol  driver  client
                     16: mysql  $sqldriversdir/libparser3mysql.so       @mysql_client@
                     17: pgsql  $sqldriversdir/libparser3pgsql.so       @pgsql_client@
                     18: oracle $sqldriversdir/libparser3oracle.so      @oracle_client@
                     19: }]
                     20: ]
                     21: 
                     22: #for ^file:load[name;user-name] mime-type autodetection
                     23: $MIME-TYPES[^table::set{ext    mime-type
                     24: zip    application/zip
                     25: doc    application/msword
                     26: xls    application/vnd.ms-excel
                     27: pdf    application/pdf
                     28: ppt    application/powerpoint
                     29: rtf    application/rtf
                     30: gif    image/gif
                     31: jpg    image/jpeg
1.4       paf        32: jpeg   image/jpeg
1.1       paf        33: png    image/png
                     34: tif    image/tiff
                     35: html   text/html
                     36: htm    text/html
                     37: txt    text/plain
1.7     ! paf        38: xml    text/xml
1.1       paf        39: mts    application/metastream
                     40: mid    audio/midi
                     41: midi   audio/midi
                     42: mp3    audio/mpeg
                     43: ram    audio/x-pn-realaudio
                     44: rpm    audio/x-pn-realaudio-plugin
                     45: ra     audio/x-realaudio
                     46: wav    audio/x-wav
                     47: au     audio/basic
                     48: mpg    video/mpeg
                     49: avi    video/x-msvideo
                     50: mov    video/quicktime
                     51: swf    application/x-shockwave-flash
                     52: }]
                     53: 
                     54: $LIMITS[
                     55:        $.post_max_size(10*0x400*0x400)
                     56: ]      
                     57: 
                     58: #$MAIL[
                     59: #      $.sendmail[your sendmail command goes here]
                     60: #      these are tried when no 'sendmail' specified:
1.5       paf        61: #          /usr/sbin/sendmail -t -i -f postmaster
                     62: #          /usr/lib/sendmail -t -i -f postmaster
1.1       paf        63: #]
                     64: 
1.6       paf        65: @fatal_error[title;body]
                     66: $response:status(500)
                     67: $response:content-type[
                     68:         $.value[text/html]
                     69:         $.charset[$response:charset]
1.1       paf        70: ]
1.6       paf        71: <html>
                     72: <head><title>$title</title></head>
                     73: <body>
                     74: <H1>$title</H1>
                     75: $body
                     76: #for [x] MSIE friendly
                     77: ^for[i](0;512/8){<!-- -->}
                     78: </body>
1.1       paf        79: 
1.3       paf        80: @unhandled_exception_debug[exception;stack]
                     81: ^fatal_error[Unhandled Exception (Debug);
                     82: 
1.1       paf        83: <pre>^untaint[html]{$exception.comment}</pre>
                     84: ^if(def $exception.source){
                     85: <b>$exception.source</b><br>
                     86: <pre>^untaint[html]{$exception.file^($exception.lineno^)}</pre>
                     87: }
                     88: ^if(def $exception.type){exception.type=$exception.type}
                     89: ^if($stack){
                     90:        <hr>
                     91:        ^stack.menu{
                     92:                <tt>$stack.name</tt> $stack.file^($stack.lineno^)<br>
                     93:        }
                     94: }
1.3       paf        95: 
                     96: ]
                     97: 
1.6       paf        98: @unhandled_exception_release[exception;stack]
                     99: ^fatal_error[Unhandled Exception;
                    100: 
                    101: <p>The server encountered an unhandled exception 
                    102: and was unable to complete your request.</p>
                    103: <p>Please contact the server administrator, $env:SERVER_ADMIN
                    104: and inform them of the time the error occurred, 
                    105: and anything you might have done that may have caused the error.</p>
                    106: <p>More information about this error may be available in the Parser error log
                    107: or in debug version of unhandled_exception.</p>
                    108: 
1.3       paf       109: ]
1.6       paf       110: 
                    111: @unhandled_exception[exception;stack]
                    112: ^unhandled_exception_release[$exception;$stack]
                    113: 
1.1       paf       114: 
                    115: @auto[]
                    116: #source/client charsets
                    117: $request:charset[windows-1251]
                    118: $response:charset[windows-1251]
                    119: 
                    120: $response:content-type[
                    121:         $.value[text/html]
                    122:         $.charset[$response:charset]
                    123: ]
                    124: 
                    125: #$SQL.connect-string[mysql://user:pass@host/db?charset=cp1251_koi8]
                    126: #$SQL.connect-string[pgsql://user:pass@host/db]
                    127: #$SQL.connect-string[oracle://user:pass@service?NLS_LANG=RUSSIAN_AMERICA.CL8MSWIN1251&NLS_DATE_FORMAT=YYYY-MM-DD HH24:MI:SS]
                    128: #$SQL.connect-string[odbc://DSN=datasource^;UID=user^;PWD=password]

E-mail: