Solved

Move php website from dedicated to shared hosted on godaddy

Posted on 2011-02-26
7
957 Views
Last Modified: 2012-05-11
I have a working site on a dedicated hosted linux box.
www.flattentheworld.com
I copied it to a godaddy shared hosted linux box.
This is the error I get.

      Warning: require_once(/var/chroot/home/content/16/7001316/html/main.php) [function.require-once]: failed to open stream: No such file or directory in /home/content/16/7001316/html/accessioncorp/config.php on line 3

      Fatal error: require_once() [function.require]: Failed opening required '/var/chroot/home/content/16/7001316/html/main.php' (include_path='.:/usr/local/php5/lib/php') in /home/content/16/7001316/html/accessioncorp/config.php on line 3

I'm not a PHP programmer but I'm hoping to be able to move this site to the new host.
Am I even close? What can I do to make this work?


first two lines of index.php
<?php
require_once('config.php');



The config.php file
<?php
// the orginal line follows
// require_once('SystemLib/main.php');
// this is what I tried but I still get the above error.
require_once($_SERVER['DOCUMENT_ROOT']).'/main.php';

require_once('Smarty/Smarty.class.php');

define('ORDER_EMAIL_ADDRESS', 'tobyd@softdesigns.com');

define('ACS_ANY',      0);
define('ACS_USER',      128);
define('ACS_ADMIN',      255);

require_once('config_local.php');
require_once('config_pages.php');

require_once('class.User.php');

#require_once('Admin.php');
#require_once('User.php');
#require_once('Order.php');
#require_once('Home.php');

?>
0
Comment
Question by:davidpm
  • 3
  • 3
7 Comments
 
LVL 4

Expert Comment

by:florjan
ID: 34987424
Have you tried chmoding files to 755?
0
 
LVL 4

Expert Comment

by:TTauri
ID: 34987456
Does this file actually exist at this path?
/var/chroot/home/content/16/7001316/html/main.php

The config file is in a slightly different place:
/home/content/16/7001316/html/accessioncorp/config.php
0
 

Author Comment

by:davidpm
ID: 34987507
Since this is a shared godaddy host I donn't belive I can go poking around on the server.
They do say on the control panel that the absolute hosting path is: /home/content/16/7001316/html

I'm assuming that main.php exists someplace as wordpress works on this host.

The 777 thing I donn't know what to do since I am limited to the hosting path.
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 4

Expert Comment

by:florjan
ID: 34987553
On the hosting panel you should have fix file permissions or something simular. If you don't you can change permissions via file manager from panel or via ftp
0
 

Author Comment

by:davidpm
ID: 34988814
Donn't mean to argue as I'm the one asking for help but what makes you think it is a permission problem?
If it is a permission problem for main.php I'm not going to have access to it as it is considered a shared system file, yes?

If it was a permission problem on config.php which I can get to would it open. It seems like it is opening as it finds the line number to error on.
0
 
LVL 4

Accepted Solution

by:
florjan earned 500 total points
ID: 34988863
http://www.flattentheworld.com/main.php
This is where main.php should be right? It returns 404 which either means that it doesn't exsist or isn't word readable (or it has a redirect unless some criteria is met).
Also can you put
echo $_SERVER['DOCUMENT_ROOT'];

Open in new window

after <?php and tell the output?
0
 

Author Closing Comment

by:davidpm
ID: 34989629
Thanks for the nudge. I examined the source computer and found a directory under /user/share/includes/SystemLib with the files referenced in the include.
I copied them to an includes folder I created under accessioncorp and adjusted the include path and it works now.
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Join & Write a Comment

HOW TO: Upload an ISO image to a VMware datastore for use with VMware vSphere Hypervisor 6.5 (ESXi 6.5) using the vSphere Host Client, and checking its MD5 checksum signature is correct.  It's a good idea to compare checksums, because many installat…
Veeam Backup & Replication has added a new integration – Veeam Backup for Microsoft Office 365.  In this blog, we will discuss how you can benefit from Office 365 email backup with the Veeam’s new product and try to shed some light on the needs and …
Teach the user how to use vSphere Update Manager to update the VMware Tools and virtual machine hardware version Open vSphere Client: Review manual processes for updating VMware Tools and virtual hardware versions: Create a new baseline group in vSp…
This tutorial will walk an individual through the steps necessary to enable the VMware\Hyper-V licensed feature of Backup Exec 2012. In addition, how to add a VMware server and configure a backup job. The first step is to acquire the necessary licen…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now