Re: [PHP] normal for Apache to hang?

2001-03-15 Thread Christian Reiniger
0 1.2 0:05 mysqld Apache isn't hanging - it's just keeping its existing subprocesses at hand in case some new request comes in. If apache would spawn a new subprocess on each request it would be painfully slow. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Pretty

Re: [PHP] Statistics function

2001-03-15 Thread Christian Reiniger
imply use "ab" (the benchmarking app that comes with apache)? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Pretty cool, the kind of power information technology puts in our hands these days. - Securityfocus on probing 3600 hosts for known problems in 3 weeks -- P

Re: [PHP] Creating Files Windows vs Unix

2001-03-15 Thread Christian Reiniger
supose I need a few lines of code that first test > if my file exist and then if it doesn't I will have to create it using > the touch command?? Any other ideas? If I'm right this won't work as well. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Pretty

Re: [PHP] Executing a string with both html and php inside it..

2001-03-15 Thread Christian Reiniger
std.html for example looks like this (it's a german site): Bearbeiten   Such an approach is IMHO easy to understand and handle, well-structured etc. -- Christian Reiniger LG

Re: [PHP] List of Directories with in a Directory

2001-03-15 Thread Christian Reiniger
s topic check the manual -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Pretty cool, the kind of power information technology puts in our hands these days. - Securityfocus on probing 3600 hosts for known problems in 3 weeks -- PHP General Mailing List (http://www.php.net/)

Re: [PHP] FAQ

2001-03-16 Thread Christian Reiniger
g. Yep. But if there's a FAQ the answers can be greatly simplified :) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Google results 1-10 of about 142,000,000 for e. Search took 0.18 seconds. - http://www.google.com/search?q=e -- PHP General Mailing List (http://www.php.net

Re: [PHP] Finding the depth

2001-03-16 Thread Christian Reiniger
t; > if (isset($return)) >return implode('/', $return); > } Won't work for the (perfectly valid) URL http://somewhere.de/lvl1lvl2//lvl3/foo.bar it's quite unlikely though that someone enters such a thing -- Christian Reiniger LGDC Webmaster (http://sun

Re: [PHP] Finding the depth

2001-03-16 Thread Christian Reiniger
tools can do automatic link conversion (absolute->relative). So I'd just go with absolute paths. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Google results 1-10 of about 142,000,000 for e. Search took 0.18 seconds. - http://www.google.com/search?q=e -- PHP General Mail

Re: [PHP] FAQ - Newbie perspective

2001-03-16 Thread Christian Reiniger
realy). In such a situation the correct thing is IMO to actually spend these 10-15 minutes and then post your code and ask the list how this could be done better. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Google results 1-10 of about 142,000,000 for e. Search took

Re: [PHP] use strict alternative

2001-03-19 Thread Christian Reiniger
On Monday 19 March 2001 12:53, you wrote: > php variables are local by default. point missed :) "use strict" forces you to declare variables before you use them. AFAIK there's no such thing in PHP (unfortunately). -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgd

Re: [PHP] Problems with Linux PHP

2001-03-19 Thread Christian Reiniger
on the distribution you're using and (sometimes) on what you selected during installation of the distro. Have a look at the manual page for crypt(PHP). It says something about constants being defined depending on which encryption modes are available. -- Christian Reiniger LGDC Webmaster (http

Re: [PHP] weeks revisited

2001-03-20 Thread Christian Reiniger
do this. Just get the current week via getdate() and do an if ($RecordWeek == $CurrentWeek) Highlight() on each record. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Those who will not reason, are bigots, those who cannot, are fools, and those who dare not, are slaves. - Ge

Re: [PHP] phpinfo() doesn't list compiled --with

2001-03-20 Thread Christian Reiniger
On Tuesday 20 March 2001 14:59, you wrote: > I compiled php --with-pgsql, but phpinfo() doesn't list that.is > this a problem with php.ini? Are you sure you didn't have a typo in that? Configure silently ignores unknown opitons. -- Christian Reiniger LGDC Webmaster (http:/

Re: [PHP] header( )

2001-04-14 Thread Christian Reiniger
3D'post' that is > > sending client data to = the server, you will have no control over > > this at all... > > There are in fact two different servers: the web server and the PHP > server. IMO it should be possible for the PHP server, executing PHP

Re: [PHP] Forcing Case

2001-04-14 Thread Christian Reiniger
On Saturday 14 April 2001 09:15, you wrote: > Is there any way to force case...like if I have a string and want it to > appear in all lowercase (or uppercase, God forbid)? http://www.php.net/strtolower -- Christian Reiniger LGDC Webmaster (http://sunsite.d

Re: [PHP] Want a Good Book for Ref on PHP

2001-04-16 Thread Christian Reiniger
ving examples) and later on (giving more complex examples :). But (1) never forget to have the online manual at hand and (2) check phpbuilder.com etc for new interesting articles from time to time -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) (A)bort (R)etry (P)retend thi

Re: [PHP] General WebServer Question?

2001-04-16 Thread Christian Reiniger
mes with "ab" (ApacheBench). -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) (A)bort (R)etry (P)retend this never happened ... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTE

Re: [PHP] RFC: Storing User Info

2001-04-17 Thread Christian Reiniger
. At least there are no real alternatives yet. > - What about when the user forgets their login? Just fetch the > info from DB and mail it out to the (registered) email address? Yup -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Never doubt that a small g

Re: [PHP] php like cgi

2001-04-17 Thread Christian Reiniger
php -q Are you 100% sure that it's /bin/php ? That's a pretty unusual location for PHP to be installed in. /usr/bin/php or /usr/local/bin/php are the common ones > > echo "Content-type: text/html\n\n"; unneccessary if you leave out the -q -- Christian Reiniger LGD

Re: [PHP] Speed of MySQL connections - Socket vs. Non-Socket

2001-04-17 Thread Christian Reiniger
e best way to do some > benchmarking wrt. this? (Links are fine) run "ab" (comes with apache) on two scripts, one using method A repeatedly, the other using method B repeatedly -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Never doubt that a small group of thou

Re: [PHP] cgi vs. module

2001-04-17 Thread Christian Reiniger
run it as a cgi > program? Modules are *way* faster (I haven't done benchmarks myself, but heard of a 10x speed increase compared to CGIs) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Never doubt that a small group of thoughtful, committed people can change the world...

Re: [PHP] baffled :<:

2001-04-17 Thread Christian Reiniger
ard to "A", then setting $card to "B", then to "C" and finally to "D". In other words: in each iteration you overwrite all previous values > I have script identical to this that works perfectly .. only difference > is this one has different names for the

Re: [PHP] How do i include ASP script into PHP...??!

2001-04-18 Thread Christian Reiniger
pt > itself. fopen ("/path/to/asp/script.asp", "r"); -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) A - American Association Against Acronym Abuse -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additiona

Re: [PHP] Persistent connection & many scripts ?

2001-04-18 Thread Christian Reiniger
> Simply using pg_pconnect() (without saving the connection ID) should be just as fast and more failproof -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) A - American Association Against Acronym Abuse -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAI

Re: [PHP] print_r style array content

2001-04-18 Thread Christian Reiniger
her than writing a function? Many thanks. serialize () A bit hard to read, but really useful nevertheless -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) A - American Association Against Acronym Abuse -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EM

Re: [PHP] Is it possible to parse a variable by character?

2001-04-18 Thread Christian Reiniger
also want to allow "minus" signs. See the manual section on the regular expression functions (Perl-compatible) for an explanation -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) A - American Association Against Acronym Abuse -- PHP General Mailing List (http://www.php

Re: [PHP] Is it possible to parse a variable by character?

2001-04-18 Thread Christian Reiniger
That, and because the dash needs to be the last character in the character class: $f_loc_new = ereg_replace("[^_a-z0-9.-]", "", $f_loc_name); -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) A - American Association Against Acronym Abuse -- PHP General Mailing L

Re: [PHP] Regular Expression

2001-04-18 Thread Christian Reiniger
uot; . $Matches [1] . "'"; } looks a bit perverse (because the [] brackets have special meaning in regular expressions), but you'll get used to it :) Also have a look at the description of the perl regex syntax in the manual -- Christian Reiniger LGDC Webmaster (http://sun

Re: [PHP] Regular Expression

2001-04-18 Thread Christian Reiniger
('/\[([^\]])\]/', $Subject, $Matches)) { > echo "Found it : '" . $Matches [1] . "'"; > } Ooops. The expression should read '/\[([^\]]+)\]/' -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Even idiots can handle computers,

