PHP script error Warning: include_once...: failed to open stream:

I have a friend that moved from one host to another, and basically just copied their directories over without regard to structure.  I'm not saavy with the PHP/MYSQL/CPanel stuff, but I can tell the problem is that the scripts are pointing in the wrong direction:

Warning: include_once(include/core.php) [function.include-once]: failed to open stream: No such file or directory in /home/sandiega/public_html/register.php  on line 2

Warning: include_once() [function.include]: Failed opening 'include/core.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/sandiega/public_html/register.php on line 2

Warning: include_once(include/db.php) [function.include-once]: failed to open stream: No such file or directory in /home/sandiega/public_html/register.php on line 3

Warning: include_once() [function.include]: Failed opening 'include/db.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/sandiega/public_html/register.php on line 3

I don't have admin access to the new host server, just the Cpanel admin console.  Is their a way to fix this via the Cpanel?  Or, do the scripts need to be recoded?  I don't think the host has tech support with this type of knowledge, as my friend has not been able to get this corrected with them, and he doesn't know what PHP platform he was on before (if that makes a difference).
kgiitAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Chris StanyonWebDevCommented:
You need to make sure that the public_html folder has a subfolder called 'include' and that the core.php is inside that.

If it still doesn't work, you may need to add the following line at the start of your script.

set_include_path('/include');


0
kgiitAuthor Commented:

Chris,

The script has the '/include' path in it, but there is no include folder anywhere in the directory tree.  I don't know if it was overwritten, deleted, or whether the server admin has to open the path to it.  He may not have copied all of the files that he needed, just those he thought were relevant to the site itself.  Which is what I'm afraid is the problem.

thanks for your reply.
0
tdotCommented:
open your cpanel a click on file manager look for your include folder.
0
Protecting & Securing Your Critical Data

Considering 93 percent of companies file for bankruptcy within 12 months of a disaster that blocked access to their data for 10 days or more, planning for the worst is just smart business. Learn how Acronis Backup integrates security at every stage

tdotCommented:
If its not there it was not transfered
0
kgiitAuthor Commented:

Hi tdot,

I went through all of the directories, did a search with the CPanel, and didn't find /includes or the missing files.  He doesn't have access to the old host files anymore.  Is there a way to replace?  Or, is it a recoding fix?

thanks
0
tdotCommented:
Hi, kgiit

If you no longer have access to the old files and no backups you will have to recode.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
tdotCommented:
Hi, kgiit

There is nothing more we can do can you please close the question..
0
kgiitAuthor Commented:

Question answered.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
PHP

From novice to tech pro — start learning today.