Bugs » Small bug in my code I posted earlier about Autoadd

added on Jul 15, 2009 by jim
Bug fix for my code posted earlier as "AutoAdd problems and some errors in the
log for v20090603".

It was creating dups in the list, make sure you delete() the temporary "add" if your
link is already at the site. Oops, sorry... It should look something like this:

} else if ( strpos( $res, 'is allready in the database' ) !== false ) {
$l->delete();
return 'Allready listed at the site';
} else if ( strpos( $res, 'allready have' ) !== false ) {
$l->delete();
return 'Site already has one of your submitted links';
} else {
$l->delete();

.....

Add reply

This thread has been inactive for more than 14 days, so it has been locked.

Feel free to create a new thread with your questions.