Re[2]: [PHP] What does MAX_FILE_SIZE do?

2004-04-08 Thread Richard Davey
say "sorry, you just wasted X minutes of your life uploading that, try again". Gotta be cruel to be kind :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] smarty

2004-04-08 Thread Richard Davey
Hello Antonio, Friday, April 9, 2004, 12:21:15 AM, you wrote: AM> "Who the you tink you're talkin' to, huh! Whatta you (etc) Dear God, who unlocked the monkey cage? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General

Re[6]: [PHP] (new question on this) http referer

2004-04-08 Thread Richard Davey
something along the lines of a user downloading your form, modifying some values and then posting it from their local box. It could also stop another web-site automatically posting data to your forms should they mask the referer value. Hope that makes more sense. -- Best regards, Richard Davey h

Re[4]: [PHP] (new question on this) http referer

2004-04-08 Thread Richard Davey
ference in this instance. scriptA receives the POST data scriptA then in turns POSTs that to scriptB which outputs the result back to a variable in scriptA scriptA displays it, effectively - the proper page At no point has the user been redirected anywhere. -- Best regards, Richard Davey http://w

Re[2]: [PHP] (new question on this) http referer

2004-04-08 Thread Richard Davey
lthough it doesn't have to be Downsides: Your site is effectively processing all form data twice. Depending on traffic/size of forms/etc this probably isn't desirable. But, it does actually work and AFAIK cannot be easily spoofed. -- Best regards, Richard Davey http://www.phpcommu

Re[2]: [PHP] (new question on this) http referer

2004-04-08 Thread Richard Davey
using IE. and Norton Internet Security will block this information by default (apparently it's a "privacy thing"). -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] smarty

2004-04-08 Thread Richard Davey
tomorrow off anyway :) ... smarty/InterJinn/native PHP/whatever - pick the one that floats your boat and go sail in it. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] confused big time

2004-04-07 Thread Richard Davey
e to anyone who understands SQL. Obfuscating that into a function could be considered un-readable to some? But, whatever floats your boat mate ;) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Can someone with list access please remove these two?

2004-04-07 Thread Richard Davey
Hi, Subject says it all - they're causing auto-responder junk to any list poster and it's annoying: Information Desk <[EMAIL PROTECTED]> Advance Credit Suisse Bank <[EMAIL PROTECTED]> -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP Gene

Re[2]: [PHP] confused big time

2004-04-07 Thread Richard Davey
way of inserting the current time into a datetime or timestamp field. Converting it to a timestamp/datetime locally first is a waste of processing time IMHO and opens you up to a potential (although slight) code error. But, to get your function working, I can see the point :) -- Best regards, R

Re[2]: [PHP] confused big time

2004-04-07 Thread Richard Davey
ue as now() ? (which will break the string check as it'll wrap it with '' which will cause MySQL to insert -00-00 00:00:00) or if it's an enum field with a numeric allowed value? :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- P

Re[2]: [PHP] Validating form field text input to be a specificvariable type

2004-04-07 Thread Richard Davey
Hello John, Wednesday, April 7, 2004, 2:05:22 PM, you wrote: JWH> Yeah, but the OP wanted to be able to tell an integer from a real number JWH> from a string. is_numeric() is going to validate 5, 5.5, and 5.05E6, for JWH> example. What about is_integer() ? -- Best regards, Rich

Re: [PHP] assign mysql query to a variable first or not

2004-04-07 Thread Richard Davey
is at the moment, if you hold the query in a string before passing to MySQL it means you could implement a database handler in the future with minimal code changes and not have to re-do every single query. There are other benefits, but that one strikes me as the most important at

Re[3]: [PHP] Validating form field text input to be a specific variable type

2004-04-06 Thread Richard Davey
if it is an integer or not. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Validating form field text input to be a specific variable type

2004-04-06 Thread Richard Davey
bove will display a message. 5.0a will cast to 5, 5.5a should also cast to 5, but might be rounding the wrong way? a5.5 will cast to 0. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] confused big time

