SUCCESS message, Conditional Select option

Home Forums Quform PHP SUCCESS message, Conditional Select option

This topic is: resolved
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #32772
    dubiousa
    Participant

    Hi guys, you did a hellofajob here and i love your product, but the documentation is albeit good , but lacking.
    I understand you do not want to give it up for free, but NONE of your template files and nowhere in the documentation i can find how to add the fancy success message you have here:

    Elements

    Also, i somehow can’t read old posts from this forum (somehow i thought i will perhaps find answers here, but all i see is i do not have access because im not registered customer – which i clearly am).

    • This topic was modified 1 week, 3 days ago by dubiousa.
    #32773
    dubiousa
    Participant

    Why is this not in the documentation?

    “Ok, if you put a div that wraps all form fields and give it the class class quform-elements the success message will be inserted before this. To get the field errors to show you’ll need to have a wrapper around each field (e.g. div) with the class element-wrapper.”

    Solves problem. Hour search in internetz.

    #32780
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #32783
    dubiousa
    Participant

    Hi Ally, yes you are right. Sadly i have started with the index.html you provide and as NOT knowing the “quform-elements” are being used for this i deleted the div 😀
    Perhaps a comment:
    // this div is used for ajax success output
    would be nice in the provided index.html

    Thanks!

    Also, do not want to create yet another thread, but for everybody looking for CONDITIONAL logic, here is a simple VANILLA js for hiding options in select in condition from another select:

    
    document.addEventListener('input', function (event) {
    	if (event.target.id !== 'firstSelectId') return;
    	let firstSelectVariable = event.target.value;
    	console.log(firstSelectVariable);
    
    	var optionsSecondSelect = document.getElementsByClassName('SecondSelectClassName');
    	for (var i = 0; i < optionsSecondSelect.length; i++) {
            if (optionsSecondSelect[i].className.includes(firstSelectVariable)) { 
                  //console.log("I see the dead people");
    			  optionsSecondSelect[i].style.display = "block";
    		}
    		else { 
    			  optionsSecondSelect[i].style.display = "none";
    		}
    	}
    }, false);
    

    For this to work the options in second select have to have a
    class=”SecondSelectClassName firstSelectVariable”
    with “SecondSelectClassName” static
    and “firstSelectVariable” to be filtered after!

    • This reply was modified 1 week, 3 days ago by dubiousa.
    #32788
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.
Be inspired. © 2020 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy