[PHP] Visit to Germany

2005-07-29 Thread DL Neil, Newsletter a/c
Greetings, I'm hoping to visit the Stuttgart area* for one week ~ ten days commencing c.Friday 19 August, to visit my brother-in-law and take a short vacation. If there are any PHP-related gatherings or activities I would be interested to meet up (last time I tried, I missed out by one week.

Re: [PHP] $_SERVER['DOCUMENT_ROOT'] on localhost

2002-12-18 Thread DL Neil
Rolf, > > the document_root just doesn't show up in my phpinfo(); > > > > do windows machines have one anyway? > > I have used this var before, just not testing it locally. > > > > It normally shows up when I use phpifno on the server. Please check/compare the entries for doc_root = in the two P

Re: [PHP] Parse Errors

2002-12-14 Thread DL Neil
Andy, > I am a PHP beginner so this error may be a stupid one. Anyway, I'm > trying to write a simple addition script. The client enters two numbers, > then my script (adder.php) adds them. However, when the script is run, I > get "Parse Error On Line 3" I have no idea exactly what I have done wro

Re: [PHP] Difference between 2 Dates

2002-12-13 Thread DL Neil
Colin, > I have a similar problem. I am trying to figure out which of two dates > is greater. Both are in the -mm-dd format. Is there any easy > function that allows this sort of comparison or am I missing something? Treat the dates as strings not numbers: $DateOne = "2002-12-13"; $DateTw

Re: [PHP] ExpertRating launches PHP Certification Exam

2002-12-12 Thread DL Neil
I must be a suspicious character, but I haven't come across Expert Rating before, nor do I know what Pete's connection with Expert Rating is, so I went and looked at the PHP web site (where we are led to believe that we would expect to find "a lot of excitement") but a site-wide search fails to yie

[PHP] Proposal: New list etiquette/rule

2002-12-12 Thread DL Neil
Spam Arrest Sender VerificationYesterday we held an amusing discussion which highlighted the futility of using (badly implemented) technological 'solutions' to a social problem... Herewith I attach a response received pursuant to a list contribution. Does this 'gentleman' seriously expect every

Re: [PHP] mail() problem

2002-12-11 Thread DL Neil
i setting php.ini [mail function] ;For Win32 only SMTP = hermes.ica.gov.co sendmail_from = [EMAIL PROTECTED] =it is impressive to see that the Greeks' messenger has made it all the way over to Colombia! Wasn't he also held responsible for dealing with people who were guilty of indiscreet speech

Re: [PHP] Filter vulger / controversial words - need word source

2002-12-11 Thread DL Neil
Jason, > > there simply is no definitive list of words > The fact is content filtering does not work without a heavy dose of human > intervention. > It is quite shocking that large numbers of well known corporations deploy > misconfigured content-filtering software which rejects perfectly innocen

Re: [PHP] Filter vulger / controversial words - need word source

2002-12-11 Thread DL Neil
> > if you want a partial list of offensive terms - try looking > > at the meta keywords on a few porn sites ... > > Excellent idea! > Unfortunately I'd have to explain that to my boss... "No, really, I'm doing > some research..." =guess monopolising the color printer for a whole afternoon would

Re: [PHP] date() on two diff. servers

2002-12-11 Thread DL Neil
ike to 'prove' it. As I say, am probably just barking up the wrong (Christmas) tree(s). No worries - it's familiar territory! Thanks for your help, =dn > > -Original Message- > > From: DL Neil [mailto:[EMAIL PROTECTED]] > > Sent: 10 December 2002 19:52 >

Re: [PHP] Filter vulger / controversial words - need word source

2002-12-11 Thread DL Neil
Hi Jon, I think we've seen this discussion on the list before (so Christopher, check the archives!) > > I'm wondering if someone has a great source for a master-list > > of controversial and vulger words that I can use on my site. > > I would like to pattern match input text against this master-l

Re: Re[2]: [PHP] Script not working from one computer

2002-12-11 Thread DL Neil
> > > I have a feeling it's going to work out to be something stupidly > > > simple... like these problems always do. :) > > =embarrassingly so! If you're taking this all off a user's say-so, > then it > > sounds like an eyeball job to me... > I never did solve it, but it came down to a weird cooki

Re: [PHP] fgetcsv Help

2002-12-11 Thread DL Neil
Richard, > I am parsing a csv file with fgetcsv and the fields are surrounding by > double quotes, now I am running into a problem periodically that when there > are quotes within the value it is treating it like another value instead of > the same value. > Any ideas on how to get around that? > >

