Forums / Customization from the Admin / Followed steps, defined new page, but no text shows up.

Followed steps, defined new page, but no text shows up.

Locked

Views: 1,123

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
30 Mar 2009, 3:19 AM
#1
slichdesign avatar

slichdesign

New Zenner

Join Date:
Mar 2009
Posts:
3
Plugin Contributions:
0

Followed steps, defined new page, but no text shows up.

To answer your questions:

  • Using Ver 1.3.8a
  • Not upgraded, this is the first time using it for a project.
  • No addons
  • The steps I have done so far is installing zen cart, creating a new customized template, editing the CSS and adding/customizing mark up for the index page and the new page I just made.

Where I am now - I followed the steps as outlined on the "Creating new pages" in the Wiki - http://www.zen-cart.com/wiki/index.php/Creating_new_pages - This is the best and easiest description/method I have found so far, as for a "how to" on creating new pages.

The PROBLEM: I followed the steps, created the page successfully, but the text from the define pages editor won't show up. I'm doing this for a client, so I need the text to be editable for them.

Thanks.

30 Mar 2009, 4:57 AM
#2
bunyip avatar

bunyip

Totally Zenned

Join Date:
Sep 2004
Location:
Western Massachusetts
Posts:
2,361
Plugin Contributions:
1

Re: Followed steps, defined new page, but no text shows up.

What that wiki page doesn't tell you is how to get content into a new page that is defined from the define pages editor.

I'm assuming you have created a file such as includes/languages/english/html_includes/define_my_new_page.php and created the define statement like ```
define(FILENAME_DEFINE_MY_NEW_PAGE, 'define_my_new_page');


You need to add a define_page statement into includes/modules/pages/your_new_page/header_php.php like this:

$my_defined_content = zen_get_file_directory(DIR_WS_LANGUAGES . $_SESSION['language'] . '/html_includes/', FILENAME_DEFINE_MY_NEW_PAGE, 'false');


then you need to add that into your new page template file like this:```
<?php
  require($my_defined_content);
?>

Neville
An assumption is what you arrive at when you get tired of thinking...

30 Mar 2009, 8:08 PM
#3
slichdesign avatar

slichdesign

New Zenner

Join Date:
Mar 2009
Posts:
3
Plugin Contributions:
0

Re: Followed steps, defined new page, but no text shows up.

You are right in your assumptions. However, I have the define statements in place relative for both files. In the header file I have 2 statements:

require(DIR_WS_MODULES . zen_get_module_directory('require_languages.php'));
$breadcrumb->add(NAVBAR_TITLE);

// include template specific file name defines
$define_page = zen_get_file_directory(DIR_WS_LANGUAGES . $_SESSION['language'] . '/html_includes/', FILENAME_DEFINE_ABOUT, 'false');

I duplicated the header file for page_2 in the same dir and then changed the filename in the string to about (also because I was able to make page_2 text show up in the initial tryout).

In the tpl_about_default.php page I have

<?php /** * load the html_define for the about default */ require($define_page); ?>

This is the same as in page_2, Page_3, etc...

2 Apr 2009, 12:16 AM
#4
slichdesign avatar

slichdesign

New Zenner

Join Date:
Mar 2009
Posts:
3
Plugin Contributions:
0

Re: Followed steps, defined new page, but no text shows up.

A little more help would be appreciated. The text is still not showing up. Thanks for your help.