[PHP] Re: magic quotes

2003-04-02 Thread Foong
magic_quotes_runtime is on, you need to use stripslashes() on data colected from database. It is not only apply to data collected from database, others as well. I believe there is a details guide in the php documentation at php.net. Foong "Justin French" <[EMAIL PROTECTED]> wrote

Re: [PHP] date math question

2003-03-27 Thread Foong
sorry typo error should be: date('Y') Foong "Foong" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > hi, > > $start = mktime ( 0, 0, 0, 1, 1, date['Y']); // first day of this year > $end = mktime ( 0, 0, 0, 12, 31, date['Y

Re: [PHP] date math question

2003-03-27 Thread Foong
hi, $start = mktime ( 0, 0, 0, 1, 1, date['Y']); // first day of this year $end = mktime ( 0, 0, 0, 12, 31, date['Y']); // last day of this year then select all record where timestamp >= $start and timestamp <= $end should do the job Hope this helps Foong

[PHP] Re: Problem with PHP

2003-03-27 Thread Foong
can i have a peek on you code Foong "Jan Navratil" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > > > Hallo, > > > > i have problem with running PHP4.3.1 on Apache1.3.19 on W2K. > > > > I instaled everithng by install.txt. I

[PHP] Re: Retrieving newly created ID from MySQL?

2003-03-26 Thread Foong
hello just call: mysql_insert_id(); right after you execute a insert statement Foong "Ben Cheng" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > If I have a MySQL table with an auto-incrementing ID field, is there an > easy way to retrieve the new ID af

[PHP] Informix

2003-03-20 Thread Foong
Hello any idea how can i fix this problem when I compile php with informix ERROR: /opt/informix/lib/esql/libifos.so: the use of `mktemp' is dangerous, better use `mkstemp' Foong -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] running PHP through command shell

2003-03-19 Thread Foong
Does anybody knows why I get call to undefined function for mysql_connect when running PHP through command shell. but it works fine when accessing the script through web browser. Foong -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Detecting if GET field is Numeric or Alpha numeric

2003-03-18 Thread Foong
Helo, use is_numeric($str) to check whether a string contains all numeric values. Foong "Stephen Of Blank Canvas" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi Everyone, > > Does anyone know if it is possible to check the values of a $_GET field &

Re: [PHP] stripping slashes before insert behaving badly

2003-03-17 Thread Foong
if Magic_quotes_gpc in you php.ini is set to 'on', php will automatically escape(add slashes) for you. Foong "Charles Kline" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > John, > > You are right, something was adding the additional slash.

[PHP] Re: SUBMIT

2003-03-07 Thread Foong
OK sorry i miss this post. looking at you code. I guess there are mismatch of opening and closing tags. In HTML double slashes // is not a comment. when you do something like // The tag wont get commented use: to comment a html tag out side php scope. Foong "Diksha Neel" <[EM

[PHP] Re: submit button

2003-03-07 Thread Foong
sorry, I really didn't seen any attachment in any of your post. can you paste it in your next post? foong "Diksha Neel" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > hi everybody, > > i have a PHP script by name registration.php > in which i h

[PHP] Re: submit button

2003-03-07 Thread Foong
can i have a peek on your diki.php? I didn't see any attachment. Foong "Diksha Neel" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > hi everybody, > > i have a PHP script by name registration.php > in which i have a submit button at the bottom.

[PHP] Re: textarea new line

2003-01-23 Thread Foong
u can use nl2br() to convert \n to tags b4 echo the string in textarea. Foong "Neil M" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Adi wrote: > > i want to add in textarea a string with new line tag in it. how to do

[PHP] Re: Disable pic copy/save?

2003-01-23 Thread Foong
try this article http://www.devarticles.com/art/1/265 However it is not perfect. Foong "Anthony Rodriguez" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi! > > A client wants to test market two versions of an advertising

[PHP] Re: Multi-Byte String Functions

2003-01-22 Thread Foong
I never use mg_* function b4. You should try post you question on php.i18n. bcos it is the newsgroup dedicated for localization Foong "Sadeq Naqashzade" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi all, > I'm new

[PHP] Re: PHP Sessions

2003-01-21 Thread Foong
serid']; Sorry if it's not relevant. Foong "Tim Thorburn" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi, > > After a day and a half of pounding my head against the wall I believe I've > identified the source of t

[PHP] Re: Multiplication of double

2003-01-19 Thread Foong
have you try echo $price and $qty separately to check if they are correct? If they are correct, can you post you code? so we can take a look. Foong Cesar Aracena <[EMAIL PROTECTED]> wrote in message 01c2bfeb$cecbd5c0$7a00a8c0@NOTEBOOK">news:01c2bfeb$cecbd5c0$7a00a8c0@

[PHP] Re: sending array

2003-01-15 Thread Foong
I am not sure you can do it way, here is what i suggest test2.php?org[index-A]=&org[index-B]=.. you need to specify each var in you array in the query path. Danielle Van Gladbach <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi, > > I am trying to send

[PHP] Re: htmlspecialchars

2003-01-14 Thread Foong
Thank you guys Foong Foong <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi, > I wonder which is the better way to store data into database? > 1. stor the data after we call htmlspecialchars with the data (means we > store " as

[PHP] Re: globals off in function

2003-01-14 Thread Foong
instead of: global $smarty; $smarty]->assign("message", $message); try: $_GLOBAL['smarty']->assign("message", $message); Foong Michael Bevz <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi, all!!! >

[PHP] Re: valid MySQL result resource

2003-01-14 Thread Foong
put the following line after you call mysql_query(..), you should be able to see the error: echo mysql_error(); this line is very handy to see what's wrong with mysql related operation. Remember to delete it after debugging for security reasons Foong Brent Lee <[EMAIL PROTECTED]&g

[PHP] Re: query question

2003-01-14 Thread Foong
RE zip_code IN('$zip_list')"; $hdl = mysql_query($hdl); Foong Kelly Meeks <[EMAIL PROTECTED]> wrote in message 009c01c2bbf5$03496b00$6901a8c0@yourw92p4bhlzg">news:009c01c2bbf5$03496b00$6901a8c0@yourw92p4bhlzg... I've got an array of values, that I need to que

[PHP] htmlspecialchars

2003-01-14 Thread Foong
Hi, I wonder which is the better way to store data into database? 1. stor the data after we call htmlspecialchars with the data (means we store " as "e; in database) 2. stor the data in non encoded form and call htmlspecialchars whenever we want to display it. Foong -- PHP Gener