Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • in reply to: "Quick edit" & post statuses: A small bug #3542
    natchriss
    Member

    !!! 😀

    (so.. you already knew that)

    Okies… truth time. That “soon” is killing me!! 😛 haha

    Will it be the same version that will have the frontend forms too? How soon?

    Can’t wait!

    in reply to: Nested groups and conditionals #3535
    natchriss
    Member

    Hi @Steve! First off, congrats to the team for the excellent work! I’m one of the “outsiders” who never used ACF, Types and the like just because I don’t want to be restricted by ‘their way of doing things’. So coding was the only option to maintain the WP way.

    Now, what I said wasn’t about updating a hidden field. But not being able to monitor a field twice.

    Let me replicate a code example using the same parameters as above:

    piklist('field', array(
        'type' => 'group'
        ,'label' => 'Address:'
        ,'fields' => array(
    
        		array(
        		'type' => 'text'
    	        ,'field' => 'address'
    	        ,'label' => 'Street Address:'
    	        ,'columns' => 12
    	      )
    
        		,array(
    	        'type' => 'select'
    	        ,'field' => 'state'
    	        ,'label' => 'State:'
    	        ,'columns' => 4
    	        ,'choices' => array(
    	        	'CA' => 'California'
    	        	,'NY' => 'New York'
    	        	,'DC' => 'District of Columbia'
    	        	,'TX' => 'Texas'
    	        	,'Non-US' => 'Not from USA'
    	        	)
    	        /** The part that won't work IF we also have
    	        * the other condition on the next field
    	        */
    	        // Start: -->
    	        ,'conditions' => array(
    	        	array(
    	        		'type' => 'update' 
    	        		,'value' => 'Non-US'
    	        		,'compare' => '!='
    	        		,'field' => 'country'
    	        		,'update' => 'USA'
    	        	)
            	)
            	// <-- End
          	)
    
             	,array(
           		'type' => 'text'
           		,'field' => 'state_other'
    	        ,'label' => 'State/Province/Region:'
    	        ,'columns' => 4
    	        ,'conditions' => array(
    	         	array(
    	        	      'field' => 'state'
    	        	      'value' => 'Non-Us'
    	        	)
    	          )
            	)
    
            	,array(
          		'type' => 'text'
          		,'field' => 'country'
          		,'label' => 'Country:'
          		,'columns' => '4'
          	        )
        )
    ));

    In this quick example we have a field (state_other) hidden and only shown when the “Non-US” option is selected from the state field. That’s the first time we monitor the latter. So far so good.

    Now, if we wanted to monitor the state field [with our other condition in place] to update the last field (country) [i.e. monitor the same field twice], we can’t.

    Makes sense now?

    I figured that you’re intentionally not allowing “double monitoring” to prevent other issues (?), but since I found a case that it’d be useful, I thought I should mention it.

    PS – Irrelevant: On another note, are all HTML form attributes supported? Could we use autocomplete' => 'on' for instance?

    in reply to: License Information #3533
    natchriss
    Member

    That’s not an “official” reply, so you might want to wait for Steve’s answer 😉
    But I’ll put my 2 cents anyway.

    Piklist is under GNU General Public License (GPLv2). So yes, you can include it in any of your projects (personal or commercial) –as long as you don’t infringe copyright of course.

    Don’t forget that it was created mainly for developers. 😉

    Just make sure that you include Piklist checker in your theme to notify users that the plugin is needed for the theme to work properly. (and they download the plugin themselves)

    in reply to: Nested groups and conditionals #3528
    natchriss
    Member

    I noticed that you can’t have a field “monitored” twice. I.e. (i) to show/hide a field AND (ii) to update another field.

    Quick example: We have a “US States” select field with one option being “I’m not from US”. If that option is selected, a textbox is shown for manual input of state/province. That condition works.
    We have another textbox called “Country”.
    If we wanted to monitor the “US States” field (again) to auto-update the “Country” field to ‘USA’ unless the “I’m not from US” is selected, we can’t.

    Don’t know if it’s a bug but I thought I had to mention it. 🙂

Viewing 4 posts - 1 through 4 (of 4 total)