Re: [PHP] Problem relating to images in email

2002-12-11 Thread DL Neil
Hello khuram, > Iam new at this mailing list . =welcome to our happy band! I have a problem in php > is that i want to store the images on local hard disk > that are in email (pop3 account) by runing a php file. > how can i do that. please help me asap. =there are a number of classes available

Re: [PHP] date() on two diff. servers

2002-12-10 Thread DL Neil
> > =now let's take a look at the UNIX Epoch. Various > > 'quotations' have surfaced > > in this email, and I don't recall that it is well discussed > > within the PHP > > manual (it being a UNIX definition after all...). The epoch 'began' > > 1Jan1970, sure enough (exactly as quoted). HOWEVER it i

Re: Re[2]: [PHP] Script not working from one computer

2002-12-10 Thread DL Neil
John, > > > You mention that it is a login script and that input is rejected. Is > it > > > rejected when it is initially typed in, or is it reported as > rejected > > when > > > ensuing pages are served? > When it's initially typed in. =do you have multiple 'environments' (eg VHosts or even phys

Re: [PHP] Different output on two different servers

2002-12-10 Thread DL Neil
Hi Steve, Have you solved this already? If not, when you copied the code between machines was there some effort to ensure that the 'copy' points to the RDBMS/tbls on the same box/different box - or does the original box have code that points to tbls on itself, and the second box have code that run

Re: [PHP] How to test php.info from command line

2002-12-10 Thread DL Neil
I agree with Jason, it seems strange to have a command line option (that can only apply to command line operation) and yet the output be in browser/non-command line format... However with PHP-CLI 'coming soon', maybe that sorts things out. Meantime may I suggest combining the two answers: php -i

Re: Re[2]: [PHP] Script not working from one computer

2002-12-10 Thread DL Neil
Hi John, You mention that it is a login script and that input is rejected. Is it rejected when it is initially typed in, or is it reported as rejected when ensuing pages are served? Please check the IE on the offending machine. Does it have security settings that forbid cookies? Check the ipconf

Re: [PHP] Re: Snoopy Class

2002-12-10 Thread DL Neil
Hi UberGoober, Thanks for your (unique) reply. Specifically: am playing with web pages/link continuity checking and suchlike. So HTTP; as an improvement over the facilities offered by fopen(). Have worked through the readme examples, and dived into the script's code, as you would expect. Was hopi

Re: [PHP] date() on two diff. servers

2002-12-09 Thread DL Neil
Justin, Jumping in late... > >> Daylight Savings Time? > > John, I think "Daylight Saving Time" creates a difference of 1 hour and not > > 1 day :) > True... but I checked it anyway -- by adding just one and two hours to the > stamp... which made no difference... but when I added 86400 to the stam

[PHP] Snoopy Class

2002-12-08 Thread DL Neil
(pardon the pun) Please recommend a Snoopy tutorial, =dn PS Google has not been my friend! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: Re[2]: [PHP] Simple text editor for Windows?

2002-12-07 Thread DL Neil
Hi Tom, > >> I know the text editor question has been beat to death, but I'm looking > >> for a simple editor with syntax highlighting that can be installed in > >> Windows by a general user. It would have to be something that didn't > >> access the registry, as normal users can't do that. Does an

[PHP] Failed to install Mod_cURL under Windows/Apache

2002-12-06 Thread DL Neil
PHP v4.2.3 with Apache 1.3.24 under Win2000 Prof SP2 Downloaded the full v4.2.3 zip package/Win binary, some weeks ago. Installation went fine. Extensions are happily included. Have had several weeks of operations. Decided to install cURL to do some URL (strangely enough) link verification-checki

Re: [PHP] mail() problems...

2002-12-06 Thread DL Neil
imple boy), forget all the optional headers etc, just use a stripped down/simple email stub-script for testing/proving. =If PHP's mail() can be persuaded to work, thereafter it (and any scripts) can be 'tweaked'/made better - or we can look back and compare... =dn > - Origi

Re: [PHP] mail() problems...

2002-12-06 Thread DL Neil
Anthony, Do you have an SMTP server on your Win98 localhost? Recommend you change the PHP.INI SMTP= to say the same as your email package's server definitions. =dn > I'm using MS Win98 and Apache and getting the following after submitting the > mail form: > .. > Warning: Failed to Conn

