• Hi, I think that there is a problem with the auto hook option. I created a custom post type and choosed it in the post type option in the custom field templates admin. The problem is that it shows the fields in every post type (not only the one I choose).
    I have no time right now to post a fix for the plugin code, but found a quik fix that works. Inside the content part of the auto hook option, I enclosed my hook with an if statement.

    //To chek if it is my post type "componentes"
    <?php global $post; $tipo=(get_post_type( $post )); if (($tipo)=='componentes') { ?>
    //The actual hook
    <a href='[cft key='Sitio oficial']'>Sitio oficial</a>
    <a href='[cft key='Soporte']'>Soporte</a>
    <a href='[cft key='Preguntas frecuentes']'>Preguntas frecuentes</a>
    <a href='[cft key='Documentación oficial']'>Documentación oficial</a>
    <a href='[cft key='Documentación en español']'>Documentación en español</a>
    
    <?php global $post; $Idiomaes=get_post_meta($post->ID, 'Idiomaes', true); ?> <a href="/wp-content/uploads/<?php echo wp_get_attachment_url($Idiomaes); ?>" >Archivo de idioma es_ES </a>
    <?php global $post; $Idiomaar=get_post_meta($post->ID, 'Idiomaar', true); ?> <a href="/wp-content/uploads/<?php echo wp_get_attachment_url($Idiomaar); ?>" >Archivo de idioma es_AR </a>
    <?php }; ?>

    I’m preety sory about my english : )

The topic ‘[Plugin: Custom Field Template] Post types problem with auto hook’ is closed to new replies.