[PHP] Re: values from string query

2004-02-26 Thread André Cerqueira
o is intended for the attention and use only of the addressee. Should you have received this e-mail in error, please delete and destroy it and any attachments thereto immediately. Under no circumstances will the Cape Technikon or the sender of this e-mail be liable to any party for any direct, in

[PHP] Re: values from string query

2004-02-26 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 oops i changed the name of a variable in one place and forgot the other... mysql_query($sql, $this->link) or die ("".mysql_error()); André cerqueira wrote: you may find "insert ... select" interesting for what you want hehe t

[PHP] Re: Question about CGI binary

2004-02-26 Thread André Cerqueira
PHP is installed as a > CGI binary safe mode is on by default? > Chris > > "André cerqueira" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > http://www.php.net/set_time_limit [snip] > Warning > set_time_limit() has NO EFFECT when

Re: [PHP] Weird result from query...?

2004-02-26 Thread André Cerqueira
where oorder='".$o."' and nname='".$n."' and total=$p without the single quotes around $p Erwin Kerk Web Developer - -- André Cerqueira -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.4 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.o

[PHP] Re: Question about CGI binary

2004-02-25 Thread André Cerqueira
it which seems to have no effect. Is is possible that the timeout is being caused by a cgi script execution limit? Or may something else be afoot? Chris - -- André Cerqueira -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.4 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.moz

[PHP] Re: Apache/IE hangs with PHP

2004-02-25 Thread André Cerqueira
Thanks for your help, Vincent - -- André Cerqueira -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.4 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFAPZooaxdA/5C8vH8RAlPRAKC0rWq5pgp1uQjhxIZ1PEOjdxFl8wCghiPI 5GdpbYgIWQQQBDWVuNqXXOw= =D3lA -END PGP SIGNATURE-

Re: [PHP] function.date.php

2004-02-25 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 the other 3 answers were more appropriate what newsreader are you ppl using? is anyone else getting anoyed with posts out of chain? :p Sam Masiello wrote: Actually, your use of substr is incorrect. The third parameter is how many characters you want

[PHP] Re: where is my uploaded file ?

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 > bool move_uploaded_file ( string filename, string destination) > > If filename is not a valid upload file, then no action will occur, and > move_uploaded_file() will return FALSE. > > If filename is a valid upload file, but cannot be moved for some

[PHP] Re: Please dont request for receipts

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Agreed hehe I would also like to ask why are there so many threads starting with "Re:" Is that a bug on this newsgroup or people dont care about posting inside the thread they replying to? Nitin Mehta wrote: Dear All, I hereby request you all; pleas

