Best way to add editable fields for each page in the pages module.

I'm trying to add some custom fields for a bunch of pages of my site. Currently they are all using the same layout, and I have this code in MY_fuel_layouts.

// commonLaoyut layout fields $config['layout_fields']['commonLayout'] = array( 'copy' => array('copy' => lang('layout_field_main_copy')), 'page_title' => array('label' => lang('layout_field_page_title')), 'meta_description' => array('label' => lang('layout_field_meta_description')), 'meta_keywords' => array('label' => lang('layout_field_meta_keywords')), 'body' => array('label' => lang('layout_field_body'), 'type' => 'textarea', 'description' => lang('layout_field_body_description')), );

Then to allow inline editing, i'm adding this code in my view
<?php echo fuel_var('page_title'); ?>

How can I make custom fields for each page? Do I have to give them all their own layout and specify as i'm doing or is there a better way to do it?

Comments

Sign In or Register to comment.