Re: [PHP] regex and mysql - looking for opinions.

2001-04-19 Thread Christian Reiniger
() or the magic_quotes_gpc setting will do fine for strings. For numbers just cast them to int before inserting 'em in the query: $MyNum = (int) $MyNum; $Query = "INSERT INTO foo (intval) VALUES ($MyNum)'; -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) /* you are no

Re: [PHP] Regular Expression

2001-04-19 Thread Christian Reiniger
e ".+" part will match as much as possible. Example: For "This [is a] string [with] multi [brack]ets" it will match "is a] string [with] multi [brack" A better solution would be "/\[(.+?)\]/" The '?' after the '+' tells it to match

Re: [PHP] HTMLSpecialchars

2001-04-19 Thread Christian Reiniger
t has a shorter name *g* and (2) it really takes care of *all* HTML specialities (e.g. umlauts) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) /* you are not expected to understand this */ - from the UNIX V6 kernel source -- PHP General Mailing List (http://www.php.net/) To unsu

Re: [PHP] SESSIONS, a weird, funny yet strange error happens to wrong people...

2001-04-19 Thread Christian Reiniger
file exists should be impossible for open (..., O_RDWR) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) REALITY.SYS corrupted ... reboot Universe [Y,n]? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECT

Re: [PHP] Can PHP run without php.ini?