Re: [PHP] mail function() with MS

2002-12-06 Thread DL Neil
Hi Anthony > Qusetion: 1: > What would happen if I changed the php.ini settings to: > SMTP=mail.yourisp.com > sendmail_from=MyAddress@MyDomain > as opposed to: > >SMTP=smtp.ISPs.domain =as long as the SMTP server is accessible and you have access rights, then it can be anyone's/anywhere... > >

Re: [PHP] mail function() with MS

2002-12-06 Thread DL Neil
Hi Anthony, > I'm using MS Win 98 and my ISP has PHP installed on a MS server. > I'd like to display a HTML form box on my site for users to type in a > message utilizing the PHP mail() function. > > I've tested this using Apache on my drive with a html form and a php script > to receive the data

Fw: [PHP] Checking for Overlapping Dates

2002-12-06 Thread DL Neil
Thomas (and list), The solution, as previously posted, is flawed/incomplete - mea culpa. Excuse: I was interrupted three times from typing the word SELECT until pressing Send, and then rushing to get on to the next call on my time... >WHERE bstart < afinish > OR bfinish > astart; Check

Re: [PHP] Checking for Overlapping Dates

2002-12-06 Thread DL Neil
Hi Thomas, > SELECT * from $DB_TBLName WHERE > (Trim(WorkerEmail)='$userReplacementEmail') > AND AND OR OR OR OR OR This is all a bit complicated, and a simple boy like me gets lost too easily. KISS principle: Keep it simple... You have two employees: A, so named because he Already has Annu

Re: [PHP] empty string parameters to backslashes?

2002-12-06 Thread DL Neil
Hey Andy, > I'm trying to track down a problem with someone else's > code. Our hosting service changed PHP versions on us > (up to 4.0.6), and everything broke. I think I have > tracked down at least part of the problem. We have a >... Ascertain differences by printing out a phpinfo() report for

Re: [PHP] Regular Expresion Work on IP address

