Results 1 to 7 of 7
  1. #1
    Join Date
    Jul 2011
    Posts
    49
    Plugin Contributions
    0

    Default Adding a new Defined Page

    So, my addign a link worked as per Dr. Byte,


    Lets say my link reads

    $information[] = '<a href="http://www.misterguns.com/catalog/index.php?main_page=potato">Testopotomus</a>';

    How do I create a page called potato and make the link work?

    looking at another example, lets say conditions. i see

    <li><a href="http://www.misterguns.com/catalog/index.php?main_page=conditions">Conditions of Use</a></li>

    I see a conditions.php in the includes/languages/english folder

    I see the text is in define_conditions under the includes/languages/english/HTML_Included folder but i fail to see how the .../index.php?main_page=conditions" makes the connection to the DEFINE_CONDITIONS page.

    I want to make a DEFINE_POTATO.php and have it link...whats the way to do that?

  2. #2
    Join Date
    Jun 2003
    Posts
    33,715
    Plugin Contributions
    0

    Default Re: Adding a new Defined Page

    Moderator's note: Post moved to a thread of its own.

    Have a look in the Free AddOns - Look for the "About Us" addon - follow the same principals to create your own pages.
    Please do not PM for support issues: a private solution doesn't benefit the community.

    Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

  3. #3
    Join Date
    Jul 2011
    Posts
    49
    Plugin Contributions
    0

    Default Re: Adding a new Defined Page

    Is there not a simpler way? Not being lazy, just asking...

    To be more specific, Ill just manually add the link. I don't need the SQL and the PHP If statements. Which parts are what is relevant to just define the page (within the about us plugin)?
    Last edited by rolo550; 16 Aug 2011 at 03:56 AM.

  4. #4
    Join Date
    Jul 2011
    Posts
    49
    Plugin Contributions
    0

    Default Re: Adding a new Defined Page

    so I have been over and over the about us, as well as digging through the "conditions" files to try to determine what the structure is. Admittedly I'm not so good at PHP.

    Using the About US and other examples in the site, I cannot figure out the structure.

    I know that filenames.php and header_php.php are related to pulling the correct files. I know that conditions and define_conditions are called by the TPL_Conditions_default.php, but for the life of me I cant figure out what is going on.

    What calls what that calls what? The About_Us readme hasn't done much to help except sort of point out what files i need to look for.

    Please help, I really am trying to help myself, but I just need a bone...if i can just understand the structure it would make all the difference...
    Last edited by rolo550; 16 Aug 2011 at 05:39 AM. Reason: typos

  5. #5
    Join Date
    Jul 2011
    Posts
    49
    Plugin Contributions
    0

    Default Re: Adding a new Defined Page

    Also

    in a link like

    a href="http://www.misterguns.com/catalog/index.php?main_page=conditions

    what does 'conditions' correspond to - where is that tied in with the link in some other page?

  6. #6
    Join Date
    Jul 2011
    Posts
    49
    Plugin Contributions
    0

    Default Re: Adding a new Defined Page

    Any comments?

  7. #7
    Join Date
    Jul 2011
    Posts
    49
    Plugin Contributions
    0

    Default Re: Adding a new Defined Page

    After hours of digging, no thanks to the cryptic minimally helpful about_us module readme.txt, I managed to figure it out on my own how do do this. Here is the procedure for the rest of you guys that only get pointed to a module with no further help...

    Adding a page to the information box

    1. Edit Catalog\includes\templates\mytemplate\modules\sideboxes\information.php

    Add

    $information[] = ‘<ahref="http://www.mydomain.com/catalog/index.php?main_page=chl">CHL</a>';

    Above where it says:

    if (DEFINE_SHIPPINGINFO_STATUS <= 1) {
    $information[] = '<a href="' . zen_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a>';

    For the sake of this discussion the added page will be called “CHL”

    2. Edit includes\filenames.php and add
    define('FILENAME_CHL', 'chl');
    define('FILENAME_DEFINE_CHL', 'define_chl');

    3. Go to includes\modules\pages and copy an existing folder like “conditions” and rename it to the page name, in this case “chl” would be the folder name

    4. Open the header_php.php file in the chl folder and edit the line that says:

    FILENAME_DEFINE_CONDITIONS (because we copied the “conditions’ folder) , replacing it with FILENAME_DEFINE_CHL

    5. Copy some file like includes\templates\template_default\templates tpl_conditions_default rename it to tpl_chl_default.php

    remove the if statements making the text look like this:

    <div class="centerColumn" id="chl">
    <h1 id="chlHeading"><?php echo HEADING_TITLE; ?></h1>


    <div id="chlMainContent" class="content">
    <?php
    /**
    * require the html_define for the shippinginfo page
    */
    require($define_page);
    ?>
    </div>

    6. Move your tpl_chl_default to includes\templates\mytemplate\templates

    7. Copy a file like includes\languages\english\html_includes\define_conditions.php to includes\languages\english\html_includes\mytemplate and rename it to define_chl.php

    Edit text and html to your liking

    8. Copy a file like “conditions.php” to includes\languages\english\mytemplate and rename to chl.php. Edit the navbar and heading text to your liking

    Done!!!
    Last edited by rolo550; 18 Aug 2011 at 03:33 AM.

 

 

Similar Threads

  1. New defined page in html_includes not showing
    By Sheryll in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 17 Jan 2010, 04:33 PM
  2. New Page adding - using Defined Pages
    By shawnchr in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 1 Jul 2009, 04:01 PM
  3. Followed steps, defined new page, but no text shows up.
    By slichdesign in forum Customization from the Admin
    Replies: 3
    Last Post: 2 Apr 2009, 01:16 AM
  4. adding new 'defined pages' problems..
    By LoSpaccone in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 2 Jul 2007, 09:02 PM
  5. adding another defined page to the information box?
    By snarkys in forum General Questions
    Replies: 6
    Last Post: 22 Nov 2006, 01:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR