mburse1977 Posted November 22, 2008 Share Posted November 22, 2008 All the fields but one the list_email field will show the info in the form box. Why won't the list email field show up in the form. The data base has the info in that field and it shows on other file where i coded it but im missing something here any help would be nice i would dance at your wedding. <center> <p><font size=6>Edit My Details</font></p> <form method="POST" action="editnow.php"><br> Name:<br><input type="text" name="Name" value="<? echo $name; ?>"><br> <input type="hidden" name="Userid" value="<? echo $userid; ?>"> Password:<br><input type="password" name="Password" value="<? echo $password; ?>"><br> Password Verification:<br><input type="password" name="Password2" value="<? echo $password; ?>"><br> Contact Email:<br><input type="text" name="ContactEmail" value="<? echo $contact_email; ?>"><br> List Email:<br><input type="text" name="ListEmail" value="<? echo $list_email; ?>"><br> the only one that dose not show is the list the rest work fine. Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/ Share on other sites More sharing options...
.josh Posted November 22, 2008 Share Posted November 22, 2008 that chunk of (non-code-tagged) code won't really help us help you out... perhaps you mis-spelled the column name in the query string, or when assigning the result to $list_email or perhaps you made a var called $ListEmail instead of $list_email? who knows? show more code. Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696401 Share on other sites More sharing options...
mburse1977 Posted November 22, 2008 Author Share Posted November 22, 2008 Thats all the code on the page. I might mention in new at coding in any form so this is still a learning experience to me. <?php session_start(); include "../header.php"; if ($userid<>"") { include "../configpost.php"; } else { include "../config.php"; } include "../style.php"; if( ($userid<>"")&&($password<>"") ) { include("navigation.php"); include("../banners.php"); echo "<font size=2 face='$fonttype' color='$fontcolour'><p><center>"; ?> <center> <p><font size=6>Edit My Details</font></p> <form method="POST" action="editnow.php"><br> Name:<br><input type="text" name="Name" value="<? echo $name; ?>"><br> <input type="hidden" name="Userid" value="<? echo $userid; ?>"> Password:<br><input type="password" name="Password" value="<? echo $password; ?>"><br> Password Verification:<br><input type="password" name="Password2" value="<? echo $password; ?>"><br> Contact Email:<br><input type="text" name="ContactEmail" value="<? echo $contact_email; ?>"><br> List Email:<br><input type="text" name="ListEmail" value="<? echo $list_email; ?>"><br> <? if ($pay_with['paypal']) { ?> Paypal Email:<br><input type="text" name="PaypalEmail" value="<? echo $paypal_email; ?>"><br> <? } ?> <? if ($pay_with['alertpay']) { ?> Alertpay Email:<br><input type="text" name="AlertpayEmail" value="<? echo $alertpayemail; ?>"><br> <? } ?> <? if ($pay_with['safepay']) { ?> Safepay Email:<br><input type="text" name="SafepayEmail" value="<? echo $safepayemail; ?>"><br> <? } ?> <? if ($pay_with['moneybookers']) { ?> Moneybookers Email:<br><input type="text" name="MoneybookersEmail" value="<? echo $moneybookersemail; ?>"><br> <? } ?> <br><br><br> <input type="hidden" name="oldemail" value="<? echo $list_email; ?>"> <input type="hidden" name="oldemail" value="<? echo $contact_email; ?>"> <input type="submit" value="Update"> </form> </center> <? if ($verified != 1) { ?> <center><p>Your account is unverified, click this button to have your verification email resent.</p> <form method="POST" action="resendv.php"> <input type="hidden" name="userid" value="<? echo $userid; ?>"> <input type="hidden" name="contact email" value="<? echo $contact_email; ?>"> <input type="hidden" name="Listemail" value="<? echo $list_email; ?>"> <input type="submit" value="Resend"> </form> </center> <? } else {?> <form method="POST" action="vacation.php?action=go"> <input type="submit" value="Go on vacation"> </form> </center> <? } echo "</font></td></tr></table>"; } else { ?> <font size=3 face="<? echo $fonttype; ?>" color="<? echo $fontcolour; ?>"><p><b><center>You must be logged in to access this site. Please <a href="../index.php">click here</a> to login.</p></b></font> <? } include "../footer.php"; mysql_close($dblink); ?> Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696408 Share on other sites More sharing options...
.josh Posted November 22, 2008 Share Posted November 22, 2008 so...where's the code that assigns the data to those variables? (and please use code tags when posting code) Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696427 Share on other sites More sharing options...
mburse1977 Posted November 22, 2008 Author Share Posted November 22, 2008 It is working off a data base the (?list_email) Is a sub table in the data base. I though the echo (?$list_email?); Pulls that info from that table might be wrong but the others are showing and there coded the same. Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696450 Share on other sites More sharing options...
mburse1977 Posted November 22, 2008 Author Share Posted November 22, 2008 This is the file with the array in it. hope this helps. (<?php include "connect.php"; $settings = mysql_query ('select * from settings'); $settingrecord = mysql_fetch_array($settings); while ($settingrecord = mysql_fetch_array($settings)) { switch ($settingrecord["name"]) { case "sitename"; $sitename = $settingrecord["setting"]; break; case "adminid"; $adminid = $settingrecord["setting"]; break; case "adminpw"; $adminpw = $settingrecord["setting"]; break; case "paypal"; $paypal = $settingrecord["setting"]; break; case "stormpay"; $stormpay = $settingrecord["setting"]; break; case "adminemail"; $adminemail = $settingrecord["setting"]; break; case "freepoints"; $freepoints = $settingrecord["setting"]; break; case "propoints"; $propoints = $settingrecord["setting"]; break; case "exclusivepoints"; $exclusivepoints = $settingrecord["setting"]; break; case "propointsmonthly"; $propointsmonthly = $settingrecord["setting"]; break; case "exclusivepointsmonthly"; $exclusivepointsmonthly = $settingrecord["setting"]; break; case "freepointsmonthly"; $freepointsmonthly = $settingrecord["setting"]; break; case "proprice"; $proprice = $settingrecord["setting"]; break; case "exclusiveprice"; $exclusiveprice = $settingrecord["setting"]; break; case "prointerval"; $prointerval = $settingrecord["setting"]; break; case "exclusiveinterval"; $exclusiveinterval = $settingrecord["setting"]; break; case "proreadearn"; $proreadearn = $settingrecord["setting"]; break; case "exclusiveoreadearn"; $exclusivereadearn = $settingrecord["setting"]; break; case "freereadearn"; $freereadearn = $settingrecord["setting"]; break; case "proclickearn"; $proclickearn = $settingrecord["setting"]; break; case "exclusiveclickearn"; $exclusiveclickearn = $settingrecord["setting"]; break; case "freeclickearn"; $freeclickearn = $settingrecord["setting"]; break; case "freecommission"; $freecommission = $settingrecord["setting"]; break; case "exclusivecommission"; $exclusivecommission = $settingrecord["setting"]; break; case "procommission"; $procommission = $settingrecord["setting"]; break; case "freerefpoints"; $freerefpoints = $settingrecord["setting"]; break; case "exclusiverefpoints"; $exclusiverefpoints = $settingrecord["setting"]; break; case "prorefpoints"; $prorefpoints = $settingrecord["setting"]; break; case "basecolour"; $basecolour = $settingrecord["setting"]; break; case "contrastcolour"; $contrastcolour = $settingrecord["setting"]; break; case "fonttype"; $fonttype = $settingrecord["setting"]; break; case "fontcolour"; $fontcolour = $settingrecord["setting"]; break; case "scratchfreq"; $scratchfreq = $settingrecord["setting"]; break; case "scratchodds"; $scratchodds = $settingrecord["setting"]; break; case "maxwinning"; $maxwinning = $settingrecord["setting"]; break; case "bannerprice"; $bannerprice = $settingrecord["setting"]; break; case "soloprice"; $soloprice = $settingrecord["setting"]; break; case "pointprice"; $pointprice = $settingrecord["setting"]; break; case "freepost"; $freepost = $settingrecord["setting"]; break; case "exclusivepost"; $exclusivepost = $settingrecord["setting"]; break; case "propost"; $propost = $settingrecord["setting"]; break; case "domain"; $domain = $settingrecord["setting"]; } } $userinfo=mysql_query ("select * from members where userid='".$userid."'"); $userrecord=mysql_fetch_array($userinfo); $id=$userrecord["id"]; $name=$userrecord["name"]; $contact_email=$userrecord["contact_email"]; $list_email=$userrecord["list_email"]; $subscribed_email=$userrecord["subscribed_email"]; $paypal_email=$userrecord["paypal_email"]; $stormpay_email=$userrecord["stormpay_email"]; $contact_email=$userrecord["contact_email"]; $list_email=$userrecord["list_email"]; $password=$userrecord["pword"]; $userid=$userrecord["userid"]; $status=$userrecord["status"]; $referid=$userrecord["referid"]; $verified=$userrecord["verified"]; $solos=$userrecord["solos"]; $points=$userrecord["points"]; $commission=$userrecord["commission"]; $ip=$userrecord["ip"]; $joindate=$userrecord["joindate"]; $lastpost=$userrecord["lastpost"]; $subscribed=$userrecord["subscribed"]; $memtype=$userrecord["memtype"]; ?>) Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696453 Share on other sites More sharing options...
mburse1977 Posted November 23, 2008 Author Share Posted November 23, 2008 A pack of cigs and a cupple beers and i finally found the problem. I had one of the strings set wrong in one of the three file connected to the string in this one.That is one problem to using several files for each page you get lost after the fist one. Thanks for all the help Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696674 Share on other sites More sharing options...
redarrow Posted November 23, 2008 Share Posted November 23, 2008 please use code tags next time mate........ Quote Link to comment https://forums.phpfreaks.com/topic/133808-solved-feilds-in-forms-wont-show-info-form-data-base/#findComment-696677 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.