Home › Forums › Quform WordPress › Version 2 so many issues and incompatible on migrate
- This topic has 31 replies, 2 voices, and was last updated 6 years, 7 months ago by Ally.
- AuthorPosts
- September 11, 2017 at 11:31 am #21842patdundeeParticipant
One more
Form redirectI have the following function which you as yet do not have listed on the help section
mytheme_modify_form_redirect($url, $form) This works fine in 1.1
but you do show something similar
function my_success_redirect_url($url, $form)
Are these one in the same? If so do i change my code to
function my_success_redirect_url($url, Quform_Confirmation $confirmation, Quform_Form $form)
Thanks
patrick
- This reply was modified 6 years, 7 months ago by patdundee.
September 11, 2017 at 3:35 pm #21846patdundeeParticipantHi Ally
Appreciate you are very busy. Any update on these two questions please?1)
Going through my custom coding and starting to do changes on a copy of functionsOn there i have custom hidden fields.eg: my_set_hidden_price
I notice there are no changes to this particular function name in your new guide so i am thinking the only change would befrom
iphorm_element_value_priceto
quform_element_value_priceAm i correct with this one?
2)
Form redirectI have the following function which you as yet do not have listed on the help section
mytheme_modify_form_redirect($url, $form) This works fine in 1.1
but you do show something similar
function my_success_redirect_url($url, $form)
Are these one in the same? If so do i change my code to
function my_success_redirect_url($url, Quform_Confirmation $confirmation, Quform_Form $form)
Thanks
patrick
- This reply was modified 6 years, 7 months ago by patdundee. Reason: I cannot spell :)
September 11, 2017 at 5:40 pm #21851AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
September 11, 2017 at 7:31 pm #21852patdundeeParticipantHi Ally Forget this post/question I just re-read your post. Will let you know if i get stuck
🙂
Thanks for that. Just to confirm I have a few form redirects 4 in total I beleive
on the add action it is currently
On the function i have the following
function mytheme_modify_form_redirect2($url, $form)
(number 2 at end of redirect relates to the form this is for)
which i beleive should now look lime this
function my_success_redirect_url2($url, Quform_Confirmation $confirmation, Quform_Form $form) {
On the add action currently set to
add_action('quform_success_redirect_url_2', 'mytheme_modify_form_redirect2', 10, 2);
Again notice the number 2 at the end of url and redirect
How would this be set in the new add action in the below example provided ?
add_action('quform_confirmation_redirect_url_1_1', 'my_success_redirect_url', 10, 3);
Many thanks
PatrickSeptember 11, 2017 at 10:09 pm #21862patdundeeParticipantHi Ally
I have activated and imported the forms and am working on Form 1 at the moment I have also adjusted the code on that page to load the new form
If you log back into the admin section and view form 1 (Contact and reservations)
Conditional logic is working in preview but columns is not working
If you then go to the website to the contact page (Select contact from the menu, you will see neither conditional logic works or columns.
The first item is an element where you can set the style to inline, but you cannot set this on any other element inside a group or column, nor can you set it direct from the group
I am on the site at the moment. Please advise
Many thanks
PatrickSeptember 11, 2017 at 10:33 pm #21864AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
September 11, 2017 at 10:46 pm #21866patdundeeParticipantHi Ally
Many thanks
WP Super was already urned off 🙂 Disabling the combine options solved the issue.
That was the easy one lol now i have to ry the othersP 🙂
September 11, 2017 at 10:53 pm #21867AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
September 11, 2017 at 10:57 pm #21868patdundeeParticipantThanks for your help. Greatly appreciated. Just to let you know. Conditional logig has to be set on the page setting sfor each form and on some items you have to redo the logic. No great problem that one though.
P
September 11, 2017 at 11:14 pm #21869AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
September 11, 2017 at 11:24 pm #21870patdundeeParticipantWhen a form is submitted and saved to the database and you go to the forms and select view submitted form, it does not show any details. You have to select edit form to view the submitted info. With that no links to images work either
🙂
P
September 12, 2017 at 2:15 am #21871patdundeeParticipantMorning Ally
It was all going great and thenNone of the values are being collected from the submitted form. All the settings below for collecting the data from the form work in version 1.10
The first and last lines are the old redirect statements and are remmed out. The only thing i can think of is if there is a different way for the getValue that i do not know about.
//function mytheme_modify_form_redirect4($url, $form)
function my_success_redirect_url3($url, Quform_Confirmation $confirmation, Quform_Form $form)
Date = $form->getValue('quform_3_6');
$Time = $form->getValue('quform_3_10');
$AL = $form->getValue('quform_3_12');
$CT = $form->getValue('quform_3_13');
$wp_session = WP_Session::get_instance();
if ($Date['day']<10) { $myDate1='0'.$Date['day']; } else { $myDate1=$Date['day'];}
if ($Date['month']<10) { $myDate2='0'.$Date['month']; } else { $myDate2=$Date['month'];}
$wp_session['price'] = $form->getValue('quform_3_72');
$wp_session['sku'] = $form->getValue('quform_3_73');
$wp_session['qty'] = $form->getValue('quform_3_74');
$wp_session['qty1']=NULL;
$wp_session['cType'] = $form->getValue('quform_3_75');
$wp_session['desc'] = 'Recipient- '. $form->getValue('quform_3_4').'<br>Guests- '.$form->getValue('quform_3_5').'<br>Date- '.$myDate1.'-'.$myDate2.'-'.$Date['year'].'<br>Time- '.$Time['hour'].'-'.$Time['minute'].'-'.$Time['ampm'].'<br>Flavours- If not shown below then to be notified<br>Any alergens- '.$AL['0'].' '.$AL['1'].' '.$AL['2'].' '.$AL['3'].' '.$AL['4'].'<br>Specific cake type- '.$CT['0'].' '.$CT['1'].' '.$CT['2'].' '.$CT['3'].' '.$CT['4'].'<br>Other information- '.$form->getValue('quform_3_18');
$wp_session['strBillingFirstnames'] = $form->getValue('quform_3_32');
$wp_session['strBillingSurname'] = $form->getValue('quform_3_33');
$wp_session['KRef']=substr($wp_session['strBillingFirstnames'],0,1).substr($wp_session['strBillingSurname'],0,1).$myDate1.$myDate2.substr($Date['year'],2,2);
$wp_session['strBillingAddress1'] = $form->getValue('quform_3_34');
$wp_session['strBillingAddress2'] = $form->getValue('quform_3_35');
$wp_session['strBillingCity'] = $form->getValue('quform_3_36');
$wp_session['strBillingPostCode'] = $form->getValue('quform_3_37');
$wp_session['strBillingCountry'] = $form->getValue('quform_3_38');
$wp_session['strBillingState']='';
$wp_session['strBillingPhone'] = $form->getValue('quform_3_41');
$wp_session['strBillingEMail'] = $form->getValue('quform_3_42');
$wp_session['bIsDeliverySame'] = $form->getValue('quform_3_43');
$wp_session['dc'] = $form-> getValue('quform_4_77');
if ($wp_session['dc']==2) {
$wp_session['strDeliveryFirstnames'] = 'Kimbos';
$wp_session['strDeliverySurname'] = 'Cakes';
$wp_session['strDeliveryAddress1'] = '152 Ladywood Road';
$wp_session['strDeliveryAddress2'] = 'Kirk Hallam';
$wp_session['strDeliveryCity'] = 'Derbyshire';
$wp_session['strDeliveryPostCode'] = 'DE7 4NS';
$wp_session['strDeliveryCountry'] = 'GB';
$wp_session['strDeliveryState']='';
$wp_session['strDeliveryPhone'] = '01158 24 00 44';
} else {
if ($wp_session['bIsDeliverySame']==1) {
$wp_session['strDeliveryFirstnames'] = $form->getValue('quform_4_32');
$wp_session['strDeliverySurname'] = $form->getValue('quform_3_33');
$wp_session['strDeliveryAddress1'] = $form->getValue('quform_3_34');
$wp_session['strDeliveryAddress2'] = $form->getValue('quform_3_35');
$wp_session['strDeliveryCity'] = $form->getValue('quform_3_36');
$wp_session['strDeliveryPostCode'] = $form->getValue('quform_3_37');
$wp_session['strDeliveryCountry'] = $form->getValue('quform_3_38');
$wp_session['strDeliveryState']='';
$wp_session['strDeliveryPhone'] = $form->getValue('quform_3_41');
} else {
$DelVenue = $form->getValue('quform_3_47');
if ($DelVenue==1) {
$wp_session['strDeliveryFirstnames'] = $form->getValue('quform_3_50');
$wp_session['strDeliverySurname'] = '*';
$wp_session['strDeliveryAddress1'] = $form->getValue('quform_3_51');
$wp_session['strDeliveryAddress2'] = $form->getValue('quform_3_52');
$wp_session['strDeliveryCity'] = $form->getValue('quform_3_53');
$wp_session['strDeliveryPostCode'] = $form->getValue('quform_3_54');
$wp_session['strDeliveryCountry'] = $form->getValue('quform_3_56');
$wp_session['strDeliveryState']='';
$wp_session['strDeliveryPhone'] = $form->getValue('quform_3_55');
} else {
$wp_session['strDeliveryFirstnames'] = $form->getValue('quform_3_59');
$wp_session['strDeliverySurname'] = $form->getValue('quform_3_60');
$wp_session['strDeliveryAddress1'] = $form->getValue('quform_3_61');
$wp_session['strDeliveryAddress2'] = $form->getValue('quform_3_62');
$wp_session['strDeliveryCity'] = $form->getValue('quform_3_63');
$wp_session['strDeliveryPostCode'] = $form->getValue('quform_3_64');
$wp_session['strDeliveryCountry'] = $form->getValue('quform_3_66');
$wp_session['strDeliveryPhone'] = $form->getValue('quform_3_65');
}
}
}
$payMethod = $form->getValue('quform_3_29');
if ($payMethod==2) {
$url = ('https://www.kimboscakes.co.uk/payments');} else {
$url = ('https://www.kimboscakes.co.uk/cake-order-confirm');
}
return $url;
}
add_action('quform_confirmation_redirect_url3_3_1', 'my_success_redirect_url3', 10, 3);
//add_action('quform_success_redirect_url_4', 'mytheme_modify_form_redirect4', 10, 2);
September 12, 2017 at 10:15 am #21873AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
September 12, 2017 at 11:00 am #21877patdundeeParticipantlol got a problem restoring the database hence site down at moment.
Many thanks for that. I will try again as soon as the database is reloaded. For some reason it seems to take forever 🙂
Regards
PatrickSeptember 12, 2017 at 1:07 pm #21899patdundeeParticipantHi Ally
Thanks for all your help and time.
Success on this site. A few niggly things that dont happen on migrate but nothing to worry about. Such as form numbers changing. I have a plug in for search and replace on the database which solves all of those issues so no problem on that one. The other small thing was that not all conditional logic is carried over and you have to manually tell each form to enable it. Again no big issue. The final little detail is if you have 3 columns on the old form (where they are hidden until something is selected, the column auto falls inline. On the new form you create 3 columns and all three elements go in the first column to keep inline. Again no great issue.Onto the next site which is a lot more in depth on the functions but i have got myself a good grip on most of it now so i am not expecting to many issues and most i will probably solve now i have a working knowledge.
Great new style easy to use once you get over the initial shock. Always open to change for the better..
Keep up all the great work
I will be dropping a coffee fund off for you in appreciation of your time, effort and help 🙂
Regards
Patrick- This reply was modified 6 years, 7 months ago by patdundee.
- AuthorPosts
- You must be logged in to reply to this topic.