2001-04-19 Thread Christian Reiniger
er (I have a backup though :) and restarted > the computer - you know what, the PHP works perfectly and show the > default settings! How come? Because it uses the default settings :) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) REALITY.SYS corrupted ... reboot Universe [Y,n

Re: [PHP] Which is better coding style...

2001-04-19 Thread Christian Reiniger
= "this"; >break; > In other words, is it good practice to exit out of a block (any > block... not just switch; if, for, while) prematurely as demon- > strated in the first example? Or should you do it as demon- > strated in the second example? Well, what is mor

Re: [PHP] Which is better coding style...

2001-04-20 Thread Christian Reiniger
ut of a function somewhere in the middle leads to > unmaintainable code See example above. > But, as with the indenting and bracket placing, > it is a matter of religion. Now that's something we agree on :) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Google re

Re: [PHP] ENUM or SET and PHP

2001-04-20 Thread Christian Reiniger
ing them and pouring boiling water over the resulting dust. And when you're done with that, take the manual and read it. Thus you will find enlightenment. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Google results 1-10 of about 142,000,000 for e. Search took 0.18

Re: [PHP] `AM_PROG_LIBTOOL' not found in library

2001-04-20 Thread Christian Reiniger
to accept ANSI C... (cached) none needed > checking for ranlib... (cached) ranlib > checking whether gcc and cc understand -c and -o together... (cached) > yes checking whether ln -s works... (cached) yes > > what do you think is going on??? Well, according to that log everythi

Re: [PHP] ENUM or SET and PHP

2001-04-21 Thread Christian Reiniger
ulting dust. >> >> And when you're done with that, take the manual and read it. >> >> Thus you will find enlightenment. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Google results 1-10 of about 142,000,000 for e. Search took 0.18 seconds. - ht

Re: [PHP] pumping database dump in mysql

2001-04-22 Thread Christian Reiniger
On Saturday 21 April 2001 15:39, Peter Van Dijck wrote: > Hi, > I want to write a script that takes a mysql dump file and pumps it into > the database. What about simply using phpMyAdmin? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Software is like sex: t

Re: [PHP] Getting a binary file from URL

2001-04-23 Thread Christian Reiniger
s before you rely on it. I once did this with (IIRC) PHP 4.0.1 and it read up to several hundred junk bytes after encountering EOF. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "World domination. Fast." (Linus Torvalds about Linux) -- PHP General Mailing List (http:

Re: [PHP] anyone know of a dicitionary for bad site content?

2001-04-23 Thread Christian Reiniger
ort version of "student" in this context, but how can a filter differentiate between that and the "sex bomb" meaning? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Even idiots can handle computers, and many do. -- PHP General Mailing List (http://www.php.net/

Re: [PHP] How to turn off warnings ???

2001-04-24 Thread Christian Reiniger
hese are not > fatal - is there any way to turn them off? Warnings are not fatal as such, but they often give hints that you have a bug somewhere. Correct your code. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) ...1000100011010101101010110100111010113...

Re: [PHP] Fatal Errors and Error Handling

2001-04-24 Thread Christian Reiniger
cceptable solution. I *MUST* return a valid XML message > in a predefined format. If not, I am violating the standard we are if (@foo_bar (42, 4711) == ERROR_CODE) { PrintXMLErrorMessage (); } else { GoOnProcessing (); } -- Christian Reiniger LGDC Webmaster

Re: [PHP] Fatal Errors and Error Handling

2001-04-24 Thread Christian Reiniger
l be ignored. -- The @ operator suppresses any error *message*, but leaves the return value intact. Just imagine that with your interpretation in the following snippet $conn = @mysql_connect(...) $conn would always be set to 0... -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc

Re: [PHP] Fatal Errors and Error Handling

2001-04-24 Thread Christian Reiniger
tion call. Well, we both are right. The snippet I suggested (top of this mail) *will* work, because the @ operator doesn't mess with the return value of the function. A custom error handling function installed via set_error_handler() will *not* work because it won't get the error code.

Re: [PHP] Fatal Errors and Error Handling

2001-04-24 Thread Christian Reiniger
ct, because return value evaluation can be used instead (unless some functions never signal errors via their return value). Aside from that you're right. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) I sat laughing snidely into my notebook until they showed me a PC run

Re: [PHP] Fatal Errors and Error Handling

2001-04-25 Thread Christian Reiniger
ng from a (quite common) error. Corrupted data is something to be expected, something that even has to be considered *normal* when developing such a thing. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Software is like sex: the best is for free" -- Linus Tor

Re: [PHP] How to turn off warnings ???

2001-04-25 Thread Christian Reiniger
return stripslashes ($GLOBALS[$Name]); else return $GLOBALS[$Name]; } else { return ""; } } $MyVar = pbGetGlobal ("foobar"); if ($MyVar == 0) {...} -- Christian Reiniger LGDC Webmaster (http://suns

Re: [PHP] Variable (naming them) Functions.

2001-04-27 Thread Christian Reiniger
er: $foo = create_function (...); $FNames [$var] = $foo; function delta ($FuncName, $args) { return ${$FNames[$FuncName]} ($args); } ) But such a thing is an ugly hack and I'm sure you don't need it. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion

Re: [PHP] explode won't explode

2001-04-27 Thread Christian Reiniger
if (($size != "") && ($size != "n/a")) { >$sizearry = explode(",", $size); >while (list($key,$value) = each($sizearry)) { >$size_option_block .= "$size\n"; Why are yo using $size (the unexploded string) in the last line? -- C

Re: SV: [PHP] PHP Book?

2001-04-27 Thread Christian Reiniger
e online manual is much quicker to search and much more up to date (the book only covers PHP3) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion error - see error 032 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED]

Re: [PHP] Syntax for select statement

2001-04-27 Thread Christian Reiniger
n, will this cause an error in my select statement? If the answer is > "Yes", can someone give me a more robust way of writing it using PHP? Yes. use addslashes() -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion error - see error 032 -- PHP Gene

Re: SV: [PHP] PHP Book?

2001-04-27 Thread Christian Reiniger
there's a second edition" at the beginning). I own the first edition and described that. > Please read books more carefully and don't pester this mailing list > with your nonsense comments. I mean that book with a foreword by Andi > Gutmans. Well, you just said "Core

Re: [PHP] Is PHP code software?

2001-04-27 Thread Christian Reiniger
term was coined to differentiate these instructions from hardware-i.e., the physical components of a computer system. A set of instructions that directs a computer's hardware to perform a task is called a program, or software program." http://www.britannica.com/eb/article?eu=2214&

Re: SV: [PHP] PHP Book?

2001-04-28 Thread Christian Reiniger
ologize for having an opinion and telling others about it. This list is a *good* place for book reviews, because (1) reviews help (future) readers to choose the right book for them and (2) because bad reviews (such as mine) can be easily corrected (as you did) here. -- Christian Reiniger LGDC W

Re: [PHP] php sucks

2001-04-29 Thread Christian Reiniger
tainly not "defamation", just like Bill Gates jokes are not defamation :) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Software is like sex: the best is for free" -- Linus Torvalds -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mai

Re: [PHP] template solutions?

2001-04-30 Thread Christian Reiniger
say. > Ease of use? I want to let *other people* customize the web page to > some extent, but surely do not want to require them to learn PHP. Also in this regard. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) CPU not found. retry, abort, ignore? -- PHP General Mailing

Re: [PHP] Working with numbers

2001-05-03 Thread Christian Reiniger
rin to a floating-point number and PHP will do the rest. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Drink wet cement. Get stoned. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]

Re: [PHP] Shorten String or encode/decode a string

2001-05-04 Thread Christian Reiniger
data around on each request, store it in a database and just pass around the record ID -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) ...to paraphrase Churchill, while representative democracy may be terrible, it's still the best system that large corporations can buy. - D

Re: [PHP] Array Assignment

2001-05-04 Thread Christian Reiniger
. And as you can only assign other single characters to a single char, the first char of "pass" is used. > echo "$first[$second]";// prints: P That should be a lowercase 'p' (see above) Summary: You thought too complex and thus stumbled over another feature o

Re: Re[2]: [PHP] Netscape and post

2001-05-05 Thread Christian Reiniger
; > That's exactly what he was saying. Change this to > <-- Action is set Who cares about some field named "action"? The problem is the "action" *attribute" of the tag - the thing responsible for telling the browser where to send the data. You le

Re: [PHP] URL redirection

2001-05-07 Thread Christian Reiniger
On Monday 07 May 2001 20:04, elias wrote: > > location = "hello-world.htm"; > > > can be used even if header is already sent! But only works if (a) the browser supports Javascript, (b) supports this JS construct and (c) has Javascript enabled. -- Christian Rein

Re: [PHP] FILE () STRIPS BLANKS FROM THE ARRAY - HOW CAN I STOP IT

2001-05-07 Thread Christian Reiniger
Line'" ? Then of course you don't see the blanks - you're looking at HTML code. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion error - see error 032 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTE

Re: [PHP] Large Memory Problem

2001-05-07 Thread Christian Reiniger
est way: Use wget (as others already mentioned) (2) General way to avoid memory overflow on such a thing: Stream the data to disk, i.e. read n bytes, write 'em to disk, repeat. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion error - see error 032 -- PHP

Re: [PHP] variable functions: empty/isset/unset invalid?

2001-05-07 Thread Christian Reiniger
; In otherwords, only these few functions aren't working as "variable > > functions" but result in a "Fatal Error" instead. Why? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion error - see error 032 -- PHP General Mailing Lis

Re: [PHP] help with fgets

2001-05-07 Thread Christian Reiniger
ight now it interprets the i in the brackets as bareword, assumes a string is meant and thus interprets it as $photos ['i']. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Error 032: Recursion error - see error 032 -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] no html tags in php via form get

2001-05-08 Thread Christian Reiniger
On Tuesday 08 May 2001 13:55, Alexander Bierbrauer wrote: > Hi people, > > is there a way to check a string, which is passed by a form via GET,for > html tags?? > Does anyone know some code or anything else?? strip_tags() -- Christian Reiniger LGDC Webmaster (http://sunsite.

Re: [PHP] OT question..

2001-05-08 Thread Christian Reiniger
On Tuesday 08 May 2001 16:40, Kelly Meeks wrote: > Hey folks, > > What language is associated with a web page with a .epl extension? Could be embedded perl (Perl embedded in HTML woughly the way PHP is) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) What luck for t

Re: [PHP] OT question..

2001-05-08 Thread Christian Reiniger
On Tuesday 08 May 2001 18:13, [EMAIL PROTECTED] wrote: > > Christian Reiniger > > LGDC Webmaster (http://sunsite.dk/lgdc/) > > > > What luck for the rulers that men do not think. > > > > - Adolf Hitler > > Could you please remove that signature.

Re: [PHP] OT question..

2001-05-08 Thread Christian Reiniger
e into the sig to clear out the misunderstandings that could easily happen. EOT, ok? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) What luck for the rulers that men do not think. - Adolf Hitler Note: This quote is not meant to be offensive, it is meant to make people think, to le

Re: [PHP] any way to get backslashes through in preg_replace?

2001-05-09 Thread Christian Reiniger
On Wednesday 09 May 2001 01:06, Michael Geary wrote: > $replaceIt = array("\\341","\\116"); > By the way, when I pass: > > $replaceIt = array("341","116"); > > I get: > > "this is the \\341 and this is the \\116&qu

Re: [PHP] string varable...

2001-05-09 Thread Christian Reiniger
On Wednesday 09 May 2001 07:46, Vegard wrote: > Does anybody know how much text can be stored in a variable og type > string? Typically about 2^(sizeof(int) * 8 - 1) chars. On a normal 32 Bit machine that's 2 Gig, on a 64Bitter, one moment, 9223372036854775808 chars -- Christian Re

Re: [PHP] passing parameters in the url using forward slashes

2001-05-09 Thread Christian Reiniger
ion It's quite simple. Read the tutorial "Building dynamic websites with search engines in mind" on phpbuilder.com. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) REALITY.SYS corrupted ... reboot Universe [Y,n]? -- PHP General Mailing List (http://www.php.net/

Re: [PHP] Identifying input type="file"

2001-05-09 Thread Christian Reiniger
ing the form. > > Using $HTTP_POST_VARS does not seem to recognize this type of input > field. Is there another method? > > I do have the form as: > > and I can catch all the other form elements without a problem. Re-Read the chapter on file uploads in the manual. -- Christia

Re: [PHP] Search a string between

2001-05-09 Thread Christian Reiniger
27;o' and '>'" You're looking for something like this: $Text = preg_replace ('/<(foo)>(.*?)<\/\\1>/', '$2', $Text); -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) REALITY.SYS corrupted ... reboot Universe [Y,n]? -

Re: [PHP] forcing error documents

2001-05-09 Thread Christian Reiniger
this did not work with PHP 3, but I've found > nothing about PHP 4. Works fine here: function pbHTTP_404 () { header ("HTTP/1.0 404 Not Found"); include ('404.html'); exit (); } -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/)

Re: [PHP] Apache error when installing PHP 4.0.5

2001-05-10 Thread Christian Reiniger
I have apache already installed? I have a Cobalt Raq3 > >with > >apache already installed. > > you need to recompile apache too, unless you want to run php as cgi, > in which case you just leave out the --with-apache part --with-apxs should work fine without recompiling apach

Re: [PHP] Strange

2001-05-10 Thread Christian Reiniger
erid; <--- new line > > Now, by my reasoning, the new line should't ever be executed, and if it > were, it should kick out an error. So, what is going on here? header () just adds a line to the HTTP headers. you can call it as often as you want. -- Christian Reiniger LGDC Webmas

Re: [PHP] StripSlashes

2001-05-11 Thread Christian Reiniger
rub_error = scrub_slashes($email, > $first_name, etc) Hmm, I think someone else answered that already. But another thing I miss in your code is the use of 'global' (See http://php.net/manual/en/language.variables.scope.php) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lg

Re: [PHP] Multiple ASP 2 PHP conversion

2001-05-12 Thread Christian Reiniger
hp'` ; do asp2php $i ../dest/$i done should do it in any decent environment (i.e. any Unix flavor :) -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Install once, run forever. Linux. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED]

