But during upgrade came message
SyntaxError: Unexpected token < in JSON at position 0 OK Warning: mysqli_select_db() expects parameter 1 to be mysqli, string given in /customers/d/e/c/jordalblomster.no/httpd.www/shop1/system/library/db/mysql.php on line 12
In my file mysql.php in mentioned lines I see as below
<?php
namespace DB;
final class MySQL {
private $connection;
public function __construct($hostname, $username, $password, $database, $port = '3306') {
if (!$this->connection = mysqli_connect($hostname . ':' . $port, $username, $password)) {
trigger_error('Error: Could not make a database link using ' . $username . '@' . $hostname);
exit();
}
if (!mysqli_select_db($database, $this->connection)) {
throw new \Exception ('Error: Could not connect to database ' . $database);
}
mysqli_query("SET NAMES 'utf8'", $this->connection);
mysqli_query("SET CHARACTER SET utf8", $this->connection);
mysqli_query("SET CHARACTER_SET_CONNECTION=utf8", $this->connection);
mysqli_query("SET SQL_MODE = ''", $this->connection);
+++++++++++++
What shall I correct?
I already chnaged in words mysql to mysqli
Thanks in advance for help
by attempting to UPGRADE something, where absolutely NOTHING of the old Version
Code can be used, not even the Database, as it exists by default.
Ernie
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
How to proceed if my proivider changed php to 7,2 and my opencart quite old
With 5.6 version the shoip was working well.. Now not at all.
Do I need to upgrade the shop to 3xxx?
Can I stay with old version of opencart but make it working with new php7,2?
To create the shop again from scratch will be disaster
But I just tested the encryption.php File, placed into an OC v.1.5.3.1 in an
old OC Localhost Environment, by use of this PHP7-compatible
system/library/encryption.php File, and the only Error I got was an email-related
problem, since I have nothing configured, to allow eMails to be sent from this localhost/PC
environment. But otherwise, I found nothing else, keeping the Shop from running, during
my 3 minute test...
But I did NOT test it under PHP-7, so, I cannot really tell, if it only requires this File, to
be replaced, or if other matters will keep an 1.5.4 Version from further doing it's Job !
Also make sure, to also have the bcrypt.php file placed in the same Directory
system/library/bcrypt.php, since some functions or Mods might look for it.
I also added a few other encryption.php Files into the ZIP, you might need another one,
but so, you at least have some choice ..
---
But possibly, you also use some Extensions/Modules, and some of them might refuse
to further function. Just to have this mentioned too.
Good Luck, that's all I can do for you.
Ernie
---
PS: NOT ALL of those Files have been tested in my Software, so,
better also check around in the OC Forum, to get some comments on
some of them, which I am not able to 'judge' on.
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
As soon as I switch to 5.6 everything OK.
But 5.6 to be removed by my provider on 03 of december...
With 7.2 comming following error.
+++++++++++
Fatal error: Uncaught Error: Call to undefined function mysql_connect() in /customers/d/e/c/jordalblomster.no/httpd.www/shop/system/database/mysql.php:11 Stack trace: #0 /customers/d/e/c/jordalblomster.no/httpd.www/shop/system/library/db.php(12): MySQL->__construct('jordalblomster....', 'jordalblomster_', 'Oxxxxxxxxxxxxx...', 'jordalblomster_') #1 /customers/d/e/c/jordalblomster.no/httpd.www/shop/index.php(38): DB->__construct('mysql', 'jordalblomster....', 'jordalblomster_', 'Oxxxxxxxxxxx...', 'jordalblomster_') #2 {main} thrown in /customers/d/e/c/jordalblomster.no/httpd.www/shop/system/database/mysql.php on line 11
+++++++++++++++
( i just retyped my password with xxxx...)
Any advice ? Of course I f I can run 1.5.4 with 7.2 PHP I do not need to upgrade OC and stay with 1.5.4
Will appreciate any help... just few days remain to fix this issue.
Thanks in advance!
https://www.opencart.com/index.php?rout ... rch=mysqli
Ernie
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Still, you should consider to at least some day move up to the latest
OC v.1.5.x Version, and I will have a 'virgin' OC v.2.0.x Code multi-themed
1.5.6.5(_rc2 ) Version ready by the end of November, which could be used,
to test it with existing Themes/Mod's, required to still function as they did
before. Or then, download the official 'stock/default' 1.5.6.5_rc Version,
if your shop already uses a responsive Custom Theme, which you need to
keep.
https://github.com/myopencart/opencart/tree/v1.5.6.x
Then, you only have to download VqMod for OpenCart:
v2.6.1-opencart - anything above is mostly OcMod related/adaption Code
and so possibly only of value by use of PEKU's 1.5.6.5 EDGE as OcMod-Version.
https://github.com/vqmod/vqmod/releases ... 1-opencart
https://github.com/vqmod/vqmod/wiki
to start work!
Let me know by PM, if you like to play Tester ...
http://www.gratisangebote.ch
Good Luck !
Ernie
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Only problem as I can see I cannot use template anymore and have to buy new template?
Otherwise I can upgrade as you say to latest 1.5.6 and 2.0?
Or can follow your advice and be your tester
I was playing with my site now and realised SEARCH box not working .When I put anything into search box coming another screen with error...
www.jordalblomster.no is currently unable to handle this request.
HTTP ERROR 500
In error log I see as below
++++++
2018-11-25 20:00:36 - PHP Notice: Undefined variable: languages in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:00:36 - PHP Warning: count(): Parameter must be an array or an object that implements Countable in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:01:29 - PHP Notice: Undefined variable: languages in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:01:29 - PHP Warning: count(): Parameter must be an array or an object that implements Countable in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:01:47 - PHP Notice: Undefined variable: languages in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:01:47 - PHP Warning: count(): Parameter must be an array or an object that implements Countable in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:01:49 - PHP Notice: Undefined variable: languages in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
2018-11-25 20:01:49 - PHP Warning: count(): Parameter must be an array or an object that implements Countable in /customers/d/e/c/jordalblomster.no/httpd.www/shop/catalog/view/theme/OPC020046/template/common/header.tpl on line 52
Rest looks like working well.. including mail system etc.
Is this also related to PHP 7.2?
Thanks and best regards,
Sergiy
you could possibly contact the Theme Designer, to get some solution on this,
I am not familiar with this theme.
But If you only use one Language, you could 'Admin-disable' the english Language
to be selectable on the Front Side. And/or manually remove the LANGUAGE related
line/s in the theme header.tpl file as Quick-Fix-Solution for this.
Code: Select all
<?php echo $language; ?>
I have made several postings regarding later Versions, and some of them might
no longer exist , since not everybody likes that kind of 'publicity'...
But generally, there was no V-2 'quasi-final' Version anymore, which could be
taxed as 'TOP V2', since the v.2.3.x is already more a v.3 Prototype than a v 2. ...
In contrary to the 1.5.6.5_rc. And all of those Version Numbers get 'archived'
for good, after a (Sub-) Version Number 'upgrades' , and will so remain,
without beeing fixed, even if some misses or faults will be found later on. And
this will force installers, to find out first, and this is not really the most efficient way,
to get something done, as I assume ...
In contrary to 1.5.6.5_rc, which is actually nothing, but a 'final-fixed' 1.5.6.4, which
already was a well-done Version, and based on a solid development, as we all know.
It just collided 'time-wise' with the long awaited v.2.x, released a couple of months
earlier, and 1.5.x was therefore no longer of interest to OC itself ...
But it's still an official part of the OC Family, just no longer 'shown' in the open:
https://github.com/IP-CAM/Opencart-1.5.6.5_rc
---
So, one better keeps, what is known to function, and some day, OC will have a 'final'
again, or someone will create one, like some Russians are doing it. Unfortunately,
they do some things in their own way, don't have all 'default' OC Payments, e.t.c., and
don't translate their Versions in native english either in full, otherwise, one could use
one of them.
But my release will include a couple of nice Themes, so, at least for that one, you won't
have to worry about your existing one. But they don't match your 1.5.4 either, just to
mention this, it's all standard 'OC-2 tech-type' Bootstrap Design, based on famous PEKU's
great "V2Theme to 1.5" Extension Development.
https://www.opencart.com/index.php?rout ... ember=peku
https://github.com/pekka2
Ernie
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Vielen Dank für die Links, sie sind wirklich hilfreich
Reason: removed hidden link
dem ständig steigenden Haufen von technischen Doppel-Nullen, und mit
einem Klima, welches sowieso fast nur noch Erkältungen generiert.
Und nicht mal mehr Smilies und Links funzen hier noch seit Neustem, aber
auch Solches passt ja zu Anderen,was länger schon nur noch halbwegs taugt.
Viel Glück !
Ernie
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
/Dan
went wrong. You therefore have to check in the Server Site Admin Logs, what
kind of error this is. It's possible, that some extension is no longer able to handle
PHP v.7.2x, since, under 'normal' Conditions, the Admin Section should further
function.
Ernie
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
Users browsing this forum: Amazon [Bot] and 130 guests