Make WordPress Core

Changeset 3475


Ignore:
Timestamp:
01/23/2006 11:49:22 PM (19 years ago)
Author:
ryan
Message:

wp-mail quote escaping fix from majelbstoat. fixes #2209

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-mail.php

    r3085 r3475  
    6262                $author=trim($line);
    6363            if ( ereg("([a-zA-Z0-9\_\-\.]+@[\a-zA-z0-9\_\-\.]+)", $author , $regs) ) {
    64                 echo "Author = {$regs[1]} <p>";
    65                 $result = $wpdb->get_row("SELECT ID FROM $tableusers WHERE user_email='$regs[1]' ORDER BY ID DESC LIMIT 1");
     64                $author = $regs[1];
     65                echo "Author = {$author} <p>";
     66                $author = $wpdb->escape($author);
     67                $result = $wpdb->get_row("SELECT ID FROM $wpdb->users WHERE user_email='$author' LIMIT 1");
    6668                if (!$result)
    6769                    $post_author = 1;
Note: See TracChangeset for help on using the changeset viewer.