Announcement

Collapse
No announcement yet.

V11 Mailform edit

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    V11 Mailform edit

    for the last three versions i have used a modified mailform to obtain names and addresses and am slowly working through V11 to put my script mods back in but have come across a problem with the mailform in v11

    I edit the mailform.pl file to allow sending of the additional information as shown below

    Code:
            # Construct the mail text and send it to the merchant
            #
            $sError = ACTINIC::GetPhrase(-1, 2377);
            $sTextMailBody .= ACTINIC::GetPhrase(-1, 2370) . $sName . "\r\n";
            $sTextMailBody .= "Company or House: " . $::g_InputHash{'HOUSE'} . "\r\n";
            $sTextMailBody .= "Street: " . $::g_InputHash{'ADDRESS1'} . "\r\n";
            $sTextMailBody .= "Town: " . $::g_InputHash{'ADDRESS2'} . "\r\n";
            $sTextMailBody .= "City: " . $::g_InputHash{'ADDRESS3'} . "\r\n";
            $sTextMailBody .= "County: " . $::g_InputHash{'ADDRESS4'} . "\r\n";
            $sTextMailBody .= "PostCode: " . $::g_InputHash{'ADDRESS5'} . "\r\n";
            $sTextMailBody .= ACTINIC::GetPhrase(-1, 2371) . $sEmailRecpt . "\r\n";
            $sTextMailBody .= "Phone Number: " . $::g_InputHash{'PHONE'} . "\r\n";
            $sTextMailBody .= "Catalogue Required: " . $::g_InputHash{'catalogue'} . "\r\n";
            $sTextMailBody .= ACTINIC::GetPhrase(-1, 2373) . "\r\n" . $sMessage . "\r\n\r\n";
            my @Response = ACTINIC::SendMail($::g_sSmtpServer, $$::g_pSetupBlob{EMAIL}, $sSubject, $sTextMailBody, $sEmailRecpt);
            if ($Response[0] != $::SUCCESS)
                {
                ACTINIC::RecordErrors($Response[1], ACTINIC::GetPath());
                $sError = $Response[1];
                }
            #
            # Now bounce back to the mail page
    this allows me to collect the details entered in the modified contact us form, shown below
    Code:
    <tr>
    <td>&nbsp;</td>
    <td>Company or House:</td>
        <td><input name="Company or House" size="50" maxsize="125" value="" /></td>
      </tr>
    <tr>
      <td>&nbsp;</td>
    <td><span class="actrequiredcolor">Street: *</td>
        <TD><input name="Street" size="50" maxsize="125" value="" /></td>
        </tr>
    <tr>
      <td>&nbsp;</td> 
        <td>Town:</td>
        <TD><input name="Town" size="50" maxsize="125" value="" /></td>
      </tr>
    <tr>
    <td>&nbsp;</td>
        <td>City:</font></td>
        <td><input name="City" size="50" maxsize="125" value="" /></td>
       </tr>
    <tr>
    <td>&nbsp;</td> 
        <td><span class="actrequiredcolor">County: *</td>
        <td><input name="County" size="50" maxsize="125" value="" /></td>
        </tr>
    <tr>
    <td>&nbsp;</td> 
        <td><span class="actrequiredcolor">Post Code: *</td>
        <td><input name="Postcode" size="50" maxsize="125" value="" /></td>
        </td>
      </tr>
      <tr>
    <td>&nbsp;</td> 
        <td><span class="actrequiredcolor">Phone No: *</td>
        <td><input name="Phone_No" size="50" maxsize="125" value="" /></td>
        </td>
      </tr>
    Now my problem is that V11 no longer seems to send this info and i do not understand why, i can see no reason why captcha would effect this but then im no expert in these fields

    Can anyone shed some light on the subject, i have also checked the mailform script on the server and the uploaded version has the mod in it

    Darren

    PS can V11 be added to this sections title

    #2
    does anyone have any suggestions or ideas?

    Comment


      #3
      Lonely old thread

      but i have now got it working, maybe i could not see the wood from the trees. I started from scratch and all seems to be working fine now.

      Amazing a slight error and it all falls down although i still dont know what the exact error was

      Comment


        #4
        aww, I missed the original post (was "holiday-ing" in UK when you posted!) but I didn't have any problems editting mine (for similar purpose)

        I'd have definitely recommended PBCAK
        Tracey

        Comment


          #5
          Formail Not Working

          Hi,
          I hope someone can help me. I'm using Actinic V11. I have edited my contact page and formail to enable customers to send more information when sending an email, these fields are mandatory. However there is no error to say the additional fields need to be filled in and the additional fields do not get sent with the email. All that gets sent are the default fields.

          I have attached code for contact page and formail, thank you
          Attached Files

          Comment


            #6
            Hi

            Your problem lies here
            Code:
            my @Response = ACTINIC::SendMail($::g_sSmtpServer, $$::g_pSetupBlob{EMAIL}, $sSubject, $sTextMailBody, $sEmailRecpt, $stelnumber, $saddress, $sbusinesstype, $syearstrading, $sproduct);
            You cannot just add extra variables to a call to another routine, the sendmail routine expects a specific number of parameters and you have added five more which will not work.

            Put that line back to its original state, and it should then work as you have already added the variables to the variable $sTextMailBody in the previous lines so all that data is now part of the body of the email.

            Malcolm

            SellerDeck Accredited Partner,
            SellerDeck 2016 Extensions, and
            Custom Packages

            Comment


              #7
              Formail Not Working

              Thank you I will do what you suggested and let you know the outcome

              Comment

              Working...
              X