Forum Replies Created
-
AuthorPosts
-
cyclissmoMember3 years later and this should have been addressed by now. I have to do this same hackery to include piklist fields in my REST endpoints.
cyclissmoMemberI am getting the same error:
Error: Syntax error, unrecognized expression: unsupported pseudo: -webkit-autofillFor the time being, I just wrapped the offending code in parts/js/admin.js in a try/catch block, and the error is gone. Hopefully this will be taken care of in the next update ๐
Piklist 1.0.3, with all other plugins disabled.
Wordpress 4.9.10
Using Firefox Quantum 66.0.3 64bit on Windows 10
cyclissmoMemberI use this action sparingly, only for “mission critical” websites. I just plop it into functions.php, outside of any action callback and it works just fine:
remove_action( 'wp_footer', array( 'piklist_theme', 'piklist_love' ), 1000 );And then there is the meta “generator” that also specifies piklist which should be removed as well:
remove_action('wp_head', array('piklist_theme', 'version_in_header'));August 31, 2017 at 1:11 pm in reply to: [Bug] non-numeric value encountered in class-piklist.php #8370
cyclissmoMemberGetting the exact same message.
Piklist 9.9.12
December 22, 2016 at 1:04 pm in reply to: Add-more metabox – not displaying all values properly after removing a value #7691
cyclissmoMemberThanks for checking in on it, Steve.
For now I can just tap into one of the many postmeta filters to re-index the array (assuming that’s what is causing the problem!) I’ll update this post if I discover anything new.
cyclissmoMemberThank you Steve for offering to look over my code. I was able to get Settings Tabs to work ๐
What didn’t work was using the setting name for the Page parameter in the comment block.
To make Settings Tabs work, use the
menu_slugvalue (from the new settings page parameters) for the Page parameter in the Workflow Heading page’s comment block.
cyclissmoMemberThe tutorial is somewhat ambiguous towards tabs for settings – in fact, it says Workflows are for Posts and Users. I haven’t been able to get tabs for Settings to work in 9.9 either ๐
cyclissmoMemberSolved! I found the answer right after posting:
get_post_status_object( get_post_status( $post->ID) )Which returns something like this:
stdClass Object ( [label] => CC Authorization [label_count] => Array ( [0] => CC Authorization (%s) [1] => CC Authorization (%s) [singular] => CC Authorization (%s) [plural] => CC Authorization (%s) [context] => [domain] => ) [exclude_from_search] => [_builtin] => [public] => 1 [internal] => [protected] => 1 [private] => [publicly_queryable] => 1 [show_in_admin_status_list] => 1 [show_in_admin_all_list] => 1 [capability_type] => jnl_subscription_txn [hierarchical] => [has_archive] => [show_in_admin_all] => [single_view_cap] => [name] => authorize )
cyclissmoMemberDon’t forget the native Featured Image/post thumbnail metabox:
postimagediv
cyclissmoMemberMy contribution, possibly related:
/** * Business hours */ piklist('field', array( 'type' => 'group', 'label' => 'Business hours', 'add_more' => true, 'columns' => 12, 'fields' => array( array( 'type' => 'select', 'field' => 'jnl-from', 'choices' => array( 'Monday' => 'Monday', 'Tuesday' => 'Tuesday', 'Wednesday' => 'Wednesday', 'Thursday' => 'Thursday', 'Friday' => 'Friday', 'Saturday' => 'Saturday', 'Sunday' => 'Sunday' ), 'attributes' => array( 'style' => 'float:left;' ) ), array( 'type' => 'html', 'field' => '', 'value' => 'Through', 'attributes' => array('style' => 'float:left;margin:0 12px;'), ), array( 'type' => 'select', 'field' => 'jnl-to', 'choices' => array( 'Monday' => 'Monday', 'Tuesday' => 'Tuesday', 'Wednesday' => 'Wednesday', 'Thursday' => 'Thursday', 'Friday' => 'Friday', 'Saturday' => 'Saturday', 'Sunday' => 'Sunday' ), ), // Hours sub-group array( 'type' => 'group', 'field' => 'jnl-hours', 'add_more' => true, 'columns' => 12, 'fields' => array( array( 'type' => 'select', 'field' => 'jnl-from-time-hour', 'choices' => array('1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12'), 'attributes' => array( 'style' => 'float:left;' ), ), array( 'type' => 'select', 'field' => 'jnl-from-time-minutes', 'choices' => array(':00 AM', ':30 AM', ':00 PM', ':30 PM'), 'attributes' => array( 'style' => 'float:left;' ), ), array( 'type' => 'html', 'field' => '', 'value' => 'To', 'attributes' => array( 'style' => 'float:left;margin:0 12px;' ) ), array( 'type' => 'select', 'field' => 'jnl-to-time-hour', 'choices' => array('1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12'), 'attributes' => array( 'style' => 'float:left;' ), ), array( 'type' => 'select', 'field' => 'jnl-to-time-minutes', 'choices' => array(':00 AM', ':30 AM', ':00 PM', ':30 PM'), 'attributes' => array( 'style' => 'float:left;' ), ), ) ), ) ));
cyclissmoMemberIn case anyone else is interested in unit testing their custom plugins and don’t know how to set up their environment, this tutorial got me on the right track:
cyclissmoMemberThank you sir. I hope my post didn’t come across as a complaint. Piklist is a fantastic piece of work, and what I’ve learned about it so far has changed my perception of WordPress being a viable development platform to offer my clients now. I’m sure if I worked with WordPress more frequently I would have less trouble understanding how piklist works.
-
AuthorPosts