[PHP] Re: Scroll en barra de mensajes del explorer

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 php is server side scroll bar on explorer message bar (what is that?) is client side conclusion: no, you can not use php for that i think ppl would prefer if you posted in english php es el lado del servidor barra de mensajes del explorer (cuál es ése?

Re: [PHP] beginners question

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 to avoid other issues followed by other threads about the same stuff of every 2 weeks: echo 'Click to add' John Nichel wrote: Steve wrote: I have this code $var=$_POST['Stock']; in one page further down in the code, if certain conditions are me

[PHP] Re: preg_guru

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 delimiters? ex: preg_match("/(:[0-9]{16}:)/", $contents, $match); or something like that... http://br2.php.net/manual/en/function.preg-match.php http://br2.php.net/manual/en/ref.pcre.php welcome to php manual hehe btw, are you actually running those 3

[PHP] Re: Problem deleting a cookie...

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 > Here's what I use to set the cookie. > $value=(time() + 9000) . ":$uid:$username:$gid:$fullname"; > SetCookie("Trackookie", $value, 0, "", "server.mssystems.com" ); > > Here's what I use to delete the cookie. > SetCookie("Trackookie", "", time()-3600,

[PHP] Re: To Separate, or Not to Separate

2004-02-23 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 i think if the most accessed fields are much smaller than the hole thing, you can consider splitting it whats the average size of your records? whats the size of the fields you access the most? (check your sql's for that one...) amount of records woul

Re: [PHP] Help with '&' character

2004-02-17 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 the problem is the '&' on the url http://...&campaign=MBI%20List%20-%20Steel%20&%20Concrete ^ | there> this url is saying:

[PHP] Re: Help with '&' character

2004-02-17 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 http://...&campaign=MBI%20List%20-%20Steel%20&%20Concrete (wrong) http://...&campaign=MBI%20List%20-%20Steel%20%26%20Concrete (right) where does that url come from? is it generated by a script? if it is, you must urlencode() it before outputing, not whe

[PHP] Re: Are variables persistent?

2004-02-16 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul Furman wrote: When I refresh a script using a form, it goes through & resets all my custom Constants but presumably all my variables should still hold their values from the last run, right? THere are no functions involved. wrong What would cau

[PHP] Re: PHP Newbie Database Records?

2004-02-15 Thread André Cerqueira
is hit. $num_rows; always returns one numeric 1 even though there is no username like $username in the database ?? Have I missed something? Col "André cerqueira" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] I believe you forgot to read the manual. $query_qUse

[PHP] Re: PHP Newbie Database Records?

2004-02-15 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I believe you forgot to read the manual. > $query_qUsername = "SELECT * FROM users WHERE username = '$username'"; > $num_rows = mysql_num_rows($query_qUsername); $query_qUsername is a String mysql_num_rows want a result resource as argument You have n

[PHP] Re: File Injection Bug

2004-02-15 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 on index.php, are you including directly the file passed by content? if you are vulnerable, the autor of your index.php is the one to blame, not php hehe if safe mode is on, you may be immune to this asu.txt, but dont relly on it against everything el

[PHP] Re: Simple while loop skipping first row of array

2004-02-15 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 just fixing something hehe echo ""; $result = mysql_query("select * from cats order by title"); if ($result) { while ($c = mysql_fetch_array($result)) { echo "$c[title]"; } } echo ""; André

[PHP] Re: Simple while loop skipping first row of array

2004-02-15 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 try: echo ""; $result = mysql_query("select * from cats order by title"); while ($c = mysql_fetch_array($result)) { echo "$c[title]"; } echo ""; Verdon Vaillancourt wrote: I'm not sure I phrased my subject well, but... The following is just to bui

Re: [PHP] Re: preg guru question

2004-02-13 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 lol i meant you, but i wrote the other name instead... sorry again Adam Bregenzer wrote: On Sat, 2004-02-14 at 00:24, André Cerqueira wrote: strange bug happened on my newsreader... 'joel boonstra' regex seems to be the better one hehe

[PHP] Re: preg guru question

2004-02-13 Thread André Cerqueira
e brakets for \s... kinda stupid hehe André cerqueira wrote: did you post the same message 7 times? try: '; $pattern = '//i'; $matchFound = preg_match_all ($pattern, $subject, $matches, PREG_SET_ORDER); print_r($matches); //$matches[$i][1] is what really matters ?> that patt

[PHP] Re: preg guru question

2004-02-13 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 did you post the same message 7 times? try: '; $pattern = '//i'; $matchFound = preg_match_all ($pattern, $subject, $matches, PREG_SET_ORDER); print_r($matches); //$matches[$i][1] is what really matters ?> that pattern may not be the best regex to use,

[PHP] Re: cli input and screen question(s)

2004-02-13 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 http://br.php.net/manual/en/intro-whatcando.php "PHP is probably not the very best language to write windowing applications, but if you know PHP very well, and would like to use some advanced PHP features in your client-side applications you can also

Re: [PHP] Re: date() funtion language

2004-02-13 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hmz... i just tryed that... didnt work tryed other locale strings, didnt work... do i need something else to make it work? running php4.3.4rc3 on windows Don Read wrote: On 12-Feb-2004 André Cerqueira wrote: -BEGIN PGP SIGNED MESSAGE- Hash

Re: [PHP] Re: date() funtion language

2004-02-13 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 ohhh thanks hehe Don Read wrote: On 12-Feb-2004 André Cerqueira wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 i had problems with locale i think its safer to make a dayname and monthname array, and use getdate(), than build the string yourself

[PHP] Re: PHP FILE SIZE LIMIT

2004-02-11 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 everything has a limit, but im sure in this case you are under it big time ive seen ppl running 1-2megs scripts hehe Matthew Oatham wrote: hi is there a limit to the filesize of a php ? I know tomcat had limits on the file size of jsps. My problem

Re: [PHP] [Q]PHP not taking input values from forms

2004-02-11 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 time() is only echo'ed if $_POST['submit'] is something on this case maybe he has a really old version of php... $HTP_POST_VARS...? do what Richard Davey is saying, on the top Richard Davey wrote: Hello Dan, Wednesday, February 11, 2004, 6:39:35 PM,

[PHP] Re: date() funtion language

2004-02-11 Thread André Cerqueira
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 i had problems with locale i think its safer to make a dayname and monthname array, and use getdate(), than build the string yourself like: function date_wrapper($format, $timestamp=NULL) { global $wdayname_array, $monthname_array; if

Re: [PHP] HELP: Nested include(...)'s take relative paths

2004-02-10 Thread André Cerqueira
If it was a function, parenteses would be mandatory hehe I prefer no parentheses on include/require/echo/print/..., cant justify it with arguments though, its just the style i chose... What about: > if (...) { > ... > } and: > if (...) > { > ... > } I prefer the second, but people find good r

[PHP] Re: HELP: Detecting the name of the file a function is being called from

2004-02-09 Thread André Cerqueira
function called_from_file(){ $backtrace = debug_backtrace(); print $backtrace[0]['file']; } check: http://www.php.net/manual/en/function.debug-backtrace.php Samuel Ventura wrote: Hi there I have 2 scripts: function called_from_file(){ print __FIL

Re: [PHP] send script output to file

2004-02-08 Thread André Cerqueira
John Nichel wrote: Boneripper wrote: hi, i would like to send the output of a PHP script, to a file, and not to the browser. any ideas on how i can do this? tkx in advance, Use the manual, Luke. http://www.php.net/manual/en/ref.filesystem.php and: http://www.php.net/manual/en/ref.outcontr

[PHP] Re: how to conver a string to float

2004-02-08 Thread André Cerqueira
Sebastian wrote: Is there a possibility to convert a string like "10*500" (parsed from a XML-File) to a float? When i try to store this String in a float variable it only coverts the "10" but nothing after the "*"-sign, but i need the result of this expresison... Is there a function to calculate s

[PHP] Re: Can I do this?

2004-02-08 Thread André Cerqueira
John Taylor-Johnston wrote: Can I include a script on another server doing this? $sql = 'SELECT * FROM '.$table.' where number like '.$number.';'; http://foo.com?list.php?number=16 include("http://elsewhere.com/list.php";); My $sql is error-ing - obviously. http://elsewhere.com/list.php is not