Samet Chan

Well-Known Member
Jun 24, 2016
369
42
153
cPanel Access Level
Root Administrator
Twitter
Dear,

Folder "inc" and "class" they are weak security, It's still working on a website running up.

But I have moved to new folder /library/database/ & /library/AXS/ANYPHP.php are not working for PHP 7.0 is not running up. It's two folders. Getting error again.

Code:
####################### START - PHP #######################
require_once ("../library/AXS/ANYPHP.php");
if(isset($_SESSION["user_zero"])){
$us = new Usersin();
$user=$us->ui($_SESSION["user_zero"]);
}
Warning: include(): Failed opening '../library/AXS/ANYPHP.php' for inclusion (include_path='.:/opt/cpanel/ea-php70/root/usr/share/pear') in /home/HIDDEN/public_html/library/AXS/EP.php on line 3
 

Samet Chan

Well-Known Member
Jun 24, 2016
369
42
153
cPanel Access Level
Root Administrator
Twitter
Do these folders works the way
Yes. The folder was correct. I moved to folder more security. I don't want to say public of my folder on this thread. I'll PM you.

I have to edit all PHP Script here,
Before OLD
Code:
require_once ("../inc/class.php");
if(isset($_SESSION["user_zero"])){
$us = new Usersin();
$user=$us->ui($_SESSION["user_zero"]);
}
After changed to new PHP here,

Code:
require_once ("../library/AXS/ANYPHP.php");
if(isset($_SESSION["user_zero"])){
$us = new Usersin();
$user=$us->ui($_SESSION["user_zero"]);
}
It's two created folders. Then I got an error.

you want on different PHP versions? Have you checked it?
I prefer PHP 7.0 more than 5.6 is an old end of life support in 2018. Almost one year later. PHP 7.0 is working fine all PHP Script before. One bug after issue "require_once ("../library/AXS/ANYPHP.php");"
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,256
463
Hello,

This looks like more of an issue with the code of the PHP script as opposed to how PHP is offered in EasyApache 4. I recommend posting to a website such as StackOverflow for help with the PHP code.

Thank you.
 

Samet Chan

Well-Known Member
Jun 24, 2016
369
42
153
cPanel Access Level
Root Administrator
Twitter
Hello,

This looks like more of an issue with the code of the PHP script as opposed to how PHP is offered in EasyApache 4. I recommend posting to a website such as StackOverflow for help with the PHP code.

Thank you.
Have you posted from StackOverflow? Or I have to make a new topic?

You can read more topic: "PHP - Failed to open stream : No such file or directory"

I followed that. Still, doesn't work. I created two folders. It's problem error again. Before old "One folder for inc or class are weak security" It's working fine. I changed did to new two folders keep error.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,256
463
Hello,

You may want to review the "5. Check PHP settings" section in the top comment from the link you provided and verify if those settings are the culprit. This type of issue often relates to the PHP code you are using, so you may also want to consult with a qualified system administrator:

System Administration Services | cPanel Forums

Thank you.
 

Samet Chan

Well-Known Member
Jun 24, 2016
369
42
153
cPanel Access Level
Root Administrator
Twitter
Hello,

You may want to review the "5. Check PHP settings" section in the top comment from the link you provided and verify if those settings are the culprit. This type of issue often relates to the PHP code you are using, so you may also want to consult with a qualified system administrator:

System Administration Services | cPanel Forums

Thank you.
I'm little confused, I don't understand. What do you mean 5.6 for PHP version right?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,256
463

Samet Chan

Well-Known Member
Jun 24, 2016
369
42
153
cPanel Access Level
Root Administrator
Twitter
For instance, you can browse to the URL you referenced at:

PHP - Failed to open stream : No such file or directory

Scroll down the page until you see the section titled "5. Check PHP settings" in bold and verify if those settings are related to your issue.

Thank you.
Oh, I have enabled open_basedir protection & allow_url_fopen from MultiPHP INI Editor.

I never enable safe mode. It's off safe.

allow_url_include is now enabled. I checked AXS still error up. :eek: again!
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,256
463
It's likely an issue with your PHP coding, and that's outside the scope of support we can offer. However, feel free to open a support ticket using the link in my signature and we can take a closer look to rule out any issues with the PHP configuration.

Thank you.
 

Samet Chan

Well-Known Member
Jun 24, 2016
369
42
153
cPanel Access Level
Root Administrator
Twitter
@cPanelMichael, Solved problem now. :)

@cPTravis solved MariaDB can now add anime and episode list. But they cannot edit successfully as well. I will ask my friend developer to take look later.

Travis Holloway
Hello,

You mentioned that you upgraded to MariaDB 10.2 earlier in this ticket. MariaDB 10.2 enables 'STRICT_TRANS_TABLES' by default which can cause this issue if the queries that you are using to insert new videos/images/etc into your database are not following strict standards:

=====
[15:24:19 [email protected]~]cPs# mysql -e "SELECT @@GLOBAL.sql_mode;"
+-------------------------------------------------------------------------------------------+
| @@GLOBAL.sql_mode |
+-------------------------------------------------------------------------------------------+
| STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION |
+-------------------------------------------------------------------------------------------+
[15:25:16 [email protected]~]cPs#
=====

Can you try to disabling strict standards and let me know if this resolves this issue for you? To disable strict standards, add the following line to '/etc/my.cnf' and restart mysql:

=====
sql_mode=ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
=====




Sincerely,

--
Travis Holloway
Linux Technical Analyst
cPanel, Inc

Join us for the 2017 cPanel Conference!
Sept. 26th & 27th in Fort Lauderdale, Fl.
cPanel Conference | cPanel & WHM
 
Last edited by a moderator:
  • Like
Reactions: cPanelMichael