katman1971 Posted October 19, 2008 Posted October 19, 2008 Hi I want to create 2 internal links from my homepage. One link will be under "beautiful Irish Art" and the other link will be in the Customer Service box towards the bottom on the left hand side. How do I do this? Thanks
Hotclutch Posted October 19, 2008 Posted October 19, 2008 Hi I want to create 2 internal links from my homepage. One link will be under "beautiful Irish Art" and the other link will be in the Customer Service box towards the bottom on the left hand side. How do I do this? Thanks It will depend on what you are trying to link to and whether the pages have already been created. You can add something like this to catalog\includes\boxes\information.php '<a href="' . tep_href_link(FILENAME_RETURNS) . '">' . BOX_INFORMATION_RETURNS . '</a><br>' .
katman1971 Posted October 19, 2008 Author Posted October 19, 2008 It will depend on what you are trying to link to and whether the pages have already been created. You can add something like this to catalog\includes\boxes\information.php '<a href="' . tep_href_link(FILENAME_RETURNS) . '">' . BOX_INFORMATION_RETURNS . '</a><br>' . Sorry, I should have specified in my 1st post. I want to link to a new / fresh page. Does your instruction still apply?
Hotclutch Posted October 19, 2008 Posted October 19, 2008 Sorry, I should have specified in my 1st post. I want to link to a new / fresh page. Does your instruction still apply? If you want to create a new page and create a link to it from your information box, then an idea is to copy one of the existing pages and corresponding definition file and add the link to the information box like above. You have to edit the copied files in the appropriate places and also add a definition to includes\filenames.php
katman1971 Posted October 20, 2008 Author Posted October 20, 2008 If you want to create a new page and create a link to it from your information box, then an idea is to copy one of the existing pages and corresponding definition file and add the link to the information box like above. You have to edit the copied files in the appropriate places and also add a definition to includes\filenames.php Ok. I'm new at this so I have to take baby steps. How do I copy one of the existing pages and corresponding definition file? How do I edit the copied files in the appropriate places and also add a definition to includes\filenames.php? Thanks
Hotclutch Posted October 20, 2008 Posted October 20, 2008 Copy catalog\shipping.php and rename to new.php in the same directory Open new.php and find this on line 15 require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_SHIPPING); replace with require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_NEW); find on line 19 $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_SHIPPING)); replace with $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_NEW)); Copy catalog\includes\languages\english\shipping.php and rename to new.php in the same directory Open new.php and find on line 13 define('NAVBAR_TITLE', 'Shipping & Returns'); replace with define('NAVBAR_TITLE', 'New'); find on line 14 define('HEADING_TITLE', 'Shipping & Returns'); and replace with define('HEADING_TITLE', 'New'); find on line 16 define('TEXT_INFORMATION', 'Put here your Shipping & Returns information.'); and replace with define('TEXT_INFORMATION', 'Put here your New information.'); Open catalog\includes\filenames.php Add before the closing tag define('FILENAME_NEW', 'new.php'); Open catalog\includes\boxes\information.php find this $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a><br>' . '<a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a><br>' . '<a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a><br>' . '<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a>'); and replace with $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a><br>' . '<a href="' . tep_href_link(FILENAME_NEW) . '">' . BOX_INFORMATION_NEW . '</a><br>' . '<a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a><br>' . '<a href="' . tep_href_link(FILENAME_CONDITIONS) . '">' . BOX_INFORMATION_CONDITIONS . '</a><br>' . '<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a>'); Open catalog\includes\languages\english.php Find // information box text in includes/boxes/information.php define('BOX_HEADING_INFORMATION', 'Information'); define('BOX_INFORMATION_PRIVACY', 'Privacy Notice'); define('BOX_INFORMATION_CONDITIONS', 'Conditions of Use'); define('BOX_INFORMATION_SHIPPING', 'Shipping & Returns'); define('BOX_INFORMATION_CONTACT', 'Contact Us'); Add after define('BOX_INFORMATION_NEW', 'New');
katman1971 Posted October 20, 2008 Author Posted October 20, 2008 Thanks. Looking at your instructions, I think that adds the link in the Customer service box. What about the link I want to put in the text area under "beautiful Irish Art"? Or does your instruction include that also? thanks
katman1971 Posted October 20, 2008 Author Posted October 20, 2008 There is one thing really bugging me after successfully adding the link: The wording of the link is "New" (in the Customer Sevice Box). I simply want to change the word to "Warning". How do I do that? Thanks
Hotclutch Posted October 21, 2008 Posted October 21, 2008 There is one thing really bugging me after successfully adding the link: The wording of the link is "New" (in the Customer Sevice Box). I simply want to change the word to "Warning". How do I do that? Thanks Change "New" to "Warning" everywhere in the instruction.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.