king-theme
Forum Replies Created
-
Hi!
I’ve checked your website and found that you did wrong settings. Please see my screenshot https://prntscr.com/b67ol3
I corrected it and it works ??
Hi!
The link param will return “link|target|title”. To use it,
$link = explode( $atts['link'] ); // now we have an array ( "link", "target", "title" ); echo '<a href="'.$link[0].'" target="'.$link[1].'">'.$link[2].'</a>';
I’ve updated the plugin to version 2.3.2, please update all of your elements.
From this version, you’ll not need to care about decode.
– “editor” will return as string
– “group” will return as array() and all children field also decode before return to your template
– “textarea” will return as string
– “textarea_html” will work with 3rd party elements. But it’s a special type, read document carefully before use it.
– After add_map, just create a template file: /your_theme/kingcomposer/{shortcode_name}.phpPlease let me know if you found any more trouble.
Thank You so much for helping us!
Hi!
I tested your map with my code bellow
$acoptions = json_decode($atts['acoptions'], true); // decode json as array echo base64_decode( $acoptions[1]['descr'] );
It works, but you make my new idea. I’ll also decode for children fields of “group” so that developers will easier to use.
Hi!
From version 2.3.1, the group field will not need to decode base64.
And for better help, would you can paste full of your map here? Then I can check the incorrection.
Hi!
We’ve updated to version 2.3.1 few hours ago to make sure all of those fields work.
For now,
– Textarea Field does need to base64_decode(), it has been decode before return value to template.
– The “Textarea_html” is now working for 3rd party element, Make sure your shortcode is_container ( [name] [/name] ) and put its name is “content”
– The “editor” has been decode before return to template too
We tested with twentyxxx themes, please try to ctrl+f5 few time to refresh cache.
If it is still not working, give me a live link of your installation then I can check it for you.
Please use this sample code to create 2 tab “General” and “Responsive”
'kc_column' => array( 'name' => 'Column', 'category' => '', 'title' => 'Column Settings', 'is_container' => true, 'css_box' => true, 'tab_icons' => array( 'general' => 'et-tools', 'responsive' => 'et-mobile' ), 'params' => array( 'general' => array( array( 'name' => 'col_container_class', 'label' => __( 'Container class name', 'kingcomposer' ), 'type' => 'text', 'description' => __( 'Add additional classes name to the container in a column.', 'kingcomposer' ) ), array( 'name' => 'col_class', 'label' => __( 'Column class name', 'kingcomposer' ), 'type' => 'text', 'description' => __( 'Add additional classes name to ther outer layer of a column.', 'kingcomposer' ) ) ), 'responsive' => array( 'name' => 'important', 'label' => __( 'Important', 'kingcomposer' ), 'type' => 'checkbox', 'options' => array( 'yes' => __( 'Yes, Please!', 'kingcomposer' ), ), 'description' => __( 'Make this option as important and have a higher priority than other places', 'kingcomposer' ) ), array( 'name' => 'display', 'label' => __( 'Hide Column', 'kingcomposer' ), 'type' => 'checkbox', 'options' => array( 'hide' => __( 'Yes, Please!', 'kingcomposer' ), ), 'description' => __( 'Hide this column in this screen size', 'kingcomposer' ) ), ) ),
Yes, We are planning for Developer hub. Please wait, It’ll be launched soon
Hi!
I’ve just updated to version 2.3, and the owl slider has been fixed.
hope it makes you can increase the number of stars to 5 ??
I’ll think about it and I shall reduce the range. It should be 1/3 for top zone and 2/3 for bottom zone, so when the edit button is on bottom zone the popup will auto move up.
Hi!
Thank you for your feedback, I made a screenshot to explain it https://prntscr.com/b52n2g
Hope you understand it.
The name content is special kind, it returns shortcode content instead attributes.
Example [kc content=”text 1″] text inner [/kc]
It returns “text inner” not “text 1”
More information https://docs.kingcomposer.com/available-param-types/group-fields/
Hi!
This code bellow helps you decode data from “Group” field.
// 'options' is field's name $options = json_decode( base64_decode( $atts['options'] ) ); // Need to decode before use // We encode to keep data's format protected if( isset( $options ) ){ foreach( $options as $option ){ print_r( $option ); // echo $option->__group_field_id__ } }