Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Jeff K

    (@kreitje)

    #1. It uses tables. This reduces the amount of support requests for getting things to look right.

    #2. Not currently supported. If you know javascript you could always create a text custom field (in the custom fields area), then use javascript on the form to hide the input, create a checkbox and then change the hidden inputs value based on the checkbox.

    Thread Starter slabadont

    (@slabadont)

    ok so on #1 where do I edit the tables? and fro #2 I’m not to sure how to do that, any way you can provide any additional support on that?
    Thanks again:)

    Plugin Author Jeff K

    (@kreitje)

    #1. This would be in wp-content/plugins/hms-testimonials/shortcodes.php file. I believe it is the top function. Please note that the next time you update the plugin it will overwrite your changes.

    #2. I imagine so. It might not happen tonight though.

    Plugin Author Jeff K

    (@kreitje)

    Add this to your themes footer.php. Any where you see .cf-testing it needs to be changed to the correct selector. It usually follows cf-{your custom field name}. You can use firebug or chrome developer tools to find the right one. That particular instance is the table row for the custom field. The input box is hidden and has its value set to 0. When you check the box it gets set to 1, and when it gets unchecked it goes back to 0.

    <script type="text/javascript">
    	jQuery(document).ready(function($) {
    
    		$('.cf-testing input[type="text"]').val('0').css('display','none');
    		$('.cf-testing input[type="text"]').before('<input type="checkbox" id="customCheckbox" value="1" />');
    
    		$(document).on('click', '#customCheckbox', function() {
    			if ($(this).is(':checked')) {
    				$('.cf-testing input[type="text"]').val('1');
    			} else {
    				$('.cf-testing input[type="text"]').val('0');
    			}
    		});
    
    	});
    </script>
Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Captcha and checkbox’ is closed to new replies.