Support

Account

Home Forums Front-end Issues Field content displays without CSS?

Solved

Field content displays without CSS?

  • I created new text field with your great plugin and I am calling it with my function (I’m using Thematic Theme Framework childtheme):

    // Adds “Status” field to posts
    function add_status_field() {
    the_field(‘status’);
    }
    add_action(‘thematic_abovepost’, ‘add_status_field’);

    Everything displays fine on both languages (I’m using WPML plugin) but there is no CSS generated in my HTML, only pure text. Is there any option in your plugin settings to accomplish that (couldn’t find any) or is it a bug? Or do I have to call my CSS class with my childtheme function and if so, how can I accomplish that?

  • Hi @Soulstudio

    This is no bug. The result is exactly what you have coded. If you wish to create any MARKUP, you need to code this youself. eg:

    
    <?php 
    
    // Adds “Status” field to posts
    function add_status_field() {
    	
    	?><p class="class-here"><?php the_field('status'); ?></p><?php
    	
    }
    add_action('thematic_abovepost', 'add_status_field');
    
     ?>
    
Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘Field content displays without CSS?’ is closed to new replies.