Jump to content

chuck808

New Members
  • Posts

    2
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

chuck808's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hi mikosiko, Thanks for the reply. I have realised how thick I am, nTransactionId column is from $sql = "SELECT * from " . TABLEPREFIX . "transactiontxn where nSTId='" . $_REQUEST['nSTId'] . "'"; $res = mysql_query($sql) or die(mysql_error()); if ($srow = mysql_fetch_array($res)){ if ($srow['nUserId']==$_SESSION['guserid']) { $this_user = $srow['nUserId']; $other_user = $srow['nUserReturnId']; } }//end if I think I want to be able to show the transaction ID nSTID? Sorry for being so dense
  2. Hi, I hope I'm not about to offend anyone by posting this in the wrong place. V 5.1.56 I have a PHP SQL query/function that returns two users details based on a transaction Id from a transaction table and it works fine. However, in the returned result I would also like to show the Transaction Id and for the life of me I can't get it to work. This is the code showing one users details and the returned details below. $sql = "SELECT * from " . TABLEPREFIX . "transactiontxn where nSTId='" . $_REQUEST['nSTId'] . "'"; $res = mysql_query($sql) or die(mysql_error()); if ($srow = mysql_fetch_array($res)){ if ($srow['nUserId']==$_SESSION['guserid']) { $this_user = $srow['nUserId']; $other_user = $srow['nUserReturnId']; } }//end if if ($var_mode == "A" && $var_flag = "true") { $sql = "SELECT vLoginName,vFirstName,vLastName,vAddress1,vAddress2,vCity,vState, vCountry,nZip,vPhone,vFax,vEmail FROM " . TABLEPREFIX . "users U where nUserId='" . $this_user . "' "; $result = mysql_query($sql) or die(mysql_error()); if (mysql_num_rows($result) > 0) { if ($row = mysql_fetch_array($result)) { $var_login2 = stripslashes($row["vLoginName"]); $var_first2 = stripslashes($row["vFirstName"]); $var_last2 = stripslashes($row["vLastName"]); $var_address12 = stripslashes($row["vAddress1"]); $var_address22 = stripslashes($row["vAddress2"]); $var_city2 = stripslashes($row["vCity"]); $var_state2 = stripslashes($row["vState"]); $var_country2 = stripslashes($row["vCountry"]); $var_zip2 = stripslashes($row["nZip"]); $var_phone2 = stripslashes($row["vPhone"]); $var_fax2 = stripslashes($row["vFax"]); $var_email2 = stripslashes($row["vEmail"]); $var_transactionid = stripslashes($row["nTransactionId"]); }//end if }//end if $message = TEXT_DETAILS_OF_COMMUNITATION_GIVEN_BELOW; $var_form = "A"; }//end if else if ($var_mode == "R" && $var_flag = "true") { $message2 = TEXT_OFFER_REJECTED; $var_form = "R"; }//end else if What is returned; Full Name user name Address Line 1 user address Address Line 2 user address City user address State user address Country user address Zip user address Phone user number Fax user fax Email user email Transaction ID The Transaction isn't currently showing Any help would be appreciated
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.