2004-04-06 Thread Richard Davey
ant way of telling where the missing ' is. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] confused big time

2004-04-06 Thread Richard Davey
u don't need to insert "NULL" values in MySQL, you can just not insert anything if null is the default anyway for that field. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: combining variables...

2004-04-06 Thread Richard Davey
Hello K.Bogac, Tuesday, April 6, 2004, 6:34:50 PM, you wrote: KBB> $i = 2; KBB> $var = "view_request_$i"; KBB> $value = $$var; That's it, I knew there was a variable variable ($$) in there somewhere :) -- Best regards, Richard Davey http://www.phpcommunity.or

Re: [PHP] combining variables...

2004-04-06 Thread Richard Davey
Hello Tristan, Tuesday, April 6, 2004, 6:14:19 PM, you wrote: TPrsc> Simply put, can I connect 2 variables, to make one... TPrsc> I want to output: TPrsc> $view_request_$i TPrsc> making for example a string: TPrsc> view_all_2 I believe it's $view_request_$$i -- Best reg

Re: [PHP] Keyword Search

2004-04-06 Thread Richard Davey
AINST 'Figs' RK> It doesnt' work. Does the keywords table have a fulltext index on it? If so the above would work, but only if you have reduced the minimum word length allowed. You could just do: SELECT * FROM table WHERE keyword LIKE '%Figs%' ? -- Best regards, Richa

Re[2]: [PHP] function CreateDate i made doesnt work?

2004-04-06 Thread Richard Davey
ogle for the term and RW> you will find many hits like this: Yeah, I reckon times must be one of the most misunderstood (or just misused) elements of PHP. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/)

Re: [PHP] function CreateDate i made doesnt work?

2004-04-06 Thread Richard Davey
timestamp which means it's going to try and calculate the difference between 10 and the given timestamp (which is going to be a lot!) What exactly is this function *supposed* to do? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] register_globals

2004-04-06 Thread Richard Davey
t can only be changed in the php.ini file or an htaccess file. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] can I get at screen size ?

2004-04-05 Thread Richard Davey
reen size automatically. You would have to pass values in from JavaScript. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP]

2004-04-05 Thread Richard Davey
can also use it to clear the contents of an existing array. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] elementary question about reading an array ...

2004-04-01 Thread Richard Davey
f them worked KM> here odd, isn't it? KM> What the heck am I doing wrong here ? Nothing.. the array appears to contain an Object (called bc). Try this to see if it'll show more details: var_dump($arrayname); and wrap it in tags or something, so the formatting makes

Re: [PHP] re:[PHP] determining number of rows in a mysql table

2004-03-31 Thread Richard Davey
lights so AB> probably missed it... I don't use colour in emails to this (or any) list, sorry. I would have hoped the screen reader said "asterisk asterisk highlighted" (etc). -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing Li

Re: [PHP] re:[PHP] determining number of rows in a mysql table

2004-03-31 Thread Richard Davey
array **in this instance**, why bother giving PHP that extra overhead?" I **highlighted** the relevant part for you :) Don't forge that nearly all replies to this list are meant in the context of the original problem, not generically, and this was certainly no exception. -- Best reg

Re: [PHP] determining number of rows in a mysql table

2004-03-31 Thread Richard Davey
less the query failed, the value count will *always* exist at row 0, so you can simply do: $count = mysql_result($rows, 0, 'count'); -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] adding days to a given date

2004-03-31 Thread Richard Davey
d on the current time the above will work, or just replace time() with any other valid timestamp you may have. Look at the manual entry for it for lots of other examples. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.p

Re: [PHP] mysql - can't use the copy/paste function

2004-03-30 Thread Richard Davey
lex queries/table building. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Really Annoying Require/Include Error

2004-03-30 Thread Richard Davey
level root, regardless of php.ini include directory settings. They are just a means for PHP to start-off looking for files, not a dictation of the only place they can be located (much like the PATH attribute in Windows). -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html --

Re[2]: [PHP] Namespaces in PHP

2004-03-30 Thread Richard Davey
In all fairness, Agent 2 is a very good program though. One of those real "has been around for ages" packages, like Eudora :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] PHP alternative to Browser Hawk?

2004-03-30 Thread Richard Davey
Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Really Annoying Require/Include Error

2004-03-30 Thread Richard Davey
ng this? Swap the file for one that does nothing but echo out "included" and see what happens? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Namespaces in PHP

2004-03-30 Thread Richard Davey
-- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Re: passing a variable value of PHP into the alert of JavaScript.

2004-03-30 Thread Richard Davey
ET framework allows this via some clever JS and page segment caching, but I'm not sure of a PHP equivalent yet). -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] determining number of rows in a mysql table

2004-03-29 Thread Richard Davey
'); CW> $num_rows = mysql_num_rows($result); SELECT COUNT(*) AS hits FROM tablename The row count will be in "hits" in $result. Count is a much faster way for MySQL to give you the number you want without actually selecting all the data in the process. -- Best regards, Richard Dave

Re: [PHP] Wrong IP address

2004-03-29 Thread Richard Davey
yone know why? Firewall? Proxy Server? Anti-Virus/spam/privacy blocker? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Namespaces in PHP

2004-03-29 Thread Richard Davey
continue to extend posters the courtesy of replying to the list rather than them personally and can only hope they do the same. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Namespaces in PHP

2004-03-29 Thread Richard Davey
Hello Justin, Tuesday, March 30, 2004, 12:42:12 AM, you wrote: JP> P.S. Why do a lot of people email off list? I get doubles. They are too lazy to remove your email when doing a reply-to-all basically. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html --

Re: [PHP] What's the use in OOP?

2004-03-29 Thread Richard Davey
akes development time heck of a lot faster. Perhaps one approach to this would be to post an example of one of your scripts (not necessarily the source, more an overview) and then let someone explain how one OO approach might be to it. -- Best regards, Richard Davey http://www.phpcommunity.org/

Re: [PHP] find string position using reg exp

2004-03-29 Thread Richard Davey
er length string, I would CC> like to know where, at what position that match was made. Any ideas? Thanks Why use a regular expression? strpos() will do this just fine. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/)

Re: [PHP] apply function to each array element?

2004-03-29 Thread Richard Davey
sting one? I.e.: function the_function (&$item) { $item = whatever_cleaning_you_need_to_do(); } array_walk($your_array_to_tidy, 'the_function'); -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] JavaScript Enabled?

2004-03-29 Thread Richard Davey
ients? Hmmm.. not a bad idea. I was thinking of some kind of "intermediary" script, where it can run a check to see if JS is there or not (via whatever method possible) and then redirect accordingly. I'll have an experiment and (further!) searches to see what other ideas are

[PHP] JavaScript Enabled?

2004-03-29 Thread Richard Davey
proof method of doing this? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] how can I get the id of the last record I inserted into a table with an insert query?

2004-03-29 Thread Richard Davey
Hello Diana, Monday, March 29, 2004, 1:40:41 PM, you wrote: DC> how can I get the id of the last record I inserted into a table with an DC> insert query? (into Mysql database) mysql_insert_id() The manual is your friend. -- Best regards, Richard Davey http://www.phpcommunity.org/wi

Re: [PHP] re:[PHP] login problem fixed!!

2004-03-25 Thread Richard Davey
Hello Andy, Thursday, March 25, 2004, 5:45:52 PM, you wrote: AB> PHP Version 4.0.4pl1 Wow, that's an old version of PHP! It could be the cause of this, there's nothing in you phpinfo to give anything else away (i.e. it's identical to mine). -- Best regards, R

Re: [PHP] session.gc_maxlifetime

2004-03-25 Thread Richard Davey
close their browser and/or wait too long), so yes - you are correct :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] re:[PHP] login problem fixed!!

2004-03-25 Thread Richard Davey
ing this in a controlled environment and you know where it's going to go when it's live, then I guess you can exploit this to its full potential. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] fsockopen and HTTP 1.1 Problem

2004-03-25 Thread Richard Davey
;outfitId"] = "6607"; $submit_vars["worldId"] = "21; $snoopy->submit($submit_url,$submit_vars); ?> Then the whole page is stored in $snoop->results, the headers in $snoopy->headers, etc etc. Lots of variations, see the doc files. :) -- Best regards, Richard Dave

Re: [PHP] re:[PHP] login problem fixed!!

2004-03-25 Thread Richard Davey
t; block should only print "valid user" if the user exists in the database, right? For me it'll print "valid user" no matter what I do because the query is always valid and that is all it's checking. If I enter a valid username and password combo the result is reflected in mysql_num_rows, as shown in the code. Unless I have missed something significant from your original code/query I'm at a complete loss as to how the above can give you any kind of different result? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] re:[PHP] login problem fixed!!

2004-03-25 Thread Richard Davey
fact they're telling you two completely different things. Without doing a COUNT or knowing how many rows the query returned, you cannot determine if the user does already exist or not, all you can tell is if your query worked and an invalid user does not = an invalid query. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] RE:[PHP] login problem fixed!!

2004-03-25 Thread Richard Davey
g your data types for affected rows. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] login problem fixed!!

2004-03-25 Thread Richard Davey
- please note this will only catch invalid queries. To catch the event of the query being perfectly fine, but nothing coming back, just check the values of num_rows or affected_rows (depending on the query). -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP Genera

Re: [PHP] Re: still having login problems sigh

2004-03-25 Thread Richard Davey
Hello Andy, Thursday, March 25, 2004, 8:44:46 AM, you wrote: AB> whats the deal with that... (and i dont get any php/sql errors at all) Post your code, we can't debug user experiences :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mail

Re: [PHP] Re: still having login problems sigh

2004-03-25 Thread Richard Davey
on which will error. Try printing out the contents of the super-globals: print_r($_SESSION); print_r($_POST); print_r($_GET); (etc) And see what they contain. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsu

Re: [PHP] looping variables from a file

2004-03-24 Thread Richard Davey
the file contains one or two arrays... Why not just suck in the contents of the file using file_get_contents and they display the output? Perhaps using a regexp to search for the = sign and anything on the left is the variable name? -- Best regards, Richard Davey http://www.phpcommunity.org/

Re: [PHP] Session problem

2004-03-24 Thread Richard Davey
ion it cc> throw me an error, for session expire, how can i fic that?. You can control the default lifespan of your session by modifying your php.ini file (look for the Session section, specifically session.gc_maxlifetime). You could also modify this via ini_set(). -- Best regards, Richard

Re: [PHP] what can be wrong here?

2004-03-22 Thread Richard Davey
ugh, it's a simple solution - you are not setting the border colour in your CSS a:hover attribute, you're setting the text colour. Just add "border: 1px solid black" to it. Note this will apply to any link now though, so perhaps creating a new "ImageLink" class with

[PHP] Timing a MySQL response

2004-03-21 Thread Richard Davey
sible?). I guess I could wrap a simple timer function before and after the query, but as MySQL seems to have this value already I'd rather not if I don't have to. Suggestions welcome! -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mai

Re: [PHP] Re: php and CSS level 2

2004-03-20 Thread Richard Davey
ally, forcing it to download it every single time? I can think of instances when this would be a desirable result, but they are far and few between :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Simple question

2004-03-19 Thread Richard Davey
t;". 2) If you DO need the name (because of JavaScript or something) then just place a check in your foreach loop to ignore the $key called "go". -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[5]: [PHP] days of week

2004-03-19 Thread Richard Davey
was offered, just a "i want it this way now". So, your reply doesn't make sense if it was intended to be directed at me. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] str_replace or regex

2004-03-18 Thread Richard Davey
$ with /, yes? In which case a str_replace will do that just fine. Ignore the final letter of the string and just search for $$ and replace with a /. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, vi

Re: [PHP] Get form name after submission

2004-03-18 Thread Richard Davey
ame as a hidden form value? Or name your submit button accordingly? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] putting selected text in textarea i a string

