zefeena Posted March 26, 2015 Posted March 26, 2015 Hi, I am trying to update from 2.3.3.2 to 2.3.3.3 and I am now getting an error: Parse error: syntax error, unexpected T_STRING, expecting ')' in /home/bramaker/public_html/catalog/includes/functions/database.php on line 14 I was very unsure when I was updating the database file. The instruction is: after the mysqli_connect() function (defined around line 178), add: function mysqli_connect_errno($link = null) { return mysql_errno($link); } function mysqli_connect_error($link = null) { return mysql_error($link); } function mysqli_set_charset($link, $charset) { if ( function_exists('mysql_set_charset') ) { return mysql_set_charset($charset, $link); } } Below is part of my database file. I inserted the info above where there is a blank space (now removed as it was obviously the wrong place) Can anyone advise the exact place I should be putting it? Totally offline now until I figure it out - or rather someone else does as i'm clueless! Thank you return mysqli_get_server_info($$link); } if ( !function_exists('mysqli_connect') ) { define('MYSQLI_ASSOC', MYSQL_ASSOC); function mysqli_connect($server, $username, $password, $database) { if ( substr($server, 0, 2) == 'p:' ) { $link = mysql_pconnect(substr($server, 2), $username, $password); } else { $link = mysql_connect($server, $username, $password); } if ( $link ) { mysql_select_db($database, $link); } return $link; } function mysqli_close($link) { return mysql_close($link); } function mysqli_query($link, $query) { Running a botched up version of osCommerce Online Merchant v2.3.4 bootstrap with the dresscode theme installed, numerous add-ons, terrible coding, terrible website, but will have to make do until I have made up for my losses and can risk shutting down for a couple of weeks while I start all over again. - I did not install my program but am endeavouring to fix it with your help.
Mort-lemur Posted March 26, 2015 Posted March 26, 2015 @@zefeena rename the database file to database.phpORIG Download and install the database.php file from the 2.3.3 package - see if that resolve the problem. If so then copy over any custom code from your original database.php Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.
zefeena Posted March 26, 2015 Author Posted March 26, 2015 Hi, That sort of worked! I had to do the same with the 'whos-online' files. The website sees to be back up, but I cannot get onto the admin side, i'm now getting a blank page with: Parse error: syntax error, unexpected T_STRING, expecting ',' or ')' in /home/bramaker/public_html/catalog/admin/login.php on line 29 I'm pretty sure I never edited that file! Running a botched up version of osCommerce Online Merchant v2.3.4 bootstrap with the dresscode theme installed, numerous add-ons, terrible coding, terrible website, but will have to make do until I have made up for my losses and can risk shutting down for a couple of weeks while I start all over again. - I did not install my program but am endeavouring to fix it with your help.
zefeena Posted March 26, 2015 Author Posted March 26, 2015 Apparently I had changed it. That trick with the changing file names is really great. Think i'm back to normal now, only two more updates to go!!! Thank you so much Running a botched up version of osCommerce Online Merchant v2.3.4 bootstrap with the dresscode theme installed, numerous add-ons, terrible coding, terrible website, but will have to make do until I have made up for my losses and can risk shutting down for a couple of weeks while I start all over again. - I did not install my program but am endeavouring to fix it with your help.
Mort-lemur Posted March 26, 2015 Posted March 26, 2015 @@zefeena my pleasure, that method gives you a quick way of reverting back if needs be - It has got me out of trouble several times, as I also use it when modifying files, that way I always have a copy of the original if things go wrong.... Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.
zefeena Posted March 26, 2015 Author Posted March 26, 2015 On another note, since the update everthing seems to be okay (closed the checkout, so cannot be certain), but I have got a strange symbol now before every £ sign - like this £6.99 Any idea why that may have happened. I am presuming it will be a language file, but despite only doing English, there are still so many! Running a botched up version of osCommerce Online Merchant v2.3.4 bootstrap with the dresscode theme installed, numerous add-ons, terrible coding, terrible website, but will have to make do until I have made up for my losses and can risk shutting down for a couple of weeks while I start all over again. - I did not install my program but am endeavouring to fix it with your help.
Mort-lemur Posted March 26, 2015 Posted March 26, 2015 @@zefeena That is something to do with the database tables being in the wrong format (should be utf8) check them in admin/tools/database tables and convert to utf8 if necessary. when I transferred my datatabase to a new 2.3.4 install I had the same issue and as I recall had to manually re-enter a few prices or take a look at the answers to this thread: http://www.oscommerce.com/forums/topic/390801-few-questions-from-osc-newbie/ Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.
MrPhil Posted March 26, 2015 Posted March 26, 2015 The "funny" currency is a Pound Sterling in multibyte UTF-8 encoding, but one of two things happened. Your pages are being displayed in a single byte encoding such as Latin-1 or Windows-1252, and Pound thus shows as two characters, OR You imported a backup of your database, but neglected to tell phpMyAdmin that the backup was in UTF-8 format. The default is to assume the backup file is Latin-1, so the two "Latin-1" characters in each Pound were converted into two multibyte UTF-8 characters (now 4 bytes instead of 2). If you now have a mixture of proper Pound signs and the messed up ones, all you can do is manually edit the database to fix each instance.
zefeena Posted March 26, 2015 Author Posted March 26, 2015 I actually went into the admin panel and under Localisation/Currencies. It looked, as below- I just edited and removed the  and it worked! Hopefully that was not the wrong thing to do! Title: Pounds Sterling Code: GBP Symbol Left: £ Symbol Right: Running a botched up version of osCommerce Online Merchant v2.3.4 bootstrap with the dresscode theme installed, numerous add-ons, terrible coding, terrible website, but will have to make do until I have made up for my losses and can risk shutting down for a couple of weeks while I start all over again. - I did not install my program but am endeavouring to fix it with your help.
irishguy9 Posted March 27, 2015 Posted March 27, 2015 Did you check your database tables to make sure they all are in UTF-8?
Recommended Posts
Archived
This topic is now archived and is closed to further replies.