Re: [PHP] Hidden Input and Quotes?

2001-05-12 Thread Christian Reiniger
o MySQL. The slashes will not show > up in MySQL. The browser converted the " into ", and PHP for some > reason (I still don't know why) adds slashes before your ' and " The reason is that in your php.ini there is an entry magic_quotes_gpc = on set this to 'off&

Re: [PHP] Pushing to Multidimensional Arrays.

2001-05-15 Thread Christian Reiniger
'parentId']; > $stack[]['name'] = $menuArray[$rowID]['name'];A > > obviously the array's internal pointer will increment and it will write > to the next element. $Foo = array (); $Foo['id'] = $menuArray[$rowID]['id']; $Foo[&#x

Re: [PHP] detecting HTML tags

2001-05-15 Thread Christian Reiniger
and send it appropriately. if (strstr ($text, '<')) { UseHTML ($text); } else { UsePlaintext ($text); } -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) The most exciting phrase to hear in science, the one that heralds new discoveries, is not "Eureka",

Re: [PHP] detecting HTML tags

2001-05-15 Thread Christian Reiniger
> Is there a way to detect the presence of HTML tags? > > > I'm rolling my own mailing program and want it to detect the HTML > > > if present and send it appropriately. > > > > if (strstr ($text, '<')) { > > UseHTML ($text); > > }

