Advertisement:

Author Topic: Add file in registration form  (Read 963 times)

Marcin

  • Newbie
  • *
  • Posts: 13
Add file in registration form
« on: January 31, 2016, 05:09:11 pm »
Hello,

does anyone know how to make add file in registration form and make it required?

Thanks for any reply.

Marcin

Marcin

  • Newbie
  • *
  • Posts: 13
Re: Add file in registration form
« Reply #1 on: January 31, 2016, 11:03:58 pm »
I tried to make it with Required Fields at Registration but it doesn't work.

I modified form.php code
<!--<?php UserForm::location_javascript(); ?>-->

<label for="user_type"><?php _e('Typ działalności', 'modern') ; ?></label>
<?php UserForm::is_company_select() ; ?>
<br />

<label for="Telefon komórkowy"><?php _e('Telefon komórkowy', 'modern') ; ?></label>
<?php UserForm::mobile_text() ; ?>
<br />

<!--<label for="phoneLand"><?php _e('Phone', 'modern') ; ?></label>
<?php UserForm::phone_land_text() ; ?>
<br />-->

<!--<label for="country"><?php _e('Country', 'modern') ; ?> *</label>
<?php UserForm::country_select(osc_get_countries()) ; ?>
<br />-->

<!--<label for="region"><?php _e('Region', 'modern') ; ?> *</label>
<?php UserForm::region_select(array()) ; ?>
<br />-->

<!--<label for="city"><?php _e('City', 'modern') ; ?> *</label>
<?php UserForm::city_select(array()) ; ?>
<br />-->

<!--<label for="city_area"><?php _e('City area', 'modern') ; ?></label>
<?php UserForm::city_area_text() ; ?>
<br />-->

<!--<label for="address"><?php _e('Address', 'modern') ; ?></label>
<?php UserForm::address_text() ; ?>
<br />-->

<label for="NIP"><?php _e('NIP', 'modern') ; ?></label>
<?php UserForm::website_text() ; ?>
<br />

<label for="user_type"><?php _e('Dokumenty rejestrowe', 'modern') ; ?></label>
<?php UserForm::dokumenty_uploaded_file() ; ?>
<br />

and footer.php code:

script>
    $(document).ready(function(){
        $("#s_phone_mobile").rules("add", {required: true, messages: { required: "Mobile phone is required" }});
        /*$("#s_phone_land").rules("add", {required: true, messages: { required: "Land phone is required" }});*/
        /*$("#countryId").rules("add", {required: true, messages: { required: "Country is required" }});*/
        /*$("#region").rules("add", {required: true, messages: { required: "Region is required" }});*/
        /*$("#city").rules("add", {required: true, messages: { required: "City is required" }});*/
        /*$("#cityArea").rules("add", {required: true, messages: { required: "City area is required" }});*/
        $("#s_website").rules("add", {required: true, messages: { required: "NIP is required" }});*/
   /*$("#dokumenty").rules.("add", {required: true, messages: { required: "Dokumenty" }});*/
    });
</Script>

Thanks for reply.