Announcement

Collapse
No announcement yet.

phpFormGenerator -

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

  • phpFormGenerator -

    Ive gotten as far as installing and creating with phpFormGenerator. Now Im not finding how to incorporate that within my site. Its all there in BlueFTP and all, but after searching all morning I cant find any information on how to have it work within my forms page. All I want from it is to be able to have my customers upload a photo.
    Any help would be apreciated.
    kate

  • #2
    Re: phpFormGenerator -

    Usually phpFormGenerator forms are not embedded in BV, but used as independent pages. So just give your BV menu a link to the form page created with phpFG
    Navaldesign
    Logger Lite: Low Cost, Customizable, multifeatured Login script
    Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
    DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
    Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

    Comment


    • #3
      Re: phpFormGenerator -

      Thank you Navaldesign. Im very very inexperienced here. First off my page Im refering to is:
      http://www.kateart-cards.com/Apprais...st%20Form.html
      Second is that Id like to add an upload so as the customer may upload the photograph in need of repair so as I can give an appraisal cost. so I wouldnt need an elaborate setting for this only a simple..lol..<look at me using that word..something that they may do that.
      In BV there is insert/form/file upload...now thats simple enough...yet Im lost after that...right click properties "T1"?...maybe add to the html before tag?, insert some magic into the inside or after tag?..
      After installing the phpformgenerator, I have created the upload, yet have not clue to where the "form page" is..this is all very confusing to me. Ive been using my own scripts and reconstructing my own html, then today there was a huge DAH on my part that all that is offered right here..I know very DAH...guess Im a stubborn ole frenchmen..old dog/no tricks..or maybe just dense..haha..
      But if there was a way to just use the upload via BV, that would be really simple and awsome..
      thank you again,

      Comment


      • #4
        Re: phpFormGenerator -

        Creating the form is very simple: drag a Form area in your page, then start placing fields. T1 is the default name BV gives the text field: change it f.e. in "Name" or "email" or whatever the field is for. Add the titles of the fields as simple text. At the end, add an "Upload file" field for the photo to be uploaded. Of course you must add a "submit" button as well, and, if you want, a "Reset" button". Have a look at the tutorials: Form Tutorial 1, Form Tutorial 2

        Now, this is the easy part. The hard part is creating the php script that will actually do the submission and will also upload the file to your site.
        If you don't want to loose time, let me know when you will have your form ready and i will provide it to you. Otherwise, just search the forms forum: i have posted many scripts for uploading files.
        Navaldesign
        Logger Lite: Low Cost, Customizable, multifeatured Login script
        Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
        DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
        Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

        Comment


        • #5
          Re: phpFormGenerator -

          I do believe Im following you...At least reading it makes sense..I did find in the forum a script that you had provided but I will have to take a more indepth look/see at it as it didnt seem to go right, but Im sure its me, I work much better in the mornings when time isnt so crunched..thank you also for the tutorials - I had requested many searches and just couldnt find where the tutorials were..Its looking like Im going to have to stop hanging out in the lounge and get serious and do some reading and learning!
          Again you have been a great help!

          Comment


          • #6
            Re: phpFormGenerator -

            ok - done deal...very simiple using the tutorials...thanx again, Ill work on the scripts in the morning!

            Comment


            • #7
              Re: phpFormGenerator -

              ok - Im scriptless - but Ill keep looking.

              Comment


              • #8
                Re: phpFormGenerator -

                Well my search has come up nada. well not completely, I did find some that were so long I fell asleep reading them! I dont think I need that much script...maybe I do..
                Heres what Ive come up with so far -
                http://kateart-cards.com/test%20form.html

                I just threw it up there so as to give an idea of what my needs are - after scripting it and its in working order I can then add the bells n whistles..Right now its set up for email submittal. But as you can see its a very simple thing I need - not a huge gallery. only a one to five photo option for appraisal.

                Comment


                • #9
                  Re: phpFormGenerator -

                  Hi Kate, what are all those hidden fields you have in your form? What they serve for? Also, why did you put in there that "upload" button? You don't need it. The "Submit for appraisal" button will do all the work. Email and Telephone fields have to be named correctly, for now they are both named T1, which is the default name that BV gives them. Just get rid of hidden fields and the "Upload" button, , change the form action in "upload.php", and the encoding in "multipart/form data". Then i'll prepare the script for you.
                  Navaldesign
                  Logger Lite: Low Cost, Customizable, multifeatured Login script
                  Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
                  DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
                  Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

                  Comment


                  • #10
                    Re: phpFormGenerator -

                    All finished. hidden fields gone,upload gone, form action set as "upload.php" encoded at multipart/form data, T1 corrected. and published..
                    I do really appreciate this - Ive been looking all day for a way to make this work!

                    Comment


                    • #11
                      Re: phpFormGenerator -

                      Hi Kate,

                      here you go:

                      <?php
                      // Receiving variables
                      @$Browse_Name = $_FILES['Browse']['name'];
                      @$Browse_Size = $_FILES['Browse']['size'];
                      @$Browse_Temp = $_FILES['Browse']['tmp_name'];
                      @$Browse_Mime_Type = $_FILES['Browse']['type'];
                      @$NAME = addslashes($_POST['NAME']);
                      @$YOUR_TOWN_CITY = addslashes($_POST['YOUR_TOWN_CITY']);
                      @$STATE_AND_ZIP = addslashes($_POST['STATE_AND_ZIP']);
                      @$YOUR_EMAIL = addslashes($_POST['YOUR_EMAIL']);
                      @$Photograph_condition = addslashes($_POST['Photograph_condition']);
                      @$Details = addslashes($_POST['Details']);
                      @$TELEPHONE = addslashes($_POST['TELEPHONE']);
                      function RecursiveMkdir($path)
                      {
                      if (!file_exists($path))
                      {
                      RecursiveMkdir(dirname($path));
                      mkdir($path, 0777);
                      }
                      }

                      // Validation
                      if( $Browse_Size == 0)
                      {
                      header("Location: error_email.html");
                      exit;
                      }
                      if( $Browse_Size >1000000)
                      {
                      //delete file
                      unlink($Browse_Temp);
                      header("Location: error_email.html");
                      exit;
                      }
                      $uploadFile = "uploads/".$Browse_Name ;
                      if (!is_dir(dirname($uploadFile)))
                      {
                      @RecursiveMkdir(dirname($uploadFile));
                      }
                      else
                      {
                      @chmod(dirname($uploadFile), 0777);
                      }
                      @move_uploaded_file( $Browse_Temp , $uploadFile);
                      chmod($uploadFile, 0644);
                      $Browse_URL = "http://www.kateart-cards.com/uploads/".$Browse_Name ;
                      if (strlen($NAME) == 0 )
                      {
                      header("Location: name_errorpage.html");
                      exit;
                      }
                      if (! ereg('[A-Za-z0-9_-]+\@[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+', $YOUR_EMAIL))
                      {
                      header("Location: email_errorpage.html");
                      exit;
                      }
                      if (strlen($YOUR_EMAIL) == 0 )
                      {
                      header("Location: error_email.html");
                      exit;
                      }
                      if (strlen($TELEPHONE) == 0 )
                      {
                      header("Location: email_errorpage.html");
                      exit;
                      }
                      // Find Server date and Time
                      $date = date("l jS F Y, g:i A");
                      // Find Browser and IPaddress
                      $browser =$_SERVER['HTTP_USER_AGENT'];
                      $ip = $_SERVER['REMOTE_ADDR'];
                      //Sending Email to form owner
                      $pfw_header = "From: $YOUR_EMAIL\n"
                      . "Reply-To: $YOUR_EMAIL\n";
                      $pfw_subject = "NewPicture Uploaded";
                      $pfw_email_to = "your_email@kateart-cards.com ";
                      $pfw_message = "There is a new picture uploaded :\n"
                      . "-----------------------------------------------------\n"
                      . "NAME: $NAME\n"
                      . "EMAIL: $YOUR_EMAIL\n"
                      . "TOWN/CITY: $YOUR_TOWN/CITY\n"
                      . "STATE_AND_ZIP: $STATE_AND_ZIP\n"
                      . "TELEPHONE: $TELEPHONE\n"
                      . "----------------------------------------------------\n"
                      . "\n"
                      . "Photograph_condition: $Photograph_condition\n"
                      . "Details: $Details\n"
                      . "----------------------------------------------------\n"
                      . "Picture link: : $Browse_URL\n"
                      . "----------------------------------------------------"
                      . "----------------------------------------------------\n"
                      . "Received on : $date\n"
                      . "Browser : $browser\n"
                      . "IP address : $ip\n"
                      . "----------------------------------------------------\n";
                      *****($pfw_email_to, $pfw_subject ,$pfw_message ,$pfw_header ) ;
                      header("Location: thankyou_page.html");
                      ?>


                      Please follow these instructions:

                      1. Copy the code, paste it in notepad, then goto Save As, choose File Type All Files, and save the script as "upload.php". Upload it on your server in the public_html folder, using Blue FTP
                      2. While you are in your public_html, click somewhere on the right part of your screen. Then click on File > New Folder and in the popup that opens type "uploads" This way you will create a new folder, called "uploads" and that's where the uploaded pictures will end.
                      3. Browse the content of your site. Find the new folder, "uploads". It will probably be at bottom. Right Click on it , Properties, and you will see a number like 755 . Change it to 777.
                      4. I have inserted field validation for

                      a. Empty Name field.
                      b. Empty email field
                      c. Non truelike email

                      I have also inserted a thankyou page. So please create these three pages: "name_errorpage", "email_errorpage", "thankyou_page".

                      To get an idea of how these pages must be, have a look at :
                      http://www.navaldesign.info/error_email.html

                      http://www.navaldesign.info/error_empty_field.html

                      http://www.navaldesign.info/thankyou_page.html


                      Save and publish these pages, then test your form.

                      Please note that in your email you will receive a link like:

                      Picture Link: http://www.kateart-cards.com/uploads/filename.jpg

                      By clicking on the file, the picture will open on your browser, then you can sipmly rig***lick it to save it on your computer.

                      If the file name is more than one words, the file link will look like:

                      http://www.kateart-cards/uploads/file name.jpg

                      Of course, you must put your Vodahost account email in the script.

                      Good luck. let me know if you have problems.

                      As you see, in this case the link will not work, so you have to download it from your site using blueFTP.
                      Last edited by navaldesign; 05-01-2006, 04:35 PM.
                      Navaldesign
                      Logger Lite: Low Cost, Customizable, multifeatured Login script
                      Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
                      DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
                      Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

                      Comment


                      • #12
                        Re: phpFormGenerator -

                        I dont know how to thank you Navel. This is just so nice of you to help so much. I wont have time today to work on it but I will however get right on it sunday morning! - I could restore a photo for you in "return" if you would like me to?!...
                        again, thank you!

                        Comment


                        • #13
                          Re: phpFormGenerator -

                          No worriws kate, thanks a lot
                          Navaldesign
                          Logger Lite: Low Cost, Customizable, multifeatured Login script
                          Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
                          DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
                          Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

                          Comment


                          • #14
                            Re: phpFormGenerator -

                            Im busy working on your instructions! Ive gotten the three pages finished and published! now on to the less creative side...lol..

                            Comment


                            • #15
                              Re: phpFormGenerator -

                              "upload.php" is on server, CHMOD set "777" on folder "uploads" All publishing done -
                              One thing is that I want my email to be : kassi1959****.com and not my vh email...I changed that in the script/did I do a booboo?
                              I received this error after submitting for appraisal.
                              Parse error: parse error, unexpected '=' in /home/kateart/public_html/upload.php on line 8

                              Comment

                              Working...
                              X