Re: [PHP] nested functions

2001-05-16 Thread Christian Reiniger
ted > auxiliary functions direct. What about using classes instead of outer functions? Classes provide rather nice (nestable) scoping. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Software is like sex: the best is for free" -- Linus Torvalds -- PHP General Mailing

Re: [PHP] Uptime script?

2001-05-16 Thread Christian Reiniger
8:55pm up 45 days, 13:42, 1 user, load average: 0.07, 0.03, 0.00 -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) ...1000100011010101101010110100111010113... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional com

Re: [PHP] while loops [ newbie ]

2001-05-17 Thread Christian Reiniger
le http://php.net/foreach http://php.net/fopen http://php.net/fwrite Should get you started. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) ...1000100011010101101010110100111010113... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL

Re: [PHP] Re: removing PHP

2001-05-17 Thread Christian Reiniger
p;reinstall apache. Did you do that? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Pretty cool, the kind of power information technology puts in our hands these days. - Securityfocus on probing 3600 hosts for known problems in 3 weeks -- PHP General Mailing List (http:

Re: [PHP] Performance issue

2001-05-17 Thread Christian Reiniger
s greatly from setup to setup. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Pretty cool, the kind of power information technology puts in our hands these days. - Securityfocus on probing 3600 hosts for known problems in 3 weeks -- PHP General Mailing List (http://ww

Re: [PHP] Installation PHP4 on UNIX problems

2001-05-17 Thread Christian Reiniger
ck-vars > like in the manual I get the error message that there is no httpd.h > file in the apache folder. And thats true. Use --with-apxs instead of --with-apache. That should do the trick. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) void sleep(){for(long int sheep=0;!

Re: [PHP] Finding if a number is in the range

2001-05-18 Thread Christian Reiniger
gt; yes, i have just finished my computational theory and computer > algorithms honors exam. Well, then you *do* know that O(log n) can be slower than O(n), right? :) For a small number of ranges the chained ifs are most likely faster... -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgd

Re: [PHP] still not friends with RegExps..

2001-05-16 Thread Christian Reiniger
l regular expression documentation should be fine. Also the "preg expression syntax" page in the manual is very good. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) "Software is like sex: the best is for free" -- Linus Torvalds -- PHP General Mailing

Re: [PHP] file()

2001-05-19 Thread Christian Reiniger
e on a Unixy server and the file is in DOS format (CRLF endings)? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Very funny, Scotty! Now beam up my clothes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-m

Re: [PHP] Unix problem

2001-05-20 Thread Christian Reiniger
ou only examine your current directory, is_file & is_dir won't find the files. -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) I saw God - and she was black. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additiona

Re: [PHP] The performance of sleep() and usleep()

2001-05-20 Thread Christian Reiniger
s exactly that - putting the process to sleep for the specified period. It doesn't use any processing power during that time and it might even use less memory (if it is swapped out). -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) I saw God - and she was black. -- PHP G

Re: [PHP] Include Paths

2001-05-20 Thread Christian Reiniger
to if there is a flag i'm missing that is > causing them to do that. Thank you for the help! You do a print (readfile ('foo')); right? Well, readfile reads the file *and outputs it*, then returns the number of chars read. That is passed to print (). So just use readfile ('f

Re: [PHP] RegEx Question

2001-05-20 Thread Christian Reiniger
et all the strings between 'testng' > and 'blah' in an array. > This will do it, yet when it wont work when special chars such \n exist > between 'testing' and 'blah'. Use preg_match() with 's' or 'm' as modifier (one of these is co

Re: [PHP] include() in a file incuded()

2001-05-21 Thread Christian Reiniger
is file? (1) $open is defined in frameset.php (2) frameset.php outputs a HTML page with the frameset definition (3) when the browser receives this, it issues two new requests, one for "onlineview.php3" and one for "footer.html" So you don't *include* onlineview.php3, y

Re: [PHP] PHP and XHTML

2001-05-21 Thread Christian Reiniger
roblem? > > It depends. If what is going to process the document is a regular > browser, the NAME attribute is what matters. Future browsers will have > to handle current HTML compatibly. So there is no point in removing the > NAME attribute. Why not specify both? -- Christian

<    1   2   3   4   5   >