the number of emails to a given email address


The number of emails  to a given email address is updated each time an email is sent.  A request for a given address should be rejected unless the address is in the Authorization table and the number of current number of accesses for that address are below the limit.  Set the limit  at a value that reduces the risk of abuse of your web service if your reporter name and password are compromised.  You can enforce the limit and the authorized email addresses using SQL update command with an appropriate condition in its where clause.

Use the SQL update command in the PHP script to update the current attribute for the unique row with a matching address.  This command  should affect a row only if the address exists and if the limit for the address has not yet been reached.  The addresses and limit attribute values are manually set, and current is manually initialized to zero for each row.  Refer to IT 202 manual for the use of SQL update command (such as p. 239 of manual).  Refer to IT 202 manual or online PHP manual for related use of the mysql_affected_rows() function which returns how many rows were affected by the update (which will be zero if the request was un-authorized but one if the request was granted).

Request for Solution File

Ask an Expert for Answer!!
PHP Web Programming: the number of emails to a given email address
Reference No:- TGS0220569

Expected delivery within 24 Hours