0

我有一个包含 124 个字段的 html 表单,其中一些字段是必需的,而其他字段可以省略。将所有填写的字段输入数据库的最佳方法是什么?

我已经尝试制作一个 MySQL 表,其中所有字段都将可以省略的字段设置为 NULL,但是当我单击表单上的提交时它不会输入任何值。

这是html表单:

<table border="1">
<tr>
<td>
    <form name="createcomp" method="post" action="createform.php">
    <table class="table table-striped" border="0">
      <tr>
        <td>
          <select name="regtype" class="input-xxlarge" required="">
            <option selected value="">
              Please select registration type
            </option>
            <option value="form1a">
              Articles of Incorporation Company Limited by Shares (Form
              1A)
            </option>
            <option value="form1a">
              Articles of Incorporation Company Limited by Guarantee
              Without a Share Capital (Form 1B)
            </option>
            <option value="form1a">
              Articles of Incorporation Company Limited by Guarantee
              With a Share Capital (Form 1C)
            </option>
            <option value="form1a">
              Articles of Incorporation Unlimited Company (Form 1D)
            </option>
            <option value="form1a">
              Registration of Business Names - Registration by Sole
              Proprietor (FORM BN1)
            </option>
            <option value="form1a">
              Registration of Business Names - Registration by
              Partneship (FORM BN2)
            </option>
            <option value="form1a">
              Registration of Business Names - Registration by
              Corporation (FORM BN3)
            </option>
          </select>
        </td>
      </tr>
    </table>
    <table class="table table-striped">
      <tr>
        <td>
          <input class="input-xlarge" type="text" name="compname"
          required="" placeholder="1. NAME OF COMPANY">
        </td>
        <td></td>
        <td>
          <div id="available"></div>
        </td>
      </tr>
      <tr>
        <td>
          <input class="input-xxlarge" type="tel" name="faxnum"
          placeholder="1A. COMPANY FAX NUMBER (XXX) XXX-XXXX" required=
          "">
        </td>
        <td>
          <label class="control-label">1B. TYPE OF COMPANY</label>
        </td>
        <td>
          <label class="radio inline"><input type="radio" name=
          "comptype" id="inlinePub" value="public" required="">
          PUBLIC</label> <label class="radio inline"><input type=
          "radio" name="comptype" id="inlinePriv" value="private"
          required=""> PRIVATE</label>
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">2. IS THE REGISTERED OFFICE IS
          SITUATED JAMAICA?</label>
        </td>
        <td>
          <label class="radio inline"><input type="radio" name=
          "injamaica" id="inlineYes" value="yes" required="">
          YES</label> <label class="radio inline"><input type="radio"
          name="injamaica" id="inlineNo" value="no" required="">
          NO</label>
        </td>
      </tr>
    </table><br>
    <table class=" table table-striped" border="0">
      <tr>
        <td>
          <label class="control-label">3. CORE BUSINESS OF THE
          COMPANY</label>
        </td>
        <td>
          <input type="text" name="coredescrip" placeholder=""
          required="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">4. THE CLASSES OF SHARES, IF ANY
          THAT THE COMPANY IS AUTHORIZED TO ISSUE</label>
        </td>
        <td>
          <input type="text" name="classshare" placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">4A. THE MAXIMUM NUMBER OF
          SHARES, IF ANY THAT THE COMPANY IS AUTHORIZED TO
          ISSUE</label>
        </td>
        <td>
          <input type="text" name="maxshares" placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">5. RESTRICTIONS,IF ANY, ON SHARE
          TRANSFERS</label>
        </td>
        <td>
          <input type="text" name="resshares" placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">6. MINIMUM NUMBER OF
          DIRECTORS</label>
        </td>
        <td>
          <input type="text" name="mindirectors" placeholder=""
          required="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">6A. MAXIMUM NUMBER OF
          DIRECTORS</label>
        </td>
        <td>
          <input type="text" name="maxdirectors" placeholder=""
          required="">
        </td>
      </tr>
    </table>
    <table class=" table table-striped" border="0">
      <tr>
        <td>
          <label class="control-label">6B. NAMES OF FIRST
          DIRECTORS</label>
        </td>
        <td>
          <label class="control-label">NAME(S)</label>
        </td>
        <td>
          <label class="control-label">RESIDENTIAL ADDRESS</label>
        </td>
        <td>
          <label class="control-label">OCCUPATION</label>
        </td>
        <td>
          <label class="control-label">CONTACT #</label>
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="dirname1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diraddress1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diroccu1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="dircontact1"
          placeholder="(XXX)XXX-XXXX" required="">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="dirname2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diraddress2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diroccu2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="dircontact2"
          placeholder="(XXX)XXX-XXXX">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="dirname3"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diraddress3"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diroccu3"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="dircontact3"
          placeholder="(XXX)XXX-XXXX">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="dirname4"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diraddress4"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diroccu4"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="dircontact4"
          placeholder="(XXX)XXX-XXXX">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="dirname5"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diraddress5"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="diroccu5"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="dircontact5"
          placeholder="(XXX)XXX-XXXX">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">6C.NAME OF 1ST COMPANY
          SECRETARY</label>
        </td>
        <td>
          <label class="control-label">NAME(S)</label>
        </td>
        <td>
          <label class="control-label">RESIDENTIAL ADDRESS</label>
        </td>
        <td>
          <label class="control-label">OCCUPATION</label>
        </td>
        <td>
          <label class="control-label">CONTACT #</label>
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="secname"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="secaddress"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="seecoccu"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="seccontact"
          placeholder="(XXX)XXX-XXXX" required="">
        </td>
      </tr>
    </table>
    <table class=" table table-striped" border="0">
      <tr>
        <td>
          <label class="control-label">7. RESTRICTIONS, IF ANY, ON THE
          BUSINESS THE COMPANY MAY CARRY ON</label>
        </td>
        <td>
          <input class="input-xlarge" type="text" name="busrestricts"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">7A. JUSTIFICATION OF PROPOSED
          NAME, WHERE APPLICABLE</label>
        </td>
        <td>
          <input class="input-xlarge" type="text" name="namejustify"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">8. THE FOLLOWING ARTICLES FROM
          TABLE A SHALL APPLY WITHOUT VARIATION</label>
        </td>
        <td>
          <div id="myModal" class="modal hide fade" tabindex="-1" role=
          "dialog" aria-labelledby="myModalLabel" aria-hidden="true">
            <div class="modal-header">
              <button type="button" class="close" data-dismiss="modal"
              aria-hidden="true">×</button>
              <h4 id="myModalLabel">
                TABLE A - Articles Relevant to Questions 8 and 8A.
              </h4>
            </div>
            <div class="modal-body">
              <h5>
                SCHEDULE I
              </h5>
              <h6>
                Article 85
              </h6>
              <p>
                “The Directors may exercise all the power of the
                Company to borrow money, and to mortgage or charge its
                undertaking, property and uncalled capital, or any part
                thereof, and to issue debentures, debenture stock, and
                other securities whether outright or as security for
                any debt, liability or obligation of the Company or of
                any third party.”
              </p>
              <h5>
                SCHEDULE II
              </h5>
              <h6>
                Article 143
              </h6>
              <p>
                ‘Subject to the provisions of sections 56, 57 and 58 of
                the Act, a Company may issue shares which by the terms
                of the issue will be redeemed or at the option of the
                Company, may be redeemed.’
              </p>
              <h6>
                Article 144
              </h6>
              <p>
                ‘Subject to the provisions of section 58 of the Act, a
                Company may purchase or otherwise acquire shares issued
                by it.’
              </p>
              <h6>
                Article 145
              </h6>
              <p>
                ‘Subject to section 59 of the Act, the Company may
                acquire its own shares of any class to:
              </p>(a) settle or compromise a debt or claim asserted by
              or against the Company
              <p>
                (b) eliminate fractional shares
              </p>
              <p>
                (c) fulfill the terms of non-assignable agreement under
                which the Company has an option or is obliged to
                purchase shares owned by an officer or an employee of
                the Company.’
              </p>
              <h6>
                Article 146
              </h6>
              <p>
                'No share or class of shares may be issued unless the
                shares have first been offered to the shareholders of
                the Company holding shares of that class.’
              </p>
              <h6>
                Article 147
              </h6>
              <p>
                ‘Subject to section 71 of the Act, the Company may by
                special resolution:
              </p>
              <p>
                (a) extinguish or reduce a liability in respect of an
                amount unpaid on any shares;
              </p>
              <p>
                (b) reduce its stated capital by an amount that is not
                represented by realizable assets; or
              </p>
              <p>
                (c) return to its shareholders any of its assets which
                are in excess of the wants of the Company.’
              </p>
              <h6>
                Article 148
              </h6>
              <p>
                ‘Subject to section 184 of the Act, the Company may
                give financial assistance by means of a loan, guarantee
                or otherwise:
              </p>
              <p>
                (a) to a shareholder, director, officer or employee of
                the Company or affiliated company, or to an associate
                of any such person for any purpose; or
              </p>
              <p>
                (b) to any person for the purpose of, or in connection
                with, a purchase of a share issued or to be issued by
                the Company or a company with which it is affiliated.’
              </p>
              <h6>
                Article 149
              </h6>
              <p>
                ‘Subject to section 201 of the Act, the Company may
                pursuant to section 201 indemnify:
              </p>
              <p>
                (a) a director or officer of the Company or any person
                employed by the Company as an auditor;
              </p>(b) a former director, officer or auditor of the
              Company; or (c) a person who acts or has acted at the
              Company’s request as a director or officer of a body
              corporate of which the Company is or was a shareholder or
              creditor, and his legal representatives, against all
              costs, charges and expenses reasonably incurred by him in
              respect of any civil, criminal or administrative action
              or proceeding to which he is made a party by reason of
              being, or having been, a director or officer of that
              company or body corporate, or any person employed by a
              company or body corporate or an auditor.’
            </div>
            <div class="modal-footer"></div>
          </div><a data-toggle="modal" data-target="#myModal" class=
          "btn" role="button">ARTICLES 7-84 and 86-142 SHALL APPLY</a>
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">8. THE FOLLOWING ARTICLES FROM
          TABLE A SHALL APPLY WITHOUT VARIATION</label>
        </td>
        <td>
          <a data-toggle="modal" data-target="#myModal" class="btn"
          role="button">SEE SCHEDULE 1 for varied artcles 85 and
          schedule 2 for articles 143-149  ATTACHED</a>
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">9. HAS THERE BEEN AN ALLOTMENT
          OF SHARES FOR CONSIDERATION OTHER THAN CASH PURSUANT TO A
          PREINCORPORATION CONTRACT?</label>
        </td>
        <td>
          <label class="radio inline"><input type="radio" name=
          "allotshares" id="inlineYes" value="yes" required="">
          YES</label> <label class="radio inline"><input type="radio"
          name="allotshares" id="inlineNo" value="no" required="">
          NO</label>
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">9A. THE NATURE AND VALUE OF THIS
          CONSIDERATION IS SET OUT BELOW:</label>
        </td>
        <td>
          <input class="input-xlarge" type="text" name="nature"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td></td>
      </tr>
      <tr>
        <td>
          <label class="control-label">10. LIABILITY OF THE MEMBERS IS
          LIMITED</label>
        </td>
      </tr>
      <tr>
        <td></td>
      </tr>
      <tr>
        <td>
          <label class="control-label">11. SUBSCRIBERS AND WITNESSES
          (Where a company is subscriber, two officers must sign on
          behalf of the company. See attached schedule III.)</label>
        </td>
      </tr>
    </table>
    <table class=" table table-striped">
      <tr>
        <td></td>
        <td>
          <label class="control-label">SUBSCRIBE 1</label>
        </td>
        <td>
          <label class="control-label">SUBSCRIBE 2</label>
        </td>
        <td>
          <label class="control-label">SUBSCRIBE 3</label>
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">PRINT NAME</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="susname1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susname2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susname3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">ADDRESS 1</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="susaddr1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susaddr2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susaddr3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">ADDRESS 2</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="susaddr21"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susaddr22"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susaddr23"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">OCCUPATION</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="susoccu1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susoccu2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susoccu3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label"># OF SHARES TAKEN</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="susshare1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susshare2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="susshare3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">CONTACT #</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="suscontact1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="suscontact2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="suscontact3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">DATE</label>
        </td>
        <td>
          <input class="input-medium" type="date" name="susdate1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="date" name="susdate2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="date" name="susdate3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <label class="control-label">WITNESS 1</label>
        </td>
        <td>
          <label class="control-label">WITNESS 2</label>
        </td>
        <td>
          <label class="control-label">WITNESS 3</label>
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">PRINT NAME</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="witname1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witname2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witname3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">ADDRESS 1</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="witaddr1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witaddr2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witaddr3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">ADDRESS 2</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="witaddr21"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witaddr22"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witaddr23"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">OCCUPATION</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="witoccu1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witoccu2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witoccu3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">CONTACT #</label>
        </td>
        <td>
          <input class="input-medium" type="text" name="witcontact1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witcontact2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="witcontact3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">DATE</label>
        </td>
        <td>
          <input class="input-medium" type="date" name="witdate1"
          placeholder="" required="">
        </td>
        <td>
          <input class="input-medium" type="date" name="witdate2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="date" name="witdate3"
          placeholder="">
        </td>
      </tr>
    </table>
    <table class=" table table-striped">
      <tr>
        <td>
          <label class="control-label">13.PARTICULARS OF
          DIRECTORS</label>
        </td>
        <td>
          <label class="control-label">NAME OF DIRECTORS</label>
        </td>
        <td>
          <label class="control-label">EMAIL ADDRESS</label>
        </td>
        <td>
          <label class="control-label">TRN NUMBER</label>
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="pdirname1"
          required="">
        </td>
        <td>
          <input class="input-medium" type="email" name="pdiremail1"
          required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="pditrn1"
          required="">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="pdirname2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="email" name="pdiremail2"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="pditrn2"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="pdirname3"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="email" name="pdiremail3"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="pditrn3"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="pdirname4"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="email" name="pdiremail4"
          placeholder="">
        </td>
        <td>
          <input class="input-medium" type="text" name="pditrn4"
          placeholder="">
        </td>
      </tr>
      <tr>
        <td>
          <label class="control-label">13.PARTICULARS OF
          SECRETARY</label>
        </td>
        <td>
          <label class="control-label">NAME OF SECRETARY</label>
        </td>
        <td>
          <label class="control-label">EMAIL ADDRESS</label>
        </td>
        <td>
          <label class="control-label">TRN NUMBER</label>
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="psecname"
          required="">
        </td>
        <td>
          <input class="input-medium" type="email" name="psecemail"
          required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="psectrn"
          required="">
        </td>
      </tr>
      <tr>
        <td></td>
      </tr>
    </table>
    <table class=" table table-striped">
      <tr>
        <td>
          <label class="control-label">12. THIS FORM WAS COMPLETED
          BY?</label>
        </td>
        <td>
          <label class="control-label">PRINT NAME</label>
        </td>
        <td>
          <label class="control-label">DATE</label>
        </td>
        <td>
          <label class="control-label">TRN NUMBER</label>
        </td>
        <td>
          <label class="control-label">EMAIL ADDRESS</label>
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input class="input-medium" type="text" name="creatrname"
          required="">
        </td>
        <td>
          <input class="input-medium" type="date" name="creatrdate"
          required="">
        </td>
        <td>
          <input class="input-medium" type="text" name="creatrtrn"
          required="">
        </td>
        <td>
          <input class="input-medium" type="email" name="creatremail"
          required="">
        </td>
      </tr>
      <tr>
        <td></td>
        <td>
          <input type="hidden" name="user_id" value=
          "<?php echo $userid;?>">
        </td>
        <td>
          <input type="submit" name="Submit" value="Register" class=
          "btn-large">
        </td>
        <td></td>
        <td></td>
      </tr>
    </table>
  </form>
</td>
</tr>
</table>
4

0 回答 0