Jump to content

maweber98

New Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

maweber98's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I have a form that application form that collects information from the user then is processed by a form processor and inputs the information into a mysql database. After that is complete it then sends an email with the users information to me. I need to have this information emailed to me as an attachment. Does anyone have any ideas on how to do this? Do I have to write this information to a file on the server then attach that file? Or is there a way I could just duplicate this same information that is in the email but also have it as an attachement as well. Thanks so much! [code]$to = "mark@somedomain.com"; $message = "ID: $HRS_ApplicantID Prefix: $HRS_Applicant_namepfx First Name: $HRS_Applicant_firstname Middle Name: $HRS_Applicant_middlename Last Name: $HRS_Applicant_lastname Suffix: $HRS_Applicant_namesfx Social Security Number: $HRS_Applicant_ssno Home Phone: $HRS_Applicant_phone1 Cell Phone: $HRS_Applicant_phone2 Address: $HRS_Applicant_addr City: $HRS_Applicant_city State: $HRS_Applicant_state Zip Code: $HRS_Applicant_zip1st Referred By: $HRS_Applicant_ReferredBy Date Added: $HRS_ApplicantDateAdded Date Available: $HRS_Applicant_DateAvailable Applicant Employed: $HRS_Applicant_Employed Contact Current Employer: $HRS_Applicant_InqEmployer Job Salary: $HRS_Applicant_JobSal Applied Before: $HRS_Applicant_ApplyBefore Apply Before Where: $HRS_Applicant_ApplyBeforeWhere Apply Before When: $HRS_Applicant_ApplyBeforeWhen Employment Desired 1: $chosenDesired[0] Employment Desired 2: $chosenDesired[1] Military: $HRS_Applicant_military Military Rank: $HRS_Applicant_militaryRank Military Discharge: $HRS_Applicant_militaryDshrgTyp Military Notes: $HRS_Applicant_militaryNotes School1 Type: $HRS_ApplicantSchoolType School1 Name: $HRS_ApplicantSchoolNameLoc School1 Yrs Attended: $HRS_ApplicantSchoolYrsAtt School1 Graduate: $HRS_ApplicantSchoolGraduate School1 Subjects: $HRS_ApplicantSchoolSubjects Employment1 Start Date: $HRS_ApplicantEmplyHstryMYStart Employment1 End Date: $HRS_ApplicantEmplyHstryMYEnd Emplyment1 Name: $HRS_ApplicantEmplyHstryNameLoc Employment1 Salary Range: $HRS_ApplicantEmplyHstrySalRnge Employment1 Position: $HRS_ApplicantEmplyHstryPstn Employment1 Reason Leaving: $HRS_ApplicantEmplyHstryRsnLv Reference1 Name: $HRS_ApplicantReferenceName Reference1 Address: $HRS_ApplicantReferenceAddr Reference1 Business: $HRS_ApplicantReferenceBsnss Reference1 Years Known: $HRS_ApplicantReferenceYrsKnwn "; mail($to, 'Application Submission', $message); [/code] Thanks so much! I appreciate any and all help.
  2. It works perfectly now!! Thank you so much for all your help. I'm still a little new to PHP so any help is always greatly appreciated. This forum has been very helpful. Thanks again!!!!
  3. This is the code I'm trying to get to work. I just can't seem to figure out why the implode function is not working. [code] <? //Color Query //error message (not found message)begins $XX = "Colors Not Found\n"; //query details table begins $query = mysql_query("SELECT   coas50.pro_color_look_up.Color_ID,   coas50.pro_color_look_up.Item_ID,   coas50.pro_item.Description,   coas50.pro_item.Item_Number,   coas50.pro_color.Color FROM   coas50.pro_color_look_up,   coas50.pro_item,   coas50.pro_color WHERE   (coas50.pro_item.Item_Number = '$Item_Number') AND   (coas50.pro_item.ID = coas50.pro_color_look_up.Item_ID) AND   (coas50.pro_color_look_up.Color_ID = coas50.pro_color.ID) ORDER BY Color");      if ($query == FALSE) {    die ('Query not working! ' . mysql_error()); }    while ($row = mysql_fetch_assoc($query))     $variable2=$row['Color']; echo implode(', ',$variable2); //below this is the function for no record!! if (!$variable2) { print ("$XX"); } //end ?> [/code] This is the error message that I get: "Warning: Bad arguments to implode() in c:\apache\htdocs\products\product_output.php on line 239" Does anyone have any insight on this. Thanks so much!! I appreciate your help!
  4. I tried both of these methods and couldn't get either to work. I figured the implode method would have worked, but I get a "Bad Argument to implode" error. Does this error give any clues as to why it doesn't work the way it should. The color table is as follows: ID Color 0 Black 1 Blue 2 Red and so on. I don't think there is anything wrong in the way the table is set up. Does anyone have any idea way the implode function is not working? Thanks so much!!!!
  5. I'm having trouble with the code below. What I'm trying to do is query a database to get a list of colors that a particular item comes in. The problem I'm having is I'm a little confused on how to output the list of colors with a comma in between each one. Example" Red, Blue, Black The way I have it now in the code below is: print ("$variable2, "); which of course prints an extra comma at the end of the list of colors. [code] <? //Color Query //error message (not found message)begins $XX = "Colors Not Found\n"; //query details table begins $query = mysql_query("SELECT   coas50.pro_color_look_up.Color_ID,   coas50.pro_color_look_up.Item_ID,   coas50.pro_item.Description,   coas50.pro_item.Item_Number,   coas50.pro_color.Color FROM   coas50.pro_color_look_up,   coas50.pro_item,   coas50.pro_color WHERE   (coas50.pro_item.Item_Number = '$Item_Number') AND   (coas50.pro_item.ID = coas50.pro_color_look_up.Item_ID) AND   (coas50.pro_color_look_up.Color_ID = coas50.pro_color.ID) ORDER BY Color");      if ($query == FALSE) {    die ('Query not working! ' . mysql_error()); }    while ($row = @mysql_fetch_array($query)) { $variable2=$row['Color']; //table layout for results //prints extra comma at the end of results print ("$variable2, "); } //below this is the function for no record!! if (!$variable2) { print ("$XX"); } //end ?> [/code] Does anyone have an idea of how I can get this to work. It seems like it should be an easy solutions. Any help would be greatly appreciated. Thank you so much!!!
×
×
  • 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.