Re: multilanguage site

2000-09-03 Thread Ričardas Čepas

On Fri Sep  1 23:18:13 2000 -0400 Eric L. Brine wrote:

> 
> > You basically must use an encoding like UTF-8 which can reach the
> > entire unicode character set or else you cannot mix languages.
> 
> Not quite. To display characters not in the current character set, use
> "&...;" encodings, such as "é" and "✏" (where  is
> unicode).
> 
This would require unicode capable browser anyway.  Even more,
Netscape v4 doesn't show these escapes unless you set encoding to utf-8.

-- 
  ☻ Ričardas Čepas ☺
~~
~



Re: [OT] multilanguage site

2000-09-03 Thread G.W. Haywood

Hi all,

On Sun, 3 Sep 2000, [UTF-8] Ričardas Čepas wrote:

> On Fri Sep  1 23:18:13 2000 -0400 Eric L. Brine wrote:
> 
> This would require unicode capable browser anyway.  Even more,
> Netscape v4 doesn't show these escapes unless you set encoding to utf-8.


There's a rather good document about character set encoding at

http://www.physics.gla.ac.uk/r2h-extras/rtfunicode.html

and some useful background stuff at

http://ppewww.ph.gla.ac.uk/~flavell/charset/

Flavell has done a lot of good work on browser response too, if you
browse around those sites you'll find there's a table there somewhere
which shows how many different browser versions respond to what I'd
call `funny characters'.

See also 'man unicode', 'man utf-8' (even 'man latin-1') on Linux.

73,
Ged.

(And what's all this \342\230\273 stuff?  Looks funny in Pine...:)




Module list in draft "mod_perl Pocket Reference" needs checking

2000-09-03 Thread Andrew Ford

I am just finishing off the "mod_perl Pocket Reference" for O'Reilly.
It should go to production later the month and hopefully be in the
shops in the Autumn.

One section of the book contains a list of the mod_perl-specific
modules on CPAN (including those in the mod_perl distribution, which
of course is itself on CPAN).  This section could do with checking --
it covers about 150 modules, runs to 13 pages and gives a bit more of
a description of each of the modules than the Apache/Perl module list.
I have written summaries of each of the modules based on the
documentation in the modules, my own use of the modules and from
reading the code, however I cannot claim that I have done justice to
every single module I found.  If you wrote one of the Apache/Perl
modules on CPAN, or have a favourite module, you might like to look
through the chapter and see if the description I have given could be
improved on.

The draft chapter is available as a PDF file from:

http://www.refcards.com/download/drafts/modules.pdf

I will be very grateful for any comments, corrections and suggestions.
The cut-off date for making changes is Friday, 15 September.

Andrew
-- 
Andrew Ford,  Director   Ford & Mason Ltd Tel: +44 1531 829900
[EMAIL PROTECTED]  South Wing, Compton HouseFax: +44 1531 829901
http://www.ford-mason.co.uk  Compton Green, Redmarley  Mobile: +44 7785 258278
http://www.refcards.com  Gloucester, GL19 3JB, UK   



New to Apache and need help!

2000-09-03 Thread Z-man


Hi All
Can Anyone here help me out?I'm trying to use the rewrite mod and have
run into a problem.I've added the rewritecond and rules into my config
file and it works if I use www in my url but will not work without it.I'd
rather it worked the opposite way but will settle for both if that's the
best I can do.The conditions I added are as follows:

    Rewritelog logs/rewrite.log
    RewritelogLevel 9 


    RewriteMap   lowercase   int:tolower
    RewriteEngine on 

    RewriteCond   ${lowercase:%{HTTP_HOST}}   !^$
    RewriteCond   ${lowercase:%{HTTP_HOST}}   !^www\.myserver.com$ 
  

    RewriteCond   ${lowercase:%{HTTP_HOST}}   ^(www\.)([^.]+)\.myserver\.com$
    RewriteRule   ^(.+)   ${lowercase:%{HTTP_HOST}}$1   [C]
    RewriteRule   ^(www\.)([^.]+)\.myserver\.com(.*)   /users/$2$3   [L] 

    RewriteCond   ${lowercase:%{HTTP_HOST}}   ^(www\.)[^.]+\.[^.]+\.myserver\.com$
    RewriteRule   ^(.+)   ${lowercase:%{HTTP_HOST}}$1   [C]
    RewriteRule   ^(www\.)([^.]+)\.([^.]+)\.myserver\.com(.*)   /users/$3/$2$4   [L]

Do I need to change anything here or am I missing something?Also If it
makes a difference I'm running apache on win2k.
Thanks for any and all help...
Denis


Dynamic Directory Protection - An authorization related question.

2000-09-03 Thread Simon Wei

Hi:

I am trying to implement a database driven solution for a small university
website (300+ users) and quite happy with Authentication and Authorization
packages provided by mod_perl. However, there doesn't seems to be a solution
to dynamically protect a directory without restarting Apache.

What I will like to do:
Store the URI  need to be protected in the database with the
permitted Groups.

What I have done:
Using  and DBI in httpd.conf, and query the database for the directory
information every time Apache starts.

Problem:
For Authentication and Group Authorization, changes in the database will be
reflected without restarting Apache. Not so for the URI  part of
it.

I have thought about restarting Apache from time to time, but thinking there
must be a "lazier" way with performance consideration.


Thanks for any comments or tips.


Simon Wei





[ANNOUNCE] First AxKit live sites

2000-09-03 Thread Matt Sergeant

I know this isn't the usual form of [ANNOUNCE] messages, and axkit-users
subscribers will have already seen this, but I just wanted people to see a
real live site built on AxKit...

PDA Verticals Corp have just finished building 4 sites dedicated to
vertical markets using PDA's. Owen Stenseth went out on a limb to try out
AxKit for these sites, and he's been following development and doing his
own custom patches as things went along. This weekend they launched the
following 4 sites, and I'm posting the links here so that people can see
real sites that AxKit is being used for:

http://www.pdamd.com
http://www.pdare.com
http://www.pdajd.com
http://www.pdafn.com

-- 


Fastnet Software Ltd. High Performance Web Specialists
Providing mod_perl, XML, Sybase and Oracle solutions
Email for training and consultancy availability.
http://sergeant.org | AxKit: http://axkit.org





Re: New to Apache and need help!

2000-09-03 Thread Jonathan Leto

 Z-man ([EMAIL PROTECTED]) was saying:

> 
>Hi All
>Can Anyone here help me out?I'm trying to use the rewrite mod and have
>run into a problem.I've added the rewritecond and rules into my config
>file and it works if I use www in my url but will not work without
>it.I'd rather it worked the opposite way but will settle for both if
>that's the best I can do.The conditions I added are as follows:
>

Try this, notice the question marks after the (www\.), which shows that
it is optional.

Rewritelog logs/rewrite.log
RewritelogLevel 9

RewriteMap   lowercase   int:tolower
RewriteEngine on
 
RewriteCond   ${lowercase:%{HTTP_HOST}}   !^$
RewriteCond   ${lowercase:%{HTTP_HOST}}   !^www\.myserver.com$
 
 
RewriteCond   ${lowercase:%{HTTP_HOST}}   ^(www\.)?([^.]+)\.myserver\.com$
RewriteRule   ^(.+)   ${lowercase:%{HTTP_HOST}}$1 [C]
RewriteRule   ^(www\.)?([^.]+)\.myserver\.com(.*) /users/$2$3   [L]
 
RewriteCond   ${lowercase:%{HTTP_HOST}}   ^(www\.)[^.]+\.[^.]+\.myserver\.com$
RewriteRule   ^(.+)   ${lowercase:%{HTTP_HOST}}$1 [C]
RewriteRule   ^(www\.)?([^.]+)\.([^.]+)\.myserver\.com(.*)   /users/$3/$2$4
   [L]
> 
>Do I need to change anything here or am I missing something?Also If it
>makes a difference I'm running apache on win2k.
>Thanks for any and all help...
>Denis

-- 
[EMAIL PROTECTED] 
"With pain comes clarity."





Re: New to Apache and need help!

2000-09-03 Thread Z-man

Thanks , That did the trick!
Denis

Jonathan Leto wrote:

>  Z-man ([EMAIL PROTECTED]) was saying:
>
> >
> >Hi All
> >Can Anyone here help me out?I'm trying to use the rewrite mod and have
> >run into a problem.I've added the rewritecond and rules into my config
> >file and it works if I use www in my url but will not work without
> >it.I'd rather it worked the opposite way but will settle for both if
> >that's the best I can do.The conditions I added are as follows:
> >
>
> Try this, notice the question marks after the (www\.), which shows that
> it is optional.
>
> Rewritelog logs/rewrite.log
> RewritelogLevel 9
>
> RewriteMap   lowercase   int:tolower
> RewriteEngine on
>
> RewriteCond   ${lowercase:%{HTTP_HOST}}   !^$
> RewriteCond   ${lowercase:%{HTTP_HOST}}   !^www\.myserver.com$
>
>
> RewriteCond   ${lowercase:%{HTTP_HOST}}   ^(www\.)?([^.]+)\.myserver\.com$
> RewriteRule   ^(.+)   ${lowercase:%{HTTP_HOST}}$1 [C]
> RewriteRule   ^(www\.)?([^.]+)\.myserver\.com(.*) /users/$2$3   [L]
>
> RewriteCond   ${lowercase:%{HTTP_HOST}}   
>^(www\.)[^.]+\.[^.]+\.myserver\.com$
> RewriteRule   ^(.+)   ${lowercase:%{HTTP_HOST}}$1 [C]
> RewriteRule   ^(www\.)?([^.]+)\.([^.]+)\.myserver\.com(.*)   /users/$3/$2$4  
> [L]
> >
> >Do I need to change anything here or am I missing something?Also If it
> >makes a difference I'm running apache on win2k.
> >Thanks for any and all help...
> >Denis
>
> --
> [EMAIL PROTECTED]
> "With pain comes clarity."




Re: HTML Template Comparison Sheet ETA

2000-09-03 Thread Sam Tregar

On Mon, 28 Aug 2000, Nelson Correa de Toledo Ferraz wrote:

>  "This approach has two problems: First, their little language is
>   crippled. If you need to do something the author hasn't thought of, you
>   lose. Second: Who wants to learn another language? You already know
>   Perl, so why not use it?"

To which HTML::Template responds: "Sure you know Perl, but does the HTML
designer you're working with?"  HTML::Template has a simple, HTML-esque
syntax for its template files that is aimed at HTML designers.  Keep the
Perl in your modules and keep the HTML in your template files.  Go the
other direction and soon enough you've got your programmers changing 
font colors.

You can put that in your sheet and, er... smoke it?
-sam





StatINC Question

2000-09-03 Thread Warren D. Johnson

Regards all,

I've installed mod_perl and latest version of apache.  Everything seems to
be working fine.

I have set StatINC as the PerlInitHandler in my httpd.conf so as to stat()
file and libraries which are are dependencies of scripts handled by the
modperl handler.  In addition, I have a startup file which is run early on
in my .conf to add another lib to the @inc (or is it %INC?) variable so
StatINC will check in the necessary directories.

Here is my problem:  StatINC seems to work fine several times after I
restart the server but then at some point begins to act funky.  I'll reload
a page and either/or a source file will get reloaded every time (despite
it's time not changing)  or i'll get different versions of the page popping
up (versions which existed in previous revision of my source file).  Its
from looking at my error_log that different httpd child processes are
catching the different browser requests and reloading the source files.
It is extremely frustrating to say the least as I can't understand what the
problem really is.  Logic would dictate that if a httpd child process
received a request to handle a mod-perl-script that StatINC would tell the
server to hold up for a second while it recompiles these modules and then
let it go on it's way.  It's almost as if each child process maintains it's
own seperate cached version of the modperl-covered scripts.  Is this the
case?

Does anyone have any ideas?





Re: Dynamic Directory Protection - An authorization related question.

2000-09-03 Thread Jonathan Leto

> 
> Problem:
> For Authentication and Group Authorization, changes in the database will be
> reflected without restarting Apache. Not so for the URI  part of
> it.
> 
> I have thought about restarting Apache from time to time, but thinking there
> must be a "lazier" way with performance consideration.

What about a cron script that creates .htaccess files in the needed directories ?

> 
> 
> Thanks for any comments or tips.
> 
> 
> Simon Wei
> 
> 

-- 
[EMAIL PROTECTED] 
"With pain comes clarity."





Re: Dynamic Directory Protection - An authorization related question.

2000-09-03 Thread Michael Robinton

> 
> I am trying to implement a database driven solution for a small university
> website (300+ users) and quite happy with Authentication and Authorization
> packages provided by mod_perl. However, there doesn't seems to be a solution
> to dynamically protect a directory without restarting Apache.
> 
> What I will like to do:
> Store the URI  need to be protected in the database with the
> permitted Groups.
> 
You can do that by changing the user portion of that authenticates the 
credentials and returns the session key. Place the allowed directories in 
the encrypted key. In the auth- session key portion you can check all 
kinds of things like the allowed path, session expiration, specific files 
you want disallowed in various directories, etc...



Re: Dynamic Directory Protection - An authorization related question.

2000-09-03 Thread Simon Wei

Thanks guys!
(Michael Hanisch, Michael Robinton, Jonathan Leto)

I think the session key idea will work for me, just hoping there are a
generic solution out there. This is a typical problem why people turn to
LDAP, but LDAP is just so horrible to administer.

Regards,

Simon Wei

>
> > Hi:
> ReHi
>
> > packages provided by mod_perl. However, there doesn't seems to be a
solution
> > to dynamically protect a directory without restarting Apache.
> >
> > What I will like to do:
> > Store the URI  need to be protected in the database with the
> > permitted Groups.
> >
> > What I have done:
> > Using  and DBI in httpd.conf, and query the database for the
directory
> > information every time Apache starts.
> >
> > Problem:
> > For Authentication and Group Authorization, changes in the database will
be
> > reflected without restarting Apache. Not so for the URI  part
of
> > it.
> Hmm, sorry if this sounds stupid, but...
> What keeps you from querying the DB on every request, i.e. in a
> custom-built Authen/Authz-handler?
> On a site with a small userbase, the overhead should be neglectable.
> Besides, you can still cache the query results in memory and expire them
> after a certain time.
> Or did I miss something here?
> BTW: There are several modules on CPAN that do what you want (if I did get
> what you want, that is ;)
>
> Regards,
> Michael.
>
>
> > I have thought about restarting Apache from time to time, but thinking
there
> > must be a "lazier" way with performance consideration.
> >
> >
> > Thanks for any comments or tips.
> >
>




Executing slower and slower

2000-09-03 Thread Marek W

Hi
My perl_mod script that uses SQL Postgres Database works slower by 5% each
time it is executed. After 20th invocation of the script it works 2 times
slower. It is very simple script that uses Apache::DBI, it connects to the
database, retrieves some data and disconnects.
Could you explain it to me? I looked for the solution to my problem but I
couldn't find the answer.
Mark




Re: StatINC Question

2000-09-03 Thread Matt Sergeant

On Sun, 3 Sep 2000, Warren D. Johnson wrote:

> Here is my problem:  StatINC seems to work fine several times after I
> restart the server but then at some point begins to act funky.  I'll reload
> a page and either/or a source file will get reloaded every time (despite
> it's time not changing)  or i'll get different versions of the page popping
> up (versions which existed in previous revision of my source file).  Its
> from looking at my error_log that different httpd child processes are
> catching the different browser requests and reloading the source files.
> It is extremely frustrating to say the least as I can't understand what the
> problem really is.  Logic would dictate that if a httpd child process
> received a request to handle a mod-perl-script that StatINC would tell the
> server to hold up for a second while it recompiles these modules and then
> let it go on it's way.  It's almost as if each child process maintains it's
> own seperate cached version of the modperl-covered scripts.  Is this the
> case?

Yes, this is the case. Each child has its own copy of the compiled
module. When you initially start the server, if your modules are
pre-loaded, initially this memory will be copy-on-write shared across each
child (i.e. only one area of memory used and shared between the children),
but when you reload them using something like StatINC, that sharing
disappears.

You could try PerlFreshRestart and issue a graceful restart if this isn't
the type of reload you want.

-- 


Fastnet Software Ltd. High Performance Web Specialists
Providing mod_perl, XML, Sybase and Oracle solutions
Email for training and consultancy availability.
http://sergeant.org | AxKit: http://axkit.org