Re: Yet more code (Was: Re: A nifty code sample to share)

2002-09-22 Thread Brat Wizard
Of course, you could also put just the info to be included into a separate file and allow it to be included at a judicious moment... (nah, that would be too easy ;) But the one thing that _doesn't_ allow for, and the reason why I myself have been working on the problem-- is putting together

Re: Yet more code (Was: Re: A nifty code sample to share)

2002-09-21 Thread Brat Wizard
A follow-up to my last post... adding this line to the render func: $tmpl =~ s/__\((.*?)\)__/%=($1)%/gm; # fixup embedded tests Allows this construct to be used: __(__F_ONSALE__?'YES':'NO')__ These constructs also work as expected: Item on sale? Yes or No: __(__F_ONSALE__?'YES':'NO')__

Re: Question re $asp (eg. $self)

2002-09-20 Thread Brat Wizard
Yup, answer: $Response-{asp} On Friday 20 September 2002 01:27 am, Brat Wizard spewed into the ether: Is there an easy way to access the $asp object (eg. $self) from within the global.asa file? -- Check out

Re: Yet more code (Was: Re: A nifty code sample to share)

2002-09-20 Thread Brat Wizard
Yes, but extrordinarily easy-to-do and it didn't break nuthin ;) On Friday 20 September 2002 02:27 pm, you muttered: Brat Wizard wrote: # picture else { $$hash{$token} = sprintf($fmt, $$hash{$token

Re: Is Apache::ASP compatible with Windows ASP?

2002-09-20 Thread Brat Wizard
No, not exactly. Apache::ASP could better be described as a reimplementation of the ASP paradigm in a Perl/Mod_Perl environment. It would be a better thing to say Apache::ASP is ASP-like. If you are familiar with one you will be probably be comfortable working in the other, assuming you know

Re: Yet more code (Was: Re: A nifty code sample to share)

2002-09-20 Thread Brat Wizard
Right, its almost as if one would want a pre-processing stage of not the output, but of the content. The current model was not built to be easily extendable to this as there is only one sub per XMLSubs that gets called, but what you would really want is something like: sub my::sub_pre()

Problem passing complex structure in XMLSubs args...

2002-09-18 Thread Brat Wizard
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 doesn't seem to work, all

Re: Problem passing complex structure in XMLSubs args...

2002-09-18 Thread Brat Wizard
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

Re: dynamic module

2002-09-17 Thread Brat Wizard
On Tuesday 17 September 2002 01:54 am, Stephen Bardsley spewed into the ether: Hi John: It's ironic how similar our applications seem! I have a perl module that wraps around DBI, and get this, it is called Db.pm also. Hmm- I contacted the naming committee, they took the matter under

A nifty code sample to share

2002-09-17 Thread Brat Wizard
I've been meaning for a long time to release some code samples-- here is one I especially like for making menus and navbars in html-- same code will work for either. A caveat: I use several custom modules which hides some stuff- most notably the Page object, which is basically a hash of

Re: A nifty code sample to share

2002-09-17 Thread Brat Wizard
Um- minor correction- I slightly misspoke-- I was confusing this with another module I have. This example _only_ matches the URL, CAPTION, and NAME fields from the hash. Sorry for any confusion. John On Tuesday 17 September 2002 03:27 am, Brat Wizard spewed into the ether: I've been

Re: dynamic module

2002-09-16 Thread Brat Wizard
I want my variable to be valid and defined for the duration of a Session. Okay, that's what the session object is for, as you appear to already know. ;) example) is to use Apache::DBI. Apache::DBI will override the normal DBI I am using and have used Apache::DBI with good results. I'm

Re: Passing form input to subroutine

2002-09-09 Thread Brat Wizard
In my applications, I generally scoop up the form into a hash and then pass it as a hash ref. eg: my $form = $Request-Form(); myfunc($form); sub myfunc { my $form = shift; print Use like this: , $form-{key}; print Or like this: , $$form{key}; } Hope this helps

Answer-- Re: Q: How to access Apache Request ($r) from Apache::ASP??

2002-08-11 Thread Brat Wizard
Then in your Apache::ASP code you can access it thusly: my $r = Apache-request; my $foo = $r-dir_config('foo'); print foo = $foo; Thanks to Ellers for giving me the clue that allowed me to unravel the answer. Regards, John On Friday 09 August 2002 10:50 am, Brat Wizard spewed into the ether: Q: How

Re: virtual urls

2002-06-01 Thread Brat Wizard
It can be done with mod_rewrite. Go to apache.org and read through the mod_rewrite docs. Regards. John Whitten [EMAIL PROTECTED] Wizard.Org, Inc. On Saturday 01 June 2002 04:02 am, Ellers spewed into the ether: Hi All This is only partly an ASP question, but any help appreciated: If I

Re: HELP: Dealing with multiple servers

2002-01-22 Thread Brat Wizard
Hmm- all of these sound like good suggestions in general-- I will definately take a look at that today. Question tho- my situation is one of the state directory apparently becoming corrupted (as evidenced by strange hanging behavior of site scripts when the problem manifests)... what you

OT HELP/ADVICE: Experiences with db's serving lots of pages

2002-01-22 Thread Brat Wizard
Howdy-- This is an off-topic post-- feel free to ignore it. I know the folks on this list are active web developers and generally smart people and this is a problem that has been vexing me for some time now-- I am at the point of having to do _something_ and I could use some advice... I am

Using Apache::ASP with offline scripts- HOW???

2001-12-09 Thread Brat Wizard
Howdy- I'm wondering if there is a neat and clever way to utilize the functionality of Apache::ASP in an offline capacity... This isn't as hair-brained a request as it might seem-- I am attempting to create a background processor script to dig through a database and send html-formatted email