erniethemilk Posted April 4, 2007 Posted April 4, 2007 I'm wanting to add a box on my store to put in a reciprocal link to another site. Can someone explain in easy terms ( :lol: ) how I go about doing it Thanks :)
Jack_mcs Posted April 4, 2007 Posted April 4, 2007 Try this: Make a copy of the information infobox. Name it what ever you want. Make an entry for it in the includes/filenames.php. Add the definitions in english.php. Add a link in one of the column files. Edit the box to have the link you want. Jack Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
Bushmaster Posted April 4, 2007 Posted April 4, 2007 I'm wanting to add a box on my store to put in a reciprocal link to another site. Can someone explain in easy terms ( :lol: ) how I go about doing it Thanks :) The documentation makes it about as easy as it can get. http://www.oscommerce.info/kb/osCommerce/Catalog_Area/Boxes
erniethemilk Posted April 6, 2007 Author Posted April 6, 2007 OK, so I now have a box based on the information box as per the above link, but I can't figure out how to change the box heading or populate it with reciprocal links :( Anyone able to offer single syllable advice to a complete baffoon :lol:
rrrhythm Posted April 6, 2007 Posted April 6, 2007 Anyone able to offer single syllable advice to a complete baffoon :lol: "baffoon" would that be a baffled buffoon, or a befuddled baboon. ok, now that i got that silliness out of my system. going from jack's advice: 1. Make a copy of the information infobox.2. Name it what ever you want. 3. Make an entry for it in the includes/filenames.php. 4. Add the definitions in english.php. 5. Add a link in one of the column files. 6. Edit the box to have the link you want. what have you done? i'm assuming you have sucessfully done #'s 1, 2, 3, and 5 if you have got the box appearing on your site. so that leaves you #'s 4 and 6. start with number 6 by opening the file: catalog/includes/boxes/yourNewBox.php. if you based it on information.php, it will look like this: <?php /* $Id: information.php,v 1.6 2003/02/10 22:31:00 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License*/ ?> <!-- information //--> <tr><td> <?php $info_box_contents = array(); $info_box_contents[] = array('text' => BOX_HEADING_INFORMATION, 'params' => ' id="headingInformation"'); new infoBoxHeading($info_box_contents, false, false); //create an instance of infoBoxHeading $info_box_contents = array(); $info_box_contents[] = array('text' => '<a href="' . tep_href_link(FILENAME_CONTACT_US) . '">' . BOX_INFORMATION_CONTACT . '</a><br>' . '<a href="' . tep_href_link(FILENAME_PRIVACY) . '">' . BOX_INFORMATION_PRIVACY . '</a><br>' . '<a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_RETURNS . '</a><br>' . '<a href="' . tep_href_link(FILENAME_SHIPPING) . '">' . BOX_INFORMATION_SHIPPING . '</a><br>' . '<a href="' . tep_href_link(FILENAME_SITE_MAP) . '">' . ALL_PRODUCTS_LINK . '</a>', 'params' => 'id="textInformation"'); new infoBox($info_box_contents); //create an instance of infoBox ?> </td></tr> <!-- information_eof //--> now, everywhere you see something written in all caps with underscores, rename it to something else. change BOX_HEADING_INFORMATION to BOX_HEADING_LINKS, and change FILENAME_PRIVACY to FILENAME_LINK_ONE, and BOX_INFORMATION_PRIVACY to BOX_LINKS_LINK_ONE. now you have to do step 4, which means open catalog/includes/languages/english.php and make sure each thing you changed in the previous step is defined. for example: define ('BOX_HEADING_LINKS', 'Links'); and define('FILENAME_LINK_ONE', 'www.linkone.com'); etc. this really is all laid out in the documentation.
erniethemilk Posted April 6, 2007 Author Posted April 6, 2007 Thanks rrrythmn :) I actually followed the documentation, so far I have a box, but not much else... I'll give it a shot, thanks for the help :) I'll no doubt be back :lmao:
Recommended Posts
Archived
This topic is now archived and is closed to further replies.