Loading ...
Sorry, an error occurred while loading the content.

Re: [HTML-on-the-WEB] Form sent to me and others

Expand Messages
  • Michael Roush
    ... The php code looks as if it were written for PHP4.x or so. It appears there are some places where variables from the form are referenced without naming
    Message 1 of 7 , Jan 6, 2009
    • 0 Attachment
      --- *Maria Marsala*
      <discuss@...> wrote:

      > 1) It's not sending me a copy (as the site
      > owner)
      >
      > 2) It's not sending the client a copy (as the
      > one who wants
      > this information for future use
      >
      > 3) It's not sending the client a note from me.

      The php code looks as if it were written for PHP4.x or
      so. It appears there are some places where variables
      from the form are referenced without naming them from
      the $_GET[] or $_POST[] arrays (I know, this really
      has nothing to do with strict HTML, but there isn't
      much traffic on this list otherwise, so maybe you'll
      forgive me).

      Is your current web server running PHP 4.x, or PHP
      5.x? If it's 5.x, there are enhanced security
      features in place by default that won't allow that
      code to work for picking up the $EmailAddress
      variable.

      That probably shouldn't stop the e-mail to
      'forms@el...' from going, though. There is an at-sign
      in front of the "mail" function in the code... this
      prevents error messages from being displayed if the
      function triggers one. Removing those (temporarily)
      and testing the form yourself might give some new
      clues. You could remove them permanently (later, once
      it works) if you can set display_errors to "off" in a
      php.ini file.


      > 4) The dat file isn't saving the form in the
      > text file.

      Does that (text) file exist in the same directory as
      the form processor?



      Michael Roush
      mdroush@...

      "The power of the Web is in its universality. Access by everyone regardless of disability is an essential aspect."
      -- Tim Berners-Lee, W3C Director and inventor of the World Wide Web
    • Bob
      The $BusinessEmailAddress variable doesn t match the variable $EmailAddress used in sending mail:- pt_register( POST , BusinessEmailAddress );
      Message 2 of 7 , Jan 6, 2009
      • 0 Attachment
        The $BusinessEmailAddress variable doesn't match the variable $EmailAddress used in sending mail:-

        pt_register('POST','BusinessEmailAddress');
        $BusinessEmailAddress==""
        @mail($EmailAddress, 'Best Business Practice Assessment', $message, $headers);

        The one that is wrong depends which variable was used in the form.


        ----- Original Message -----
        From: "elevatingyourbusiness"

        > Well first problem is that the form was going to an email address
        > that is no longer used. I fixed that problem. But only 1 copy is
        > sent to me (and since I sent the form to myself) I should have
        > received two copies and one copy would have a private looking message
        > on the top and then the form answers on the bottom. That's what the
        > version that is missing.
        >
        >
        > Also, the answers are all bunched up on the email I recieved.
        >
        > If you can help me with these problems, LMK.
        >
        > Here is the code
        > <?php
        > include("global.inc.php");
        > $errors=0;
        > $error="The following errors occured while processing your form
        > input.<ul>";
        > pt_register('POST','FirstName');
        > pt_register('POST','LastName');
        > pt_register('POST','CompanyName');
        > pt_register('POST','WebsiteURL');
        > pt_register('POST','TelephoneNumber');
        > pt_register('POST','BusinessEmailAddress');
        > pt_register('POST','BusinessPlanandWrittenGoals');
        > pt_register('POST','DailyTrackingSystem');
        > pt_register('POST','BusinessPlanEffectiveness');
        > pt_register('POST','AttractingIdealClients');
        > pt_register('POST','ExitStrategy');
        > pt_register('POST','MarketingPlanEffectiveness');
        > pt_register('POST','MarketingSkills');
        > pt_register('POST','LeadGenerationSalesSystem');
        > pt_register('POST','LeadConversionClosing');
        > pt_register('POST','BrandingIdentity');
        > pt_register('POST','DistinctCompetitiveEdge');
        > pt_register('POST','ExpertStatusinYourIndustry');
        > pt_register('POST','ElevatorSpeechThatWorks');
        > pt_register('POST','NetworkingandFollowupProcess');
        > pt_register('POST','AdvertisingandPREfforts');
        > pt_register('POST','CustomerRetentionandLoyalty');
        > pt_register('POST','ProfitabilityandCashFlow');
        > pt_register('POST','PricingProcessandMarketingFunnel');
        > pt_register('POST','AvailabilityofCapital');
        > pt_register('POST','FulfilmentandDeliveryofProductsandServices');
        > pt_register('POST','SpeakingEngagements');
        > pt_register('POST','PresentationSkills');
        > pt_register('POST','ProductsandIntellectualProperty');
        > pt_register('POST','NewServicesandProducts');
        > pt_register('POST','ProductKnowledgeWithinCompany');
        > pt_register('POST','BudgetsandReportingProcesses');
        > pt_register('POST','TechnologyandCMS');
        > pt_register('POST','InternetPresence');
        > pt_register('POST','OngoingInternetMarketing');
        > pt_register('POST','QualityControlsandProcedures');
        > pt_register('POST','LegalAdviceandContracts');
        > pt_register('POST','AdministrationFunctions');
        > pt_register('POST','StrategicAlliances');
        > pt_register('POST','TeamworkandLeadership');
        > pt_register('POST','HiringProcessandManual');
        > pt_register('POST','EmployeeandConsltantRetention');
        > pt_register('POST','TrainingandCrossTraining');
        > pt_register('POST','BusinessandHealthInsurance');
        > pt_register('POST','OfficeOrganization');
        > pt_register('POST','ComputerOrganization');
        > pt_register('POST','PersonalOrganization');
        > pt_register('POST','YourProfessionalDevelopment');
        > pt_register('POST','YourPersonalDevelopment');
        > pt_register('POST','WorkandLifeFulfillmentandBalance');
        > pt_register('POST','SettingLifePrioritiesandGoals');
        > pt_register('POST','PersonalHealthandHavingFun');
        > if($FirstName=="" || $LastName=="" || $TelephoneNumber=="" ||
        > $BusinessEmailAddress=="" || $BusinessPlanandWrittenGoals=="" ||
        > $DailyTrackingSystem=="" || $BusinessPlanEffectiveness=="" ||
        > $AttractingIdealClients=="" || $ExitStrategy=="" ||
        > $MarketingPlanEffectiveness=="" || $MarketingSkills=="" ||
        > $LeadGenerationSalesSystem=="" || $LeadConversionClosing=="" ||
        > $BrandingIdentity=="" || $DistinctCompetitiveEdge=="" ||
        > $ExpertStatusinYourIndustry=="" || $ElevatorSpeechThatWorks=="" ||
        > $NetworkingandFollowupProcess=="" || $AdvertisingandPREfforts=="" ||
        > $CustomerRetentionandLoyalty=="" || $ProfitabilityandCashFlow=="" ||
        > $PricingProcessandMarketingFunnel=="" || $AvailabilityofCapital==""
        > || $FulfilmentandDeliveryofProductsandServices=="" ||
        > $SpeakingEngagements=="" || $PresentationSkills=="" ||
        > $ProductsandIntellectualProperty=="" || $NewServicesandProducts==""
        > || $ProductKnowledgeWithinCompany=="" ||
        > $BudgetsandReportingProcesses=="" || $TechnologyandCMS=="" ||
        > $InternetPresence=="" || $OngoingInternetMarketing=="" ||
        > $QualityControlsandProcedures=="" || $LegalAdviceandContracts=="" ||
        > $AdministrationFunctions=="" || $StrategicAlliances=="" ||
        > $TeamworkandLeadership=="" || $HiringProcessandManual=="" ||
        > $EmployeeandConsltantRetention=="" || $TrainingandCrossTraining==""
        > || $BusinessandHealthInsurance=="" || $OfficeOrganization=="" ||
        > $ComputerOrganization=="" || $PersonalOrganization=="" ||
        > $YourProfessionalDevelopment=="" || $YourPersonalDevelopment=="" ||
        > $WorkandLifeFulfillmentandBalance=="" ||
        > $SettingLifePrioritiesandGoals=="" ||
        > $PersonalHealthandHavingFun=="" ){
        > $errors=1;
        > $error.="<li>You did not enter one or more of the required fields.
        > Please go back and try again.";
        > }
        > if(!eregi("^[a-z0-9]+([_\\.-][a-z0-9]+)*" ."@"."([a-z0-9]+([\.-][a-z0-
        > 9]+)*)+"."\\.[a-z]{2,}"."$",$BusinessEmailAddress)){
        > $error.="<li>Invalid email address entered";
        > $errors=1;
        > }
        > if($errors==1) echo $error;
        > else{
        > $where_form_is="http".($HTTP_SERVER_VARS["HTTPS"]
        > =="on"?"s":"")."://".$SERVER_NAME.strrev(strstr(strrev
        > ($PHP_SELF),"/"));
        > $message="First Name: ".$FirstName."
        > Last Name: ".$LastName."
        > Company Name: ".$CompanyName."
        > Website URL: ".$WebsiteURL."
        > Telephone Number: ".$TelephoneNumber."
        > Business Email Address: ".$BusinessEmailAddress."
        > Business Plan and Written Goals: ".$BusinessPlanandWrittenGoals."
        > Daily Tracking System: ".$DailyTrackingSystem."
        > Business Plan Effectiveness: ".$BusinessPlanEffectiveness."
        > Attracting Ideal Clients: ".$AttractingIdealClients."
        > Exit Strategy: ".$ExitStrategy."
        > Marketing Plan Effectiveness: ".$MarketingPlanEffectiveness."
        > Marketing Skills: ".$MarketingSkills."
        > Lead Generation Sales System: ".$LeadGenerationSalesSystem."
        > Lead Conversion Closing: ".$LeadConversionClosing."
        > Branding Identity: ".$BrandingIdentity."
        > Distinct Competitive Edge : ".$DistinctCompetitiveEdge."
        > Expert Status in Your Industry: ".$ExpertStatusinYourIndustry."
        > Elevator Speech That Works: ".$ElevatorSpeechThatWorks."
        > Networking and Followup Process: ".$NetworkingandFollowupProcess."
        > Advertising and PR Efforts: ".$AdvertisingandPREfforts."
        > Customer Retention and Loyalty: ".$CustomerRetentionandLoyalty."
        > Profitability and Cash Flow: ".$ProfitabilityandCashFlow."
        > Pricing Process and Marketing
        > Funnel: ".$PricingProcessandMarketingFunnel."
        > Availability of Capital: ".$AvailabilityofCapital."
        > Fulfilment and Delivery of Products and
        > Services: ".$FulfilmentandDeliveryofProductsandServices."
        > Speaking Engagements: ".$SpeakingEngagements."
        > Presentation Skills: ".$PresentationSkills."
        > Products and Intellectual
        > Property: ".$ProductsandIntellectualProperty."
        > New Services and Products: ".$NewServicesandProducts."
        > Product Knowledge Within Company: ".$ProductKnowledgeWithinCompany."
        > Budgets and Reporting Processes : ".$BudgetsandReportingProcesses."
        > Technology and CMS: ".$TechnologyandCMS."
        > Internet Presence: ".$InternetPresence."
        > Ongoing Internet Marketing: ".$OngoingInternetMarketing."
        > Quality Controls and Procedures: ".$QualityControlsandProcedures."
        > Legal Advice and Contracts: ".$LegalAdviceandContracts."
        > Administration Functions: ".$AdministrationFunctions."
        > Strategic Alliances: ".$StrategicAlliances."
        > Teamwork and Leadership: ".$TeamworkandLeadership."
        > Hiring Process and Manual: ".$HiringProcessandManual."
        > Employee and Consltant Retention: ".$EmployeeandConsltantRetention."
        > Training and Cross Training: ".$TrainingandCrossTraining."
        > Business and Health Insurance: ".$BusinessandHealthInsurance."
        > Office Organization: ".$OfficeOrganization."
        > Computer Organization: ".$ComputerOrganization."
        > Personal Organization: ".$PersonalOrganization."
        > Your Professional Development: ".$YourProfessionalDevelopment."
        > Your Personal Development: ".$YourPersonalDevelopment."
        > Work and Life Fulfillment and
        > Balance: ".$WorkandLifeFulfillmentandBalance."
        > Setting Life Priorities and Goals : ".$SettingLifePrioritiesandGoals."
        > Personal Health and Having Fun: ".$PersonalHealthandHavingFun."
        > ";
        >
        >
        >
        > $message = stripslashes($message);
        > $message = preg_replace("/(content-
        > type|bcc:|cc:|onload|onclick)/i", '', $message);
        >
        > // Save data to file
        > $date = date('D, F jS Y \a\t H:i:s A');
        > $divider = str_repeat('-', 70);
        > $fp = fopen('data.dat', 'a');
        > $data = "Date: $date\r\n\r\n$message\r\n$divider\r\n";
        > fwrite($fp, $data);
        > fclose($fp);
        >
        > $headers = "From: $FirstName $LastName <$EmailAddress>\r\n";
        > $headers .= "Content-Type: text/plain\r\n";
        > $headers .= "Priority: Normal\r\n";
        > $headers .= "X-Mailer: PHP/" . phpversion();
        >
        > $headers = preg_replace("/(content-
        > type|bcc:|cc:|onload|onclick)/i", '', $headers);
        > @mail('123@...', 'Best Business Practice
        > Assessment Responses', $message, $headers);
        >
        > $headers = "From: Maria Marsala
        > <maria@...>\r\n";
        > $headers .= "Content-Type: text/plain\r\n";
        > $headers .= "Priority: Normal\r\n";
        > $headers .= "X-Mailer: PHP/" . phpversion();
        >
        > $headers = preg_replace("/(content-
        > type|bcc:|cc:|onload|onclick)/i", '', $headers);
        > @mail($EmailAddress, 'Best Business Practice Assessment', $message,
        > $headers);
        >
        >
        > // THANKYOU EMAIL MESSAGE
        > $thankyou = "Dear $FirstName
        >
        > There are six steps to take to start the process of building a better
        > business, substantially increasing your income and improving your
        > productivity so that you have more free time.
        >
        > You've just taken part of Step 1.
        >
        > I know you've heard the adage, that you have to know where you are,
        > then determine where you're going, in order to get there.
        >
        > The assesment you've taken, is part of 3 assessments I give my
        > clients to help them turbo charge their business. You can get the
        > other two assessments, one that measures if you're working with your
        > ideal client, and the
        > other assessment which allows you to see where you might be leaking
        > profits by joining my ezine. You can go here to do that
        > http://www.ElevatingYourBusiness.com/free/keepintouch.html
        >
        > What do you do next? I have limited availablity for 1:1 clients. To
        > receive your free consultation and determine if Elevating Your
        > Business can help you turn most areas of the form into 4's or 5's,
        > email our Senior Coach, Maria Marsala at
        > http://www.ElevatingYourBusiness.com/sitemap and you'll find the
        > right form for your situation.
        >
        > I look forward to the opportunity to talk to you about your
        > professional and personal goals.
        >
        >
        > Maria
        >
        > P.S. See what my clients are saying about my services. Visit
        > http://www.elevatingyourbusiness.com/success/
        > ";
        >
        >
        > $headers = "From: Maria Marsala <123@...>\r\n";
        > $headers .= "Content-Type: text/plain\r\n";
        > $headers .= "Priority: Normal\r\n";
        > $headers .= "X-Mailer: PHP/" . phpversion();
        >
        > $thankyou = preg_replace("/(content-
        > type|bcc:|cc:|onload|onclick)/i", '', $thankyou);
        > @mail($EmailAddress, 'Business Best Practices Assessment', $thankyou,
        > $headers);
        >
        > header("Refresh: 0; url=http://www.BusinessCoachPlus.com");
        > } // End else
        >
        > ?>
      Your message has been successfully submitted and would be delivered to recipients shortly.