Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Only wanted to change the text


slave2thebean

Recommended Posts

Hello:

 

I was changing the text on my site and now I am getting this error:

 

Parse error: parse error, unexpected T_STRING in /home/kankan/public_html/catalog/includes/languages/english/index.php on line 19

 

 

Once I got the error, I used my backup copy to put it back the way it was originally and I am still getting the same error. I don't have any white space anywhere. Can anyone please advise?

 

TIA,

Sarah

Link to comment
Share on other sites

I don't have any white space anywhere.

 

And no unescaped ' either?

 

quotes in the language files have to be escaped with a slash first, don't becomes don\'t.

Forum search

Contributions search

Documentation search (note: docs being adapted for MS3, may be different for MS2)

3 tips for better forum searching

 

Want to post? Read this first:

osCommerce for dummies

Topic name etiquette

 

Basics:

Basics for design

Right syntax to use near '-20, 20'

Cannot re-assign $this

Parse error

Link to comment
Share on other sites

Hello:

 

I was changing the text on my site and now I am getting this error:

 

Parse error: parse error, unexpected T_STRING in /home/kankan/public_html/catalog/includes/languages/english/index.php on line 19

Once I got the error, I used my backup copy to put it back the way it was originally and I am still getting the same error. I don't have any white space anywhere. Can anyone please advise?

 

TIA,

Sarah

Have you been using osCommerce's File Manager? If you have, there are probably other errors beyond line 19 as well.

 

Download/extract a fresh copy of catalog/includes/languages/english/index.php from http://www.oscommerce.com/solutions/downloads and start from there.

Link to comment
Share on other sites

Thank you both for answering- I was using the File Manager. I take it there is a problem with it? I've never used it before. I've always edited the code in my site's file manager.

 

I have done as you suggested and downloaded a fresh copy and changed the text again and still I'm getting this error:

 

Parse error: parse error, unexpected T_STRING in /home/kankan/public_html/catalog/includes/languages/english/index.php on line 12

 

 

Here is my code:

 

<?php
/*
 $Id: index.php,v 1.1 2003/06/11 17:38:00 hpdl Exp $

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2003 osCommerce

 Released under the GNU General Public License
*/

define('TEXT_MAIN', 'Please note that orders placed between Thursday 24th March and Thursday 31th March won?t ship until Saturday 2nd April. This is what you've all been after! The KanKan store is finally here! Here's what we offer in our catalog:<br><br><b>JustaKan</b>: no paint inside, no rust outside. If this is your first Kan , we suggest starting on the 1 litre or smaller, but by all means get more than one because you're not going to be able to stop making them once you start!<br><br><b>Kan Kits</b>:  Not everyone feels they are creative enough to alter a Kan from scratch, and that's OK! It's why we have come up with KanKits. These limited edition kits provide everything you need in order to put together a themed Kan. Many have been created exclusively for KanKan by some of the most well-known names in the Scrapbooking industry and only a limited number will be available. Ever. So? get them while you can because they're going to be snapped up!<br><br><b>Kan Kontents</b>: So, you've got your JustaKan or KanKit in your basket ready to go. But what are you going to put in it? We have organised these by theme and product, so be inspired or go for what you want. And of course, if you have ideas about things you would like to see available, get in touch.<br><br><b>Kan Kling</b>: If you're a die-hard scrapbooker, you'll probably have most of this already. But if you're not, then it's important that you use products with suitable stick-power to adhere your paper, cardstock and embellishments.<br><br>Thank you for visiting KanKan.co.uk. If we can be of assistance, please feel free to contact us.');
define('TABLE_HEADING_NEW_PRODUCTS', 'New Products For %s');
define('TABLE_HEADING_UPCOMING_PRODUCTS', 'Upcoming Products');
define('TABLE_HEADING_DATE_EXPECTED', 'Date Expected');

if ( ($category_depth == 'products') || (isset($HTTP_GET_VARS['manufacturers_id'])) ) {
 define('HEADING_TITLE', 'Let\'s See What We Have Here');
 define('TABLE_HEADING_IMAGE', '');
 define('TABLE_HEADING_MODEL', 'Model');
 define('TABLE_HEADING_PRODUCTS', 'Product Name');
 define('TABLE_HEADING_MANUFACTURER', 'Manufacturer');
 define('TABLE_HEADING_QUANTITY', 'Quantity');
 define('TABLE_HEADING_PRICE', 'Price');
 define('TABLE_HEADING_WEIGHT', 'Weight');
 define('TABLE_HEADING_BUY_NOW', 'Buy Now');
 define('TEXT_NO_PRODUCTS', 'There are no products to list in this category.');
 define('TEXT_NO_PRODUCTS2', 'There is no product available from this manufacturer.');
 define('TEXT_NUMBER_OF_PRODUCTS', 'Number of Products: ');
 define('TEXT_SHOW', '<b>Show:</b>');
 define('TEXT_BUY', 'Buy 1 \'');
 define('TEXT_NOW', '\' now');
 define('TEXT_ALL_CATEGORIES', 'All Categories');
 define('TEXT_ALL_MANUFACTURERS', 'All Manufacturers');
} elseif ($category_depth == 'top') {
 define('HEADING_TITLE', 'What\'s New Here?');
} elseif ($category_depth == 'nested') {
 define('HEADING_TITLE', 'Categories');
}
?>

 

Do you see anything that could be causing this problem? I've looked and looked and just don't see anything wrong.

 

Thanks again for any help,

Sarah

Link to comment
Share on other sites

At a quick glance, I see at least one place where you haven't escaped a single quote. change:

 

Thursday 31th March won?t ship

 

to

 

Thursday 31th March won\?t ship

 

There may be more like it in there -- didn't go past the first instance.

 

HTH,

 

Terry

Terry Kluytmans

 

Contribs Installed: Purchase Without Account (PWA); Big Images, Product Availability, Description in Product Listing, Graphical Infobox, Header Tags Controller, Login Box, Option Type Feature, plus many layout changes & other mods of my own, like:

 

Add order total to checkout_shipment

Add order total to checkout_payment

Add radio buttons at checkout_shipping (for backorder options, etc.)

Duplicate Table Rate Shipping Module

Better Product Review Flow

 

* If at first you don't succeed, find out if there's a prize for the loser. *

Link to comment
Share on other sites

Thank you so much for your help! It took some very close inspection but that did the trick. Interestingly, I had text up there before and I never used the / on ' and I had no problems. Weird.

 

Thanks to all that helped!

 

Sarah

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...