Jump to content

[Resolved] URGENT! Admin page blank


Recommended Posts

My bad:

From:
echo realpath(dirname(__FILE__)."<br/>";

To:
echo realpath(dirname(__FILE__))."<br/>";

My programmer's editor is configured to not auto-complete delimiters. Thus, sometimes I forget to match opening and closing parens.

Link to comment
Share on other sites

test1test3test4template: login.php
template_directories: Array ( [0] => /var/sites/s/shop.whitbygothweekend.co.uk/public_html/admin_XXXXXX/skins/default/ )
/var/sites/s/shop.whitbygothweekend.co.uk/public_html
/var/sites/s/shop.whitbygothweekend.co.uk/public_html

Link to comment
Share on other sites

Nothing from the try/catch??? How unfortunate.

Well, this script has determined that it is sitting in /public_html/. But you say otherwise. But the error_log (re: tcp wrapper) says this so.

Are you sure you are not in /public_html/?

Link to comment
Share on other sites

I see this, but please examine your Cpanel "Subdomains". I think the "shop" subdomain should have a Document Root of:

<house icon>/shop

where <house icon> is your "home directory" (as seen somewhere in Cpanel's General Information).

 

Link to comment
Share on other sites

It isn't a Cpanel account. This is a screenshot of the subdomains page of control panel.

However I can't see how any paths can have changed; I haven't changed them, and TSO Host have confirmed that there haven't been any configuration changes in the last week.

 

subdomains.png

Link to comment
Share on other sites

I have not seen this control panel, so excuse the stupid questions.

The Home Directory column shows a simple name (newshop, shop, etc), but how does the folder /subdomains/ come into play? Is this just "understood"? That is, when a subdomain is created, this control panel automatically creates the folder and automatically puts it in /subdomains/?

Well, the storefront seems to work -- so the above line of questioning is irrelevant.

So, making wild guesses:

Is there anything suspicious in the "shop" site's .htaccess file?

Anything suspicious in the site's globals.inc.php file?

Does the term "DYNSRV" mean anything?

 

Link to comment
Share on other sites

Yes, the control panel automatically creates a new folder in subdomains.

.htaccess is the same for the live shop and development shop.

global.inc.php looks OK, adminFile and adminFolder are both correct, as are the DB details (but the storefront wouldn't work if the DB details were wrong).

I am beginning to think I need to pay for a month of CC support and let them sort this out. It is all getting way beyond my skill level!

Link to comment
Share on other sites

I noticed that there is an /admin/ folder, as well as an /admin_xxxxx/ folder. But I can't conclude that this would matter.

We need to find out where the /public_html/ is coming from when real_path() is executed.

In the admin script:

Find:

## Include the ini file (required)
require 'ini.inc.php';

Change to:

echo "Filename: ".__FILE__."<br/>";
echo "Directory: ".dirname(__FILE__)."<br/>";
echo "Path: ".realpath(dirname(__FILE__))."<br/>";

## Include the ini file (required)
require 'ini.inc.php';

This is before CubeCart does anything. The filename should be what is expected, so too the directory.

Put this in the index.php script as well. For just long enough for you to see what it shows.

Link to comment
Share on other sites

Output from admin script:-

Filename: /var/sites/s/shop.whitbygothweekend.co.uk/public_html/admin_XXXXXX.php
Directory: /var/sites/s/shop.whitbygothweekend.co.uk/public_html
Path: /var/sites/s/shop.whitbygothweekend.co.uk/public_html

Warning: ini_set(): Cannot change zlib.output_compression - headers already sent in /var/sites/s/shop.whitbygothweekend.co.uk/public_html/ini.inc.php on line 34

Warning: session_start() [function.session-start.php]: Cannot send session cache limiter - headers already sent (output started at /var/sites/s/shop.whitbygothweekend.co.uk/public_html/admin_XXXXXXX.php:20) in /var/sites/s/shop.whitbygothweekend.co.uk/public_html/classes/session.class.php on line 640

Warning: Cannot modify header information - headers already sent by (output started at /var/sites/s/shop.whitbygothweekend.co.uk/public_html/admin_XXXXXXX.php:20) in /var/sites/s/shop.whitbygothweekend.co.uk/public_html/classes/session.class.php on line 535
test1test3test4template: login.php
template_directories: Array ( [0] => /var/sites/s/shop.whitbygothweekend.co.uk/public_html/admin_XXXXX/skins/default/ )
/var/sites/s/shop.whitbygothweekend.co.uk/public_html
/var/sites/s/shop.whitbygothweekend.co.uk/public_html

output from index.php

Filename: /var/sites/s/shop.whitbygothweekend.co.uk/public_html/index.php
Directory: /var/sites/s/shop.whitbygothweekend.co.uk/public_html
Path: /var/sites/s/shop.whitbygothweekend.co.uk/public_html

 

Link to comment
Share on other sites

Output from admin script:-
 

Filename: /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html/admin_ZZZZZZ.php
Directory: /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html
Path: /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html

Warning: ini_set(): Cannot change zlib.output_compression - headers already sent in /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html/ini.inc.php on line 30

output from index.php

Filename: /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html/index.php
Directory: /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html
Path: /var/sites/c/ccdev.whitbygothweekend.co.uk/public_html

I am wondering if the directory name I see from Filezilla (subdomains/shop), is an alias for shop.whitbygothweekend.co.uk/public_html.

Link to comment
Share on other sites

FileZilla likely won't show it, but your hosting control panel File Manager should have some sort of indication on the folder contents pane (not the folder tree pane) about what might be redirects.

Still, between the two shops, these reports indicate everything but the named specifics are the same.

Did we get any "tcp wrapper" resolution?

 

Link to comment
Share on other sites

I'VE FIXED IT!!!!!

I tried some pretty extreme experimentation to try to narrow it down. First of all I pointed the working development installation to the live DB by editing global.inc.php, and I was able to access the control panel, proving my DB is OK.

I was then going to back up the live shop file structure to my PC and copy the development file system to the non-working shop, however I got an error when downloading the admin_XXXX folder. Turns out it was corrupt, and when Windows got hold of it, it didn't recognise it as a folder; it thought it was a file. I copied the admin_ZZZZZ folder from the working development store, renamed it and bingo, I'm in.

Thanks for all your efforts today Brian. I know that your suggestions didn't solve it, but it eliminated an awful lot of stuff, and I have learnt loads about php/CubeCart.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...