2004-03-18 Thread Richard Davey
function for the simple reason that what you want is a CLIENT-SIDE change and PHP is 100% SERVER-SIDE. Try using a JavaScript function to modify a live textarea field. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To u

Re: [PHP] How to edit a datetime field?

2004-03-18 Thread Richard Davey
DATE table SET datefield = DATE_ADD(now(), INTERVAL 24 hour) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] ereg_replace help

2004-03-18 Thread Richard Davey
to me to try it. Thanks to John I now know when used in a block it's no longer limited to the start of the string. The code you posted above works, thanks. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] How to keep a timestamp from updating?

2004-03-18 Thread Richard Davey
ill change, created will remain the same. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] ereg_replace help

2004-03-18 Thread Richard Davey
Which will happily remove all alpha-numeric characters from $string! But I want it to remove anything but.. suggestions please? -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] How to do this in PHP?

2004-03-18 Thread Richard Davey
HTML (or rather, in this case a CSS) question - and I'm afraid has nothing to do with PHP. Suggest you join a web design mailing list for topics like this. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsu

Re: [PHP] Letter incrementing

2004-03-18 Thread Richard Davey
;C" Sure: You'll get "b" :) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[4]: [PHP] days of week

2004-03-18 Thread Richard Davey
ale); DC> } DC> $sunday = strtotime('1 January 1995'); // That day was a Sunday DC> return strftime("%A", $sunday+(3600*24*$day)); DC> } So despite asking for a way to do it without using dates in functions, that's exactly what you're doing?

Re[2]: [PHP] days of week

2004-03-18 Thread Richard Davey
Hello Diana, Thursday, March 18, 2004, 12:00:55 PM, you wrote: DC> yes but I want it in various languages. Not in your *original* post you didn't (the one that I replied to). Besides, it wouldn't be that hard to modify to make it happen. -- Best regards, Richar

Re: [PHP] days of week

2004-03-18 Thread Richard Davey
lt-in function that will do this (that doesn't rely on a date), but it's still quite easy to do: $days = array('','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday','Sunday'); $day_of_week = $days

Re[2]: [PHP] Simple: Whats wrong with this?

2004-03-17 Thread Richard Davey
e the right one depending if your variable exists already, etc. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Simple: Whats wrong with this?

2004-03-17 Thread Richard Davey
of the variable. Is there something in php.ini that JM> can prohibit this from working? ++ is a _post_ increment. This means it'll returns $correct first and then increment it by one. There is a section in the PHP manual on this (search for "Incrementing/Decrementing Operators&quo

Re: [PHP] refresh page

2004-03-16 Thread Richard Davey
TML that is refreshing the page though - not PHP. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] array $_POST problem

2004-03-16 Thread Richard Davey
can var_dump the whole thing) By looking at the structure like this you'll soon see how to access the values inside of it rather than second-guessing all the time. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] Switching First & Last Names in List

2004-03-16 Thread Richard Davey
Hello Ben, Tuesday, March 16, 2004, 4:24:12 PM, you wrote: BR> I missed this part, so here's my take with the solution I provided (I'm BR> including the print-out of the tags): Heh :) just as I posted about it too. -- Best regards, Richard Davey http://www.phpcommunity.o

Re[2]: [PHP] Switching First & Last Names in List

2004-03-16 Thread Richard Davey
it. But yeah, there are a few million ways to skin this cat. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Switching First & Last Names in List

2004-03-16 Thread Richard Davey
The $raw_names should be your list of names. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Regex help - PLease

2004-03-16 Thread Richard Davey
s match } (Code not tested, but you get the idea I hope) -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] current url function

2004-03-15 Thread Richard Davey
ng... any LM> ideas? If you are running PHP as an Apache module (and not CGI) then a correctly validated user will have their details in: $_SERVER['PHP_AUTH_USER'] and $_SERVER['PHP_AUTH_PW'] There is a whole chapter on this (16) in the manual. -- Best regards, Richard Dave

Re: [PHP] PHP Certification

2004-03-15 Thread Richard Davey
already have those then I don't see how that expertrating thing can hurt, but don't bank on it holding too much sway. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] failed to open stream: No such file or directory in

