Guest Posted December 19, 2003 Posted December 19, 2003 Hey yall. Got a quick one here and it seems to be throwing me off bad. I would like to add my own content which appears when you enter the catalog. I use osc 2.2ms, and I am editing this particular file: /catalog/includes/languages/english/index.php and my modifications appear as the following: <?php define('TEXT_MAIN', ' blah blah blah '); -->lots of hypertext right here like tables, images, etc... <- define define define...etc ?> It fails to process what i've added and I'm not sure why. Maybe I am adding the html in the wrong spot? When I cut and paste it before the <?, it interprets it, but displays it at the top of the screen...same thing happens if i drop it below the closing ?>. any suggestions? tks. ..from the little php that i did give myself a lesson on, i remember there exists a command to print text exactly as it appears. all i can remember is "echo". is there some sort of command which enables us to write html in parenthesis so that it's interpreted correctly by a browser? that's all. TEGO
Guest Posted December 19, 2003 Posted December 19, 2003 You can simply close PHP prior to your HTML additions, using ?>, then reopen PHP when you have finished with your HTML, using <?php. NOTE: don't include the puctuation after the PHP open and close tags. :)
Guest Posted December 19, 2003 Posted December 19, 2003 In the languages files, you need to put all your changes inside the ' '. Also, be careful of contractions like Let's or can't. These need to be written Let\'s or can\'t so that it doesn't (doesn\'t) think that the string is finished. John D.'s instructions would work in files in the catalog directory, if you find yourself making changes there. However, if I am reading your post correctly, that is not what you are trying to do at the moment. If you continute to experience problems, see if you can reproduce the problem on a simpler page with just a line or two of code. Then you could copy and paste it into a code block here. The shorter the non-working code, the easier it will be to diagnose. Hth, Matt
241 Posted December 19, 2003 Posted December 19, 2003 you could also place your tables etc where you have blah,blah,blah define('TEXT_MAIN', ' blah blah blah '); like this define('TEXT_MAIN', ' your tables and hypertext here'); No longer giving free advice. Please place deposit in meter slot provided. Individual: [=] SME: [==] Corporation: [===] If deposit does not fit one of the slots provided then you are asking too much! Is your Osc dated try Phoenix raising oscommerce from the ashes.
Guest Posted December 19, 2003 Posted December 19, 2003 thanks yall. it turns out the following line was throwing back an error: background-image:url('http://www.gravitech.net/misc/images/container_small_middle.gif'); so i changed the single quotes to double quotes and it works fine. tks again. TEGO
Guest Posted December 19, 2003 Posted December 19, 2003 you can also add the background image url link into your stylesheet.css
Guest Posted December 19, 2003 Posted December 19, 2003 You know the easiest way to possibly to do this would be to open your index.php file in /catalog/ and replace the tag where it calls for the main text and replace that with your stuff you want there. That's all I did.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.