Dieses Dokuwiki verwendet ein von Anymorphic Webdesign erstelltes Thema.

Adding New Dynamic Content Pages

I haven't got round to fully testing this yet but I believe it works! Quite alot of files require modifying, remember to backup your files first!!

This guide has been made for use with osCMax V2.0 or higher. Credit to author mhouchin.

  • This is a worked example for creating about.php

1. Creating the pages for the front end

The following files changes need to be made in the catalog folders.

1.1 Copy shipping.php and rename to about.php

  • Within this file change all references of _SHIPPING to _ABOUT

1.2 Open /includes/filenames.php

  • Add the following definitions:

  define('CONTENT_ABOUT', 'about');
  define('CONTENT_ABOUT_CONTENT', 'about_content');
  define('FILENAME_ABOUT', CONTENT_ABOUT . '.php');
  define('FILENAME_ABOUT_CONTENT', CONTENT_ABOUT_CONTENT . '.php');

1.3 Copy includes/languages/english/shipping.php and rename to about.php

  • Within this file change all the relevant information as applicable.

1.4 Copy includes/languages/english/shipping_content.php and rename to about_content.php

  • Within this file change all the relevant information as applicable.

1.5 Copy templates/[templatename]/content/shipping.tpl.php and rename to about.tpl.php (you may need to copy this file from the fallback template first)

  • Within this file change:

     <?php include(DIR_WS_LANGUAGES . $language . '/' . FILENAME_SHIPPING_CONTENT); ?> 
and change it to:
     <?php include(DIR_WS_LANGUAGES . $language . '/' . FILENAME_ABOUT_CONTENT); ?>

1.6 Open includes/configure_bts.php

  • Add the following definition: (about line 20)

     define('TEMPLATENAME_ABOUT', 'about.tpl.php');

1.7 Insert this wherever you want to link to the page put:

     <a href="<?php echo tep_href_link(FILENAME_ABOUT) ?>">ABOUT US</a>


2. Creating the pages in admin section

The following files changes need to be made in the admin folders.

2.1 Open /admin/index.php

Find:

array('title' => BOX_CATALOG_DEFINE_SHIPPING, 'link' => tep_href_link(FILENAME_DEFINE_SHIPPING, 'selected_box=catalog')),

  • And duplicate it for each page you want to add, modifying SHIPPING to ABOUT


2.2 Open /admin/includes/boxes/catalog.php

Find:

tep_admin_files_boxes(FILENAME_DEFINE_SHIPPING, BOX_CATALOG_DEFINE_SHIPPING) .

  • And duplicate it for each page you want to add, modifying SHIPPING to ABOUT


2.3 Copy admin/define_shipping.php and rename to define_about.php

  • Change all references of SHIPPING to ABOUT (13 in total)


2.4 Open admin/includes/languages/english.php

  • Add the following definition:

  define('BOX_CATALOG_DEFINE_ABOUT', 'About Page');


2.5 Open admin/includes/filenames.php

  • Add the following definition: (around line 82)

  define('FILENAME_DEFINE_ABOUT','define_about.php');
  define('FILENAME_DEFINE_ABOUT_CONTENT', 'about_content.php');



3. Enable access to the file

Add access to define_about.php in the administrator menu by enabling file access

  • Open your admin panel
  • Click on the Administrator Menu box
  • Click File Access in Menu box
  • Select the Catalog row in the central box
  • Click Store Files in right hand column
  • Select define_about.php from the drop down
  • Click Save

Don't forget to set the Member Groups –> Groups –> New Permission

  • Bookmark at
  • Bookmark "Adding New Dynamic Content Pages" at Digg
  • Bookmark "Adding New Dynamic Content Pages" at Furl
  • Bookmark "Adding New Dynamic Content Pages" at Reddit
  • Bookmark "Adding New Dynamic Content Pages" at Google
  • Bookmark "Adding New Dynamic Content Pages" at StumbleUpon
  • Bookmark "Adding New Dynamic Content Pages" at Technorati
  • Bookmark "Adding New Dynamic Content Pages" at Facebook
  • Bookmark "Adding New Dynamic Content Pages" at Twitter
  • Bookmark "Adding New Dynamic Content Pages" at Slashdot
adding_new_dynamic_content_pages.txt · Last modified: 2010/04/23 04:38 by 94.66.20.49
You are here: startadding_new_dynamic_content_pages
Dieses Dokuwiki verwendet ein von Anymorphic Webdesign erstelltes Thema.
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0