Home News Contact Us Forum About Us Demos Products F.A.Q.
Shopping Cart
You currently have 0 items in your cart.


Recent Events
  • 31/12/2023 New Year SALE

    We are glad to announce New Year SALE. 25% discount for all our extensions. Use NY24 coupon code. Hurry up the discount is valid till 7 January.

  • 21/11/2023 BLACK FRIDAY 23 is coming

    BIG SALE, 35% discount for all our extensions. Use BF23 coupon code. Hurry up the discount is valid till 27 November.


2Checkout.com, Inc. is an authorized retailer of goods and services provided by ARI Soft. 2CheckOut




Follow us on twitter



Welcome, Guest
Please Login or Register.    Lost Password?

Fields example
(1 viewing) (1) Guest
"ARI Stream Quiz" WordPress plugin
Go to bottomPage: 12
TOPIC: Fields example
#64964
Fields example 4 Years, 11 Months ago Karma: 0
Could you help me put 3 more fields in the form to capture leads?

I saw in another post that it is necessary to edit these files:


Hello,

It requires to modify the following files:

- <wordpress_plugins>/ari-stream-quiz/includes/views/quiz-session/tmpl/default.php (see quiz-user-data section)

- <wordpress_plugins>/ari-stream-quiz/includes/entities/class-quiz-result.php (see extend_bind method)

Regards,
AIR soft
admin




But could you help me? I do not know much about php.

Tks

Danilo
The administrator has disabled public write access.
 
#64968
Re:Fields example 4 Years, 11 Months ago Karma: 0
Please, how can I do this?

Tks
The administrator has disabled public write access.
 
#64970
Re:Fields example 4 Years, 11 Months ago Karma: 747
Open <wordpress_plugins>/ari-stream-quiz/includes/views/quiz-session/tmpl/default.php template file and find the following code:

Code:


<div class="quiz-user-data-content quiz-user-data-content-after data-row">
                <?php echo $quiz->quiz_meta->content->after_lead_form; ?>
            </div>



Add before it the following code:

Code:


<div class="data-row">
                <label for="<?php echo $prefix . '_userdata_field1'; ?>">Field 1 :</label>
                <input type="text" id="<?php echo $prefix . '_userdata_field1'; ?>" data-key="field1" autocomplete="off" placeholder="Enter some data" />
            </div>
            <div class="data-row">
                <label for="<?php echo $prefix . '_userdata_field2'; ?>">Field 2 :</label>
                <input type="text" id="<?php echo $prefix . '_userdata_field2'; ?>" data-key="field2" autocomplete="off" placeholder="Enter some data" />
            </div>
            <div class="data-row">
                <label for="<?php echo $prefix . '_userdata_field3'; ?>">Field 3 :</label>
                <input type="text" id="<?php echo $prefix . '_userdata_field3'; ?>" data-key="field3" autocomplete="off" placeholder="Enter some data" />
            </div>



It adds "Field 1", "Field 2" and "Field 3" fields to the form. The data will be stored in #_asq_results DB table. It requires extra PHP code if you want to show these data on some page/report.

Regards,
ARI Soft
The administrator has disabled public write access.
 
#64985
Re:Fields example 4 Years, 11 Months ago Karma: 0
Hi!!

Thanks for the feedback!

But it not load the new fields on the page...

Is there another file to change something?

Tks

Danilo
The administrator has disabled public write access.
 
#64989
Re:Fields example :-) 4 Years, 11 Months ago Karma: 0
Hello

Thanks for the feedback...
I was able to insert the fields and worked, in the way you explained earlier.

Just one detail: How do I leave these new fields mandatory?

Thank you very much.

Danilo
The administrator has disabled public write access.
 
#65009
Re:Fields example :-) 4 Years, 11 Months ago Karma: 747
We will add ability to mark custom fields as required in the future release.

Regards,
ARI Soft
The administrator has disabled public write access.
 
Go to topPage: 12