I don't know if it's the solution to this specific problem but you should always be neat and use quotes:
echo "<a href=\"do_delete.php?id=$row->id\" onClick=\"return confirm('Are you sure you wanna do this?');\"><b> DELETE </b></a>";
Maybe it helps, maybe it doesn't, but it does make your coding cleaner.