2002-12-05 Thread DL Neil
> $this="that"; > return $ip_state; > } > > function net_check($ip_2_chk){ > $parts=explode(".",$ip_2_chk); > if($parts[0]==10){ > $network="internal"; > } > elseif($part

Re: [PHP] Regular Expresion Work on IP address

2002-12-04 Thread DL Neil
John, > I think it'd be hard to verify the range with a regex. ip2long and long2ip > do not validate. So, an option would be to write your own little function > that splits the $ip on the period, verifies there are 4 parts, then checks > that each part is between 1 and 255 inclusive. My other po

Re: [PHP] Regular Expresion Work on IP address

2002-12-04 Thread DL Neil
Hello Dev, > Now I am continuing on with the same script and I need to check for valid > IP address form. > Currently I have: > > $ip="255.255.255.0"; > if (preg_match ("/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/", $ip)) { > print "Good Ip"; > } else { > print "Bad Ip"; > } > > Thi

Re: [PHP] My first post

2002-12-03 Thread DL Neil
Hi Victor, Welcome to the wonderful world of PHP! > I'm new in PHP. Could you point me where can i download a sample script > about how can i paginate some results? PHP essentially exists to output HTML. You cannot paginate in HTML (although there is some fancy CSS that could be employed). Sorr

Re: [PHP] date

2002-12-03 Thread DL Neil
Hi Shaun, > please could someone tell me how i can return a month in text from an int ie > getMonth(12) > returns Decmber. Is this possible? No. If you want to stick with this, write your own function to look up a text array. If the "12" is part of more data coming in from a form or db (for exa

Re: [PHP] Triggering a PHP Script

2002-12-02 Thread DL Neil
Ryan, > My Problem: > I've got a PHP script (running on Apache) that can take several hours > to complete. The script sends out a newsletter to those who have > requested it. When calling this script from a web browser, the browser > hangs until the script has fully executed. If the user hits "Sto

Re: [PHP] Test links?

2002-12-02 Thread DL Neil
Rob/Beth, The code should also consider: 1 updating the db if the link is 'valid', ie if previously it had been 'down'! 2 putting an @ to prevent any errors causing a hard-stop at the fopen line 3 that the url/database must contain protocol information, ie http://www.nytimes.com not www.nytimes.c

Re: [PHP] Test links?

2002-12-02 Thread DL Neil
Beth, > When fopen successfully opens a file it populates an array > $http_response_header, which you can examine to see if the link works or > not - I don't believe you can actually get the file itself, but since > that's not what we're after that's not a problem! I noticed this reference to "$h

Re: [PHP] How to give parameters to a console php-script?

2002-12-02 Thread DL Neil
Martin, Ah yes, the famous 'read the upgrade notes - gotcha'! Well done, you figured it out... =dn > ll I found a > register_argc_argv = On > > in my php.ini, which should work then. But I also found, that I have to use > > print "Ok: ".$_SERVER["argv"][1]; > > instead of > print "Ok: ".$argv[1];

Re: [PHP] How to give parameters to a console php-script?

2002-12-02 Thread DL Neil
Hello Martin, > I start a console app with > > php myscript.php4 (just prints "ok"). > > How can I give parameters to it? I tried: > php myscript.php4 myparameter > php myscript.php4?myparameter > php myscript.php4?param=myparameter > > But always php just returns without doing nothing (not eve

Re: [PHP] Detecting email bounces sent by the mail function?

2002-11-28 Thread DL Neil
Hello Ade, > Is it possible to detect with PHP whether an email sent using the PHP > 'mail' function has bounced back or has not been delivered? > > I currently all ready check the email address using the 'ereg' function > before the mail function is called, but this only checks the format is > va

Re: [PHP] IPs comparing

2002-11-27 Thread DL Neil
Hi Jesús, > I have several subnets in my network and want to show different webs > depending on the subnet the user was. > > I know how to get the IP but not how to compare two IPs numeracally, I mean: > > > If ((USER-IP > 192.168.0.1) && (USER-IP < 192.168.0.255)) > Else if ((USER-IP > 192.168.1.

Re: [PHP] php/mysql report builder

2002-11-27 Thread DL Neil
Hi Mike; > sorry for posting this mysql question again. im searching for a report > builder for mysql specifically for creating reports for > invoice/receipt..etc. > just like crystal reports and oracle report builder. or is there any > suggestion to do it in PHP . On my travels (FWIW) I have

Re: [PHP] Invalid Charactors in a string.

2002-11-27 Thread DL Neil
Gidday Philip, Full answer: http://www.oreilly.com/catalog/regex/ Short answer: PHPBuilder etc have articles introducing the use of RegExes (Regular Expressions) for this sort of thing. (but please not the Arthurian "how do I validate an email address"...) Regards, =dn > Where should i start,

Re: [PHP] Getting the script path of a commandline script

2002-11-26 Thread DL Neil
Ryan, > Anyone know how to get the script path (not the current working directory, > but the actual path of the executing script) of a commandline script? > > I've dug through the docs and can't find this anywhere. None of the > typical $_SERVER variables return the script path (although several

Re: [PHP] If statement w/ multiple conditions

2002-11-26 Thread DL Neil
Ed, Assuming there will be a response from the db-tbl, here is another choice: if ( $lineone . $linetwo . $linethree . $linefour > "" ) { //show it to the user and ask if they want to change it } else { //prompt for information } Do you mean that the db-tbl will have a row of data even if t

Re: [PHP] array manipulations

2002-11-25 Thread DL Neil
Mattia, > Can anyone suggest an ELEGANT way to find out if an array is made of empty > strings or not? > example > $a = Array( '' , '' , '' ); //ok > $b = Array( '' , '' , 'error' ); // not ok > $c = Array( 'error' , '' , 'error' ); // not ok implode() then check for nullstring/count characters.

Re: [PHP] does //commenting reduce performance?

2002-11-25 Thread DL Neil
Jason, ad infinitum, ad nauseum However it was your recent post that (sig file) quoted the Freudian: ontogency recapitulates phylogeny We should make them become more like us - even if we kill them in the process! =dn > On Sunday 24 November 2002 22:58, DL Neil wrote: > > Neatly do

Re: [PHP] Setting values of php.ini file at runtime

2002-11-25 Thread DL Neil
Justin, Neat! Don't limit thoughts to PHP when can solve it in Apache - thank you, =dn > a .htaccess file in the directory you want RG OFF (ie /wiki/) should do the > trick: > > > php_flag register_globals on > > > This seems to work for me... > > >

Re: [PHP] Setting values of php.ini file at runtime

2002-11-25 Thread DL Neil
Excuse me breaking in...somewhat similar problem: Have set up a client recently, preaching security persuaded them into updating so that could run Register_Globals=Off. Now they want to install a 'wiki' which requires (to my horror) Register_Globals=On. Short of two Apache/PHP servers, what is a

Re: [PHP] security of stand alone script

2002-11-24 Thread DL Neil
Hi gamin, >Running Red Hat 7.2, PHP 4.0.6. Is there any way of knowing if a certain > PHP script was run from the command line, shell script or through the > webserver (Apache). May be i could check the user calling the script and > find out but how would i do that ? There is a difference in

Re: [PHP] does //commenting reduce performance?

2002-11-24 Thread DL Neil
Ernest, > Some time ago I've made myself a framework for such tests and have run it > against a commented loop. This test was run on a dual PIII/1000 Dell server. > > $hpr = _fwx_profile_start('Loop with end-of-line comment', true); > for ($i = 0; $i < 100; ++$i) { > $a += 1;

Re: [PHP] does //commenting reduce performance?

2002-11-24 Thread DL Neil
Neatly done Ernest! Also in showing how these questions are best answered with five minutes on the PC, than a msg to the list... > At 12:58 24.11.2002, DL Neil said: > [snip] > >Why don't you run a microtime testbench to time a

Re: [PHP] does //commenting reduce performance?

2002-11-24 Thread DL Neil
Adam, > I have always had the opinion that the more comments you put into php > scripts, the slower they will run because there is more data to be read... > Can someone tell me if there is any truth in this or whether commenting has > absolutely 'no' impact on the performance of a script? An ans

[PHP] Re: [PHP-DB] Help with Date

2002-11-21 Thread DL Neil
Rodrigo, Is there a way to convert a date " 20/11/2002 " to a Float number in PHP, since the date starts in 30/12/1899, just like the delphi treats the dates =Check out UNIX timestamps (but watch the valid date range), =dn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, v

Re: [PHP] Newbie: PHP/MySQL (SELECT)

2002-11-20 Thread DL Neil
> On Thursday 21 November 2002 03:53, Mr. BuNgL3 wrote: > > Hi... > > I'm with a little sintax problem... > > The question is that i have two search fields (titulotxt and cdstxt) and i > > want to create an mysql condition... i trying: > > > > $sql1=($titulotxt) ? "titulo like '%".$titulotxt."%'":

Re: [PHP] What is wrong with this expression?

2002-11-18 Thread DL Neil
JohnMeyer > if (is_uploaded_file($_FILES["imagefile"]["tmp_name"]) && > ($_FILES["imagefile"]["type"] != "image/jpeg" && > $_FILES["imagefile"]["type"] != "image/gif" && $_FILES["imagefile"]["type"] > != "image/jpg" && $_FILES["imagefile"]["type"] != "image/png")) > > I'm trying to weed out everyt

Re: [PHP] Browsing directory

2002-11-18 Thread DL Neil
Helen, > I would like to create a web page which allow people to browse the directory structure and the files listed in every directory. If you have experience about that, could you kindly give me some advice or references? Thanks in advance. =To this simple boy it seems like a strange, even a p

[PHP] BBC article: Intellectual Property

2002-09-13 Thread DL Neil
Open source campaigners and 'evangelists' may be interested in BBC coverage of a report by the Commission on Intellectual Property Rights (CIPR): http://news.bbc.co.uk/1/hi/sci/tech/2253270.stm. It talks of medical, agricultural, industrial, and IT/educational disadvantages placed in front of the

Re: [PHP] Re: PHP / Bulk Email

2002-09-04 Thread DL Neil
> Hi Guys / gals, > > I ran a test recently sending emails to a list of clients (1000 or so) > from a PHP / MySQL powered system. > When sending via Sendmail this was VERY slow, taking several minutes to > complete. > When I switched over to Qmail the whole process takes only 10 or 15 > seconds. >

Re: [PHP] Ridding myself of HTML tags

2002-08-30 Thread DL Neil
Liam, If you were to stristr()/remove everything up to and including the tag, would that take care of things? =dn > I've got a lil problem with HTML tags. Here's the description. > > My site accepts HTML files by upload. A lot of these files are written in MS > Word and then saved as HTML files

Re: [PHP] Resource ID??

2002-08-30 Thread DL Neil
John, This is the output: Resource id #15 or some other seemingly arbitrary Resource ID number? First of all what is a resource ID and second how do I get it to actually show what I am trying to get it to show! =When MySQL returns data to PHP, the information is put into a variable called a "re

Re: [PHP] Re: Mail()....

2002-08-30 Thread DL Neil
Brian, Please be aware that many email clients will NOT read HTML. The human readers are then presented with raw HTML and get very <...?...> upset about it! (that's why list postings are not supposed to be in HTML/rich text format) Regards, =dn > It's a text-based newsletter... > > I have a s

Re: [PHP] variable reference parameters

2002-08-29 Thread DL Neil
Timo, If you use func_num_args() to ascertain the number of arguments passed to the function and func_get_arg() to retrieve each argument in turn (from a list of unstated length), will that do the trick? Regards, =dn > I've created (with help from some code from the site) a function to make >

Re: [PHP] How can I strip the code from HTML pages to extract the contents of a HTML page.

2002-08-28 Thread DL Neil
Carlos, I'm sorry, but am just leaving... If you check the PCRE RegEx pages of the annotated manual, there are contributed examples that will help in this situation (probably under preg_match_all() ) Regards, =dn > This may be an interesting challenge for someone or has it been done > before >

Re: [PHP] Apostrophe in preg_match?

2002-08-28 Thread DL Neil
P there's usually a way... =throw 'escape database' (apostrophe will work too) at the PHP manual's search facility (the manual is really v.good!) and it will respond with a reference to ADDSLASHES(), which will do as you ask - there is also a reference to a PG function (I'

Re: [PHP] Window/Page/Browser/Screen width

2002-08-28 Thread DL Neil
Hi Rick Check out list archives for last week (and the week before...) keyword: resolution. Also check out HTML, which will cheerfully slap text and graphics together an adapt to local peculiarities. Regards, =dn > I've seen similar questions in archives so sorry if I'm asking the same thing

Re: [PHP] No Localhost with apache?

2002-08-28 Thread DL Neil
Hi Ryan, Anyway, I installed PHPTriad first but since the version of php is 4.0.0 I uninstalled it and installed SpaceServer...the problem I noticed with both was I could not get the default page from apache with http://localhost/ I have to use http://127.0.0.1 or it gives me a page not found err

Re: [PHP] Apostrophe in preg_match?

2002-08-28 Thread DL Neil
> I'm trying to get an apostrophe (and a dash, as well) to be > included in a preg_match expression, but I don't know how to escape the > characters. The manual discusses which characters need escaping and how to escape characters: http://www.php.net/manual/en/pcre.pattern.syntax.php > if (preg

Re: [PHP] search in serialized string

2002-08-27 Thread DL Neil
to skill level > > 1b no separator it's stored as array. The array generated by language[] and > skill[] are stored into another array, serialized and put into DB > > 2 yes. could be up to 5 > > 2b again, none. only the array structure > > the field is a text. > > >

Re: [PHP] search in serialized string

2002-08-26 Thread DL Neil
, and now I have the problem to solve. So i back to old question > :-) > How can I search with some precision in a serialized string? > > > > on 8/24/02 12:13 PM, DL Neil at [EMAIL PROTECTED] wrote: > > > Rodrigo, > > > > Then the question to be asked is: is seri

Re: [PHP] Re: SeparatingWords

2002-08-21 Thread DL Neil
Philip, What about "SoftwareVersion Thingy"? Won't that end up as "Software Version Thingy" - with two spaces before the "T"? Can the RegEx be 'turned off' if the u/case letter is already preceded by a space? (sorry, may not be Hessu's requirement = my curiosity) Regards, =dn > This works. > >

Re: [PHP] Is there a better way of doing this?

2002-08-21 Thread DL Neil
Hello Mike, parse a string similar > to "4,31m)" figure out if it is numeric or not, then if it is remove the > last to characters on the string (the 'm)') and change the string so > that it is 4.31. There is probably a better way of doing this but I > can't figure out how to make it better or mo

Re: [PHP] Image library

2002-08-21 Thread DL Neil
> Having a large number of files in a single directory does affect performance, > the degree of which depends on the filesystem. This is generally accepted wisdom for dealing with large numbers of files - but what number is considered "large"? Any rules of thumb, for different OpSys/file systems

Re: [PHP] PHP Web site down?

2002-08-21 Thread DL Neil
General advice: take a look in the bottom right corner of any manual page and call for the mirrors list - it's worth bookmarking/favoriting a couple, just in case one goes down. Also FYI, mirror sites are often faster (depending upon relative locations) and their use certainly frees bandwidth at

Re: [PHP] PHP Web site down?

2002-08-21 Thread DL Neil
> Is it just me having network connectivity problems, or is the PHP website, > http://www.php.net down? I tried connecting to it from a couple of > difference computers and I can't access it on any of them. Just wondering > if anyone else is having problems getting to their website too. Adam,

Re: [PHP] Image library

2002-08-21 Thread DL Neil
hanks for your input. > > Regards > > -Scott > > > -Original Message- > > From: DL Neil [mailto:[EMAIL PROTECTED]] > > Sent: 21 August 2002 04:31 > > To: [EMAIL PROTECTED]; Bogdan Stancescu > > Subject: Re: [PHP] Image library > > > >

Re: [PHP] Image library

2002-08-21 Thread DL Neil
Scott (confirming Bogdan), Libraries of all types have had this concern for years - even though books are uniquely identified by ISBN, that is still not good enough for library purposes (eg multiple copies of a single title). So they, exactly as Bogdan suggests, use an "Accession" number sequence

Re: [PHP] Agh! trim (#$@#@^%!!!)

2002-08-21 Thread DL Neil
Mike, What are the character codes of the last few bytes in the string? Please advise, =dn - Original Message - From: "Mike At Spy" <[EMAIL PROTECTED]> To: "Rasmus Lerdorf" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Wednesday, August 21, 2002 1:36 PM Subject: RE: [PHP] Agh! trim (#

Re: [PHP] Find rows by 1st letter in MySQL

2002-08-18 Thread DL Neil
Tony, > How would I go about selecting rows from a MySQL table where the first > letter of a certain field is $letter ? Depends upon the MySQL tbl's schema. The MySQL online manual discusses wildcards (full text). Alternatively see LEFT() and other string functions that can be used in SELECT an

Re: [PHP] hyperlink parser - a bit new view :)

2002-08-18 Thread DL Neil
Hi Roman, > But on those phpbuilder's page there are also similar questions but answered > scripts don't work, for example: > ... > preg_match_all("|href=\"?([^\"' >]+)|i(+[ >])", $text,$ar); >... > I really don't know :( There's definitely something wrong with the RegEx above. The string comme

Re: [PHP] fgets question

2002-08-14 Thread DL Neil
Hi Monte, > Hi, I have a question about fgets(), it seems to pick up an extra line > at the end of a text file. ... > 8\n ... > Here is the output (showing newlines as \n): > buffer is 1\n > buffer is 2\n > buffer is 3\n > buffer is 4\n > buffer is 5\n > buffer is 6\n > buffer is 7\n > buffer is

Re: [PHP] SQL datetime ERROR !

2002-08-13 Thread DL Neil
Hi Djurovski, > I use this query to input data into MySQL DB. > EXPIRE is Expire Date! > My script allways inputs "1.1.0001" into database (as value of expire). > what is wrong? > > My table: > > CREATE TABLE korpa ( >idnarudzbeukorpi int(255) DEFAULT '0' NOT NULL auto_increment, >merna

Re: [PHP] switch statement question

2002-08-13 Thread DL Neil
Alternatively Alexander, take a look at the string functions eg strstr(), stristr(), and strpos() all of which can be used to make a condition within the case() criteria. Regards, =dn > [snip] > Say i have a variable $string_var = "Once upon a time"; > > is there a way to do this: > > Switch($st

Re: [PHP] SQL ?

2002-08-12 Thread DL Neil
Now then, let's all play nicely together! Dan: relevance It is a PHP question because whereas the SQL query SELECT fred FROM tbl produces an array element back in PHP such as $row[ "fred" ], this convention/mapping comes well unstuck if you submit something like SELECT IF ( answer = 'a', TRUE, FA

Re: [PHP] records in db

2002-08-10 Thread DL Neil
Tyler, > If I have a field in my DB that can have 4 different answers, lets say a,b,c > and d. How can I count the number of each in that field. So if there are 4 > a's 1 b 0 c's and 12 d's how can I get php to count this? You must combine IF() with SUM(). Break it down into smaller problems:

Re: [PHP] Save ability... Duplicate DB entries

2002-08-10 Thread DL Neil
JJ, > i have this code snippet: > > if(isset($_POST['save'])){ > $query = 'INSERT INTO article_data VALUES (\'\', '.$_SESSION['uid'].', > '.time().', \''.$_POST['title'].'\', \''.$_POST['description'].'\', > '.$_POST['cat'].', \''.$_POST['text'].'\', 0)'; > $result = mysql_query($query) or

Re: [PHP] Restricting access using IPs

2002-07-14 Thread DL Neil
Liam, Not altogether happy with the suggestion below. It works - for now. A more generic solution might be to replace the hard-coded "9" with a call to strrchr() on the last 'dot' character position (minus one). Then it should work on any properly formed IP address. Thereafter parameterise the su

Re: [PHP] hello the list

2002-07-14 Thread DL Neil
Welcome Nicolas, =You didn't actually say what the problem was! =Some have made suggestions, please also consider (below): i'm new and i'm trouble with this code :'( can U help me please ?? this is the code : while ($cd_tbl = mysql_fetch_array ($result)) { $cd_id = $cd_tbl['cd_id']; $cd_oeuvre

Re: Re: [PHP] PHP editor for windows

2002-04-22 Thread DL Neil
> > "etc" (TM) is able to follow up the syntax coloring operation by making > > changes to the code to correct syntax errors, puts brackets in exactly > > the right place to indicate block structure within the code, imposes > > data type prefixes in strict convention, chooses better variable names

Re: [PHP] PHP editor for windows

2002-04-22 Thread DL Neil
> I really hate to do this, but it's one of my pet peives. is that like a pet rock? BTW if we're exercising peevishness, at the same time as indulging in anally non-retentive breakfast habits, check out http://www.onelook.com/cgi-bin/cgiwrap/bware/afen.cgi?type=word_all&word =peeve > >>> Ot

Re: [PHP] calculating US holidays OT

2002-04-15 Thread DL Neil
> > I need to calculate the date to see if it's a holiday, i.e. is today > > presidents day > > No, today is Patriot's Day! > > Not sure if it's celebrated outside of Massachusetts It's celebrated any day there's a SCUD inbound! =dn -- PHP General Mailing List (http://www.php.net/) To un

Re: [PHP] web spider?

2002-04-15 Thread DL Neil
Greg, > >i was wondering if it would be possible to make a web spider in PHP. > >they work by download a website, then following all the links on the > >website to other pages, and then following the links on that page... > > > >is this possible in PHP without a whole lot of work? i just want to

Re: [PHP] PHP FAQ (again)

2002-04-03 Thread DL Neil
Justin, > I think this is a good idea, but it looks to be more of a searchable FAQ, > which will highly detailed... I'm really thinking of a medium-length email > introduction to the group (as per my attachment) which hopefulyl cleans up > the group a bit. > > Your resource could be fantastic, an

Re: [PHP] Warning: Undefined variable

2002-04-03 Thread DL Neil
Erik, My two cents' (with allowance for inflation...) > > If you're distributing code in cyberspace it's a good > > idea to make it error free too, E_NOTICE or otherwise. To get the maximum help when coding, and to ensure the minimum of confusion for your users, I recommend: 1 set the dev serve

[PHP] Re: [PHP-DB] how to get consistent UTC from gmmktime (w/o dst-offset) ????

2002-03-28 Thread DL Neil
er time discontinuity. (so I don't need to run it on another box/change the server's TZ setting, I simply read the second half of the report) It is not missing one day, but one hour! Regards, =dn > Fucko. I kicked this pony-style. Yes - typo Didn't know what hit me th

[PHP] Re: [PHP-DB] how to get consistent UTC from gmmktime (w/o dst-offset) ????

2002-03-26 Thread DL Neil
BTW for all who are following this, Patrick has cleverly illustrated that most of the northern hemisphere locations where summer time is observed will 'spring forward' this weekend. Most of the southern hemisphere locations that were in summer time did their 'fall back' last weekend! NB the two us

Re: [PHP] Problems installing PHP

2002-03-11 Thread DL Neil
Hi Berlina, > Im trying to install an Apache Web Server and PHP in a Windows NT . > > * Apache 1.2.23 > * PHP 4.1.1 > * Windows NT Server 4.0 with SP4 > > The installation of Apache Web Server and PHP was succesfully ok, but when I > configure the PHP and Apache, editing the PHP.ini and httpd.con

Re: [PHP] mktime() into TIMESTAMP ?

2002-03-08 Thread DL Neil
Hi Erik, > On Wednesday, March 6, 2002, at 05:11 AM, DL Neil wrote: > > > My 'rules' are simple: > > If the date/time is for processing, keep it as a timestamp (consider > > which type). > > If the timestamp is being used to keep track of RDBMS a

  1   2   3   >