2004-03-15 Thread Richard Davey
Hello Mike, Monday, March 15, 2004, 6:15:04 PM, you wrote: MM> Is it possible in php.ini declare $basedir(for libraries)? Not exactly, but you can add a path to the include path list which should have the same end result. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/

Re: [PHP] failed to open stream: No such file or directory in

2004-03-15 Thread Richard Davey
hassle will be to define a global variable/constant called something like $basedir and set that. $basedir = "/var/www/html"; Now just use this in all your include lines: include "$basedir/lib/lib_main.php"; This will work from *anywhere* and not fail. -- Best regards, Richard Da

Re: [PHP] Problem with mkdir() under windows.

2004-03-15 Thread Richard Davey
the 's and the directory BJC> returns an error. Is there a way around this? This works fine for me on a Windows XP box: how are you building the directory name? Or did you mean some other "special" characters? -- Best regards, Richard Davey http://www.phpcommunity.org/wi

Re: [PHP] stripping content and parsing returned pages?

2004-03-15 Thread Richard Davey
om It will do EXACTLY what you need. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] PHP ftp web client

2004-03-15 Thread Richard Davey
Hello Mario, Monday, March 15, 2004, 11:40:45 AM, you wrote: MO> Can someone recommend me a good/stable PHP-FTP Web client? MO> I wasnt quite happy with the google search results :P Search hotscripts.com or Freshmeat.net -- Best regards, Richard Davey http://www.phpcommunity.org/wi

Re: [PHP] help with storing multiple values in session variables.

2004-03-15 Thread Richard Davey
-- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] use of @ operator to suppress errors

2004-03-15 Thread Richard Davey
normal? Yes because @ suppresses the errors on function calls, not variables (which is all $_GET['this'] is). It's like saying @$this - i.e. as you can see, it doesn't make sense. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP Gen

Re[2]: [PHP] help for getimagesize

2004-03-13 Thread Richard Davey
. No errors at all. This is XnView 1.68.1 on Windows XP. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] help for getimagesize

2004-03-13 Thread Richard Davey
Hello Norbert, Saturday, March 13, 2004, 3:13:10 PM, you wrote: NP> I'm sorry - bad reply ... :-( NP> Hi Richard, NP> unfortunately you err. NP> I use already XnView. NP> This program does not support the looked for formats. Yes, it does. Look harder. -- Best regards,

Re: [PHP] help for getimagesize

2004-03-13 Thread Richard Davey
12 = JB2 and 13 = SWC. JPX and JB2 are JPEG-2000 File Formats. Not sure about SWC, but JPC is a Jpeg2000 CodeStream. You can download the excellent FREE XnView from www.xnview.com which will load (and save) JPX and JB2 files (as well as hundreds of other formats). -- Best regards, Rich

Re[8]: [PHP] STrange Problem

2004-03-12 Thread Richard Davey
Hello PHP, Friday, March 12, 2004, 7:23:47 PM, you wrote: P> It returns: P> Connected successfully P> Like I said, I have not problems connecting. Only mysql_select_db will not P> work. Fine, what does this return? With "foo" replaced with your database name. --

Re[6]: [PHP] STrange Problem

2004-03-12 Thread Richard Davey
on't just remove the "user" and "password" parts, fill them in. If there is no password, put "". -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[4]: [PHP] STrange Problem

2004-03-12 Thread Richard Davey
rying the database from within *MySQL* itself, right? i.e. from the command-line? As Tom pointed out, your error stated that no username was given. Have you tried the command using the root MySQL user account? It's possible the "apache" one hasn't been configured correctly

Re[4]: [PHP] STrange Problem

2004-03-12 Thread Richard Davey
Hello trlists, Friday, March 12, 2004, 6:48:03 PM, you wrote: tcc> Agreed, as long as he's not connected so someone can try to connect to tcc> the MySQL port. If he's connected that long and not running a firewall, he deserves it ;) -- Best regards, Richard Davey http://www.

<    2   3   4   5   6   7   8   9   10   11   >