• I would like to have multiple “Content Boxes” available to enter content either on a page or in a post.

    I found a plugin which adds a second “Content Box”, but not a third, fourth, fifth, etc. If I knew PHP, I would figure out how to extent this plugin to accommodate unlimited “Content Boxes”. Can anyone help with a solution?

    Here’s the plugin I found:
    Secondary HTML Content

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Adam

    (@panhead)

    Once again, I answered my own question. I found Custom Field Template plugin that works perfect! The only problem is that there are no good instructions on how to use it. (FYI, I am using WP 2.9.1 with plugin version 1.5.5.)

    https://www.ads-software.com/extend/plugins/custom-field-template/

    Here are my basic, simple instructions on how to use Custom Field Template. Please let me know if this works for you!

    Add to the “functions.php” file:

    // Get Custom Field Template Values
    function getCustomField($theField) {
    	global $post;
    	$block = get_post_meta($post->ID, $theField);
    	if($block){
    		foreach(($block) as $blocks) {
    			echo $blocks;
    		}
    	}
    }

    Set Up Template:
    In WordPress: Settings > Custom Field Template

    [Block #1]
    type = textarea
    rows = 8
    tinyMCE = true
    ?
    [Block #2]
    type = textarea
    rows = 8
    tinyMCE = true
    
    [Block #3]
    type = textarea
    rows = 8
    tinyMCE = true
    
    etc....

    Delete “etc….” in Custom Field Template settings.

    Call a content Area in page:

    <?php
    $block = get_post_meta($post->ID, 'Block #1');
    foreach(($block) as $blocks) {
    echo $blocks;
    }
    ?>

    Hope this helps someone!

    Wish granted. The plug-in now allows up to 5 HTML blocks on posts and / or pages.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Unlimited HTML Content Boxes’ is closed to new replies.