PHP, server settings or other?

Ask about general coding issues or problems here.

Moderators: egami, macek, gesf

Post Reply
hjortsberg
New php-forum User
New php-forum User
Posts: 5
Joined: Mon Oct 30, 2017 4:13 pm

Wed Dec 05, 2018 12:08 pm

I have just moved to a new provider, before I moved everything worked but after I moved some things does not work and I can not figure out what is wrong...

This is a piece of code that worked before I moved, the page is broken where this code is located, if I remove it the page works but I need the code:) The page works in all other aspects that I can think of.

I used PHP 5.6 at my old provider and thats why I moved, the new provider still supports 5.6, so the PHP version is the same.

Code: Select all

$query = "SELECT class FROM classes WHERE id = '" . $this->edit->id . "'";
   $db->setQuery($query);
   $db->query();
   $klassarray = $db->loadResultArray();
   
   $SF_array = array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10);
   $SIF_array = array(242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 256, 278, 280, 284, 285, 302, 303, 304, 305, 306, 307);
   $SS_array = array(11, 12, 240, 241, 255, 257, 279);
   $SH_array = array(286, 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, 301);
   $O_array = array(308);
   $L_array = array(29, 30, 31, 32, 283);
   $A_array = array(17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28);
   $R_array = array(13, 14, 15, 16);
   $B_array = array(258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277);
I cant find what's wrong:/
Can the error be HOW the code is read by the server? In that case, what differs? How do I fix it?

The logic tells me that it HAS to be server config, right?
Thanks in advance!

User avatar
hyper
php-forum Fan User
php-forum Fan User
Posts: 761
Joined: Mon Feb 22, 2016 5:52 pm

Wed Dec 05, 2018 3:57 pm

Have you contacted admin at your new provider? you might be able to revert to your older version while you sort out and update the differences.

PHP v5.6 has many sub changes. You should really be looking to upgrade to v7 while you are fixing the problems.

Your starting point will be the SQL or framework that you are using.

What framework are you using?

hjortsberg
New php-forum User
New php-forum User
Posts: 5
Joined: Mon Oct 30, 2017 4:13 pm

Thu Dec 06, 2018 5:27 am

Hi and thank you for the reply!

Unfortunatly I use Joomla 1.5:/

I have built a component that is BIG and my entire business lives on that component:/

I am currently trying to learn Laravel to be able to build a new website.

If I would try to upgrade the functions in my Joomla installation, do you have any suggestion so that I can buy me some time?

User avatar
hyper
php-forum Fan User
php-forum Fan User
Posts: 761
Joined: Mon Feb 22, 2016 5:52 pm

Thu Dec 06, 2018 11:45 am

I don't use it, have you tried a Joomla forum?

I'm sure that you are aware the version you are using reached its end of life 6 years ago?

Have you tried using the current version on a test machine?

Post Reply