[PHP] Re: A Doubt!

2002-08-19 Thread Kondwani Spike Mkandawire


Thiruvelraj Pokkishamani [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...


   Sir,
  I am using Windows 2000 server, and i use IIS 4.0 as the
 server and i have done many php scriptings and everything works
 fine and i done have any problem regarding this.

  And i want to send mail to the visitors of this site .
 for that purpose i use mail() and if i click send button i receive
 server error in D:\inetpub\wwwroot\test\sendmail.php .
 i have tried many scripts and i receive this error.

  Some  says that i want to configure the server ,
 how to configure and just iam a beginner to this PHP.
 if u help me it could b fine for me to finish this project.

 Xpecting ur mail.

  Yours Thankingly
   Thiruvelraj


If you have tested the same script on a different Server it may
just be an issue of the fact that IIS and PHP are not the greatest
of combos...  My scripts tested on my localhost running Apache
usually give me problems when I transfer them to an IIS Server
(particularly 4.0)...  They generate error messages but have
the expected functionality if this is the case with your Script
stick in some @ symbols like so:

echo @Whatever I want to print out
if variables are returned as undefined within
this echo statement;
$something = @$somethingElse;

If the functionality is not as expected then it could probably be
something else and it would really help if you posted sections of
your script which you suspect to cause the errors...

Spike...



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Re: PHP doubt

2002-05-29 Thread Girish Nath

Hi

Make sure you have an auto_increment field in your table, do the insert
first, then use mysql_insert_id() to get the number of the last which you
can use for the customer number. See the notes at the following page:

http://www.php.net/manual/en/function.mysql-insert-id.php

Regards


Girish
--
www.girishnath.co.uk


R [EMAIL PROTECTED] wrote in message
000301c20772$9538d0b0$0a6da8c0@lgwezec83s94bn">news:000301c20772$9538d0b0$0a6da8c0@lgwezec83s94bn...
 Hey guys,

 I have written a program and being a newbie I dont know if this is good or
 will give me problems in the future, so will appreciate it if you could
just
 have a look at the function and give me your esteemed opinion ;-)
 This is just a snip from the program...its pretty easy so your guru's
should
 have no problem figuring it out.


 // connected to the database successfully and running this query:
 {
 mysql_query.etc
 $r=select max(cno)+1 from customer;
 insert into customer values($r,'$name');
 }
 print(Your customer number is: $r);

 what do you think? And will this return the correct values if 2 people
 submitted the form at the same time?


 Cheers,
 -Ryan.




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php