ok, now with this, it shows one result, and there's more than one...
Code: Select all
<?php
echo "<span class=style20>";
//include the header
require("../configlog.php");
$result = mysql_query("SELECT * FROM users WHERE news='yes'") or die(mysql_error());
$row = mysql_fetch_array( $result );
echo "<br><center>";
echo "Forgot your password? Just enter your email into the field below, and we will email you the password.<br><br>";
echo "<form method=post action=newsletter.php?action=email>
Send to:<input type=text name=Email value=" . $row['Email'] . "><br>
<input type=text name=subject>
<input type=text name=message>
<input type=submit value=Continue></form>";
$_email = $row['Email'];
$lineArray = explode('$_email', $_email);
$lineArray = array_map('trim', $lineArray);
var_dump($lineArray);
anyone see why? i sure dont :/
if there's a better way to approach getting results from a field called news, from each user, and showing all users email that have news field to equal yes, please let me know, please

What im trying to do is make a code for a newsletter, so all users who have the news field to equal yes show up their email, so i know who and where to send the newsletters to.