Results 1 to 9 of 9

Hybrid View

  1. #1
    Join Date
    Feb 2007
    Posts
    107
    Plugin Contributions
    0

    Default Coders--- is this ok?

    I wanted to add an extra link into the Information sidebox (ZenCart v. 1.3.7) and spent several days on the boards trying to learn the methods. I did download the "About Us" module, as many posts suggested, but was scared away from using it because it required editing core files and I don't want to lose any changes on upgrade.
    I also could not use the EZ-Pages sidebox, which was a method favored by many users, because it is already being utilized for something else on my site.

    Long story short, I found a post where someone was adding a link to an EZ-page to his "More Information" sidebox as opposed to the "Information" box, so I edited the code I found there since the link I needed is also pointing to an EZ-Page. What I wound up with is:

    $information[] = '<a href="' . zen_ez_pages_link(4) . '">Dog Clothes Sizing</a>';

    which I pasted directly into my information.php file located in /includes/modules/sideboxes/MYTEMPLATE/ folder

    Everything works fine. The only issue I notice is that the link url that is in the Information sidebox ends with page&id=4 while the link in the footer bar (which points to the same page) has a url ending with page&id=4&chapter=0. Is this a major issue that will get me penalized by search engines?

    Also, is there anything wrong with that code I pasted into my information.php file? In particular, I wasn't sure if the $information[] part was correct, since nothing else in the information.php file starts with that.

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Coders--- is this ok?

    The code building the footer could use a bit of tidying up to not include the chapter when set to 0 ..

    We will look into this further for a future release ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Feb 2007
    Posts
    107
    Plugin Contributions
    0

    Default Re: Coders--- is this ok?

    Oh my goodness, do you mean I actually did that right?! (lol). It's odd trying to play with code that you don't understand in the least bit, but I figure if I look for patterns and use the overrides then I can always undo things. Yes, I will learn php eventually, but right now I'm bringing myself up to date with CSS2 (I only know v.1) and XHTML (I only knew old-school html). Php is next though, since learning keeps the brain young.

    Is there anything I should do right now about the urls? Or is it just not that big of an issue?

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Coders--- is this ok?

    I doubt it will be a major issue ...

    The changes to fix this are ... fast ain't I, eh?

    change line 53 in:
    /includes/modules/ezpages_bar_footer.php
    PHP Code:
          zen_href_link(FILENAME_EZPAGES'id=' $page_query->fields['pages_id'] . ($page_query->fields['toc_chapter'] > '&chapter=' $page_query->fields['toc_chapter'] : ''), ($page_query->fields['page_is_ssl']=='0' 'NONSSL' 'SSL')) : 
    change line 52 in:
    /includes/modules/ezpages_bar_header.php
    PHP Code:
          zen_href_link(FILENAME_EZPAGES'id=' $page_query->fields['pages_id'] . ($page_query->fields['toc_chapter'] > '&chapter=' $page_query->fields['toc_chapter'] : ''), ($page_query->fields['page_is_ssl']=='0' 'NONSSL' 'SSL')) : 
    change line 50 in:
    /includes/modules/sideboxes/ezpages.php
    PHP Code:
            zen_href_link(FILENAME_EZPAGES'id=' $page_query->fields['pages_id'] . ($page_query->fields['toc_chapter'] > '&chapter=' $page_query->fields['toc_chapter'] : ''), ($page_query->fields['page_is_ssl']=='0' 'NONSSL' 'SSL')) : 
    Now they will not have the chapter when the chapter is 0 ...
    Last edited by Ajeh; 18 Mar 2007 at 03:15 AM. Reason: oppers ... fixed a typo on the path
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  5. #5
    Join Date
    Apr 2004
    Location
    Montreal
    Posts
    755
    Plugin Contributions
    1

    Default Re: Coders--- is this ok?

    Dang, thanks, I needed that as well
    IntelCos

  6. #6
    Join Date
    Feb 2007
    Posts
    107
    Plugin Contributions
    0

    Default Re: Coders--- is this ok?

    Thank you VERY much, that works perfectly!

    Just in case anyone else is editing the same files, in the instructions above where it says:
    " /includes/sideboxes/ezpages.php"

    the path is actually /includes/modules/sideboxes/ezpages.php

    Linda, please don't take any offense at the correction, I'm just trying to make it easier for any newer Zenners that may be reading this.

 

 

Similar Threads

  1. Coders I need help
    By christoph100 in forum Addon Shipping Modules
    Replies: 8
    Last Post: 16 Oct 2007, 05:34 PM
  2. Not sure if this is possible? (Directed toward devs/coders)
    By paitken in forum General Questions
    Replies: 12
    Last Post: 13 Nov 2006, 06:44 AM

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