Forums / Addon Sideboxes / Info Pages Problem

Info Pages Problem

Locked

Started by jacque427 on 10 Oct 2006, 1:56 AM · Views: 2,608

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
10 Oct 2006, 1:56 AM
#1
jacque427 avatar

jacque427

Zen Follower

Join Date:
Apr 2005
Location:
Spokane, Washington
Posts:
324
Plugin Contributions:
0

Info Pages Problem

Upon moving to a new host that uses PHP 5.04 my info pages no longer work.

I am using ZC 1.2.6 and after fixing some code in /infopages.php still get the following error when attemping to access the info page:

Warning: main(includes/templates/template_default/templates/tpl_infopagesphp_default.php)
[function.main]: failed to open stream: No such file or directory
in /includes/templates/custom/common/tpl_main_page.php on line 74

Fatal error: main() [function.require]: Failed opening 
required 'includes/templates/template_default/templates/tpl_infopagesphp_default.php' (include_path='.') 
in /includes/templates/custom/common/tpl_main_page.php on line 74

Other than the host change and fixing the code in infopages.php to get it to work via the admin side I haven't changed anything.

Suggestions? (besides upgrade to ZC 1.3)

Jacque

Just knowledgeable enough to be dangerous.

11 Oct 2006, 5:45 AM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Info Pages Problem

jacque427:

(includes/templates/template_default/templates/tpl_infopagesphp_default.php)
[function.main]: failed to open stream: No such file or directory

Fatal error: main() [function.require]: Failed opening
required 'includes/templates/template_default/templates/tpl_infopagesphp_default.php'

What is a URL to one of your infopages?
It looks like you're using a URL that says something like "main_page=infopagesphp" when it should just be "main_page=infopages"

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

11 Oct 2006, 4:05 PM
#3
jacque427 avatar

jacque427

Zen Follower

Join Date:
Apr 2005
Location:
Spokane, Washington
Posts:
324
Plugin Contributions:
0

Re: Info Pages Problem

Right! Manually removing the .php from the url makes it work.

Now I found a new problem. I went to my developers tool kit (what an awesome tool! Couldn't work without it.) and entered "main_page=infopages.php" to find what pages to edit and received the following error when attempting to search:

Warning: dir(/home/httpd/vhosts/freshabundance.com/httpdocs//_private) [function.dir]: failed to open dir: Permission denied in 
/home/httpd/vhosts/freshabundance.com/httpdocs/admin/developers_tool_kit.php on line 36

Fatal error: Call to a member function read() on a non-object in /home/httpd/vhosts/freshabundance.com/httpdocs/admin/developers_tool_kit.php on line 38

I'm guessing it's another PHP 5 error.

Here is the applicable code from developers_tool_kit.php lines 34 through 47

// add directory name to the sub_dir_files list;
    $sub_dir_files[] = $dirName;
    $d = dir($dirName);
    $file_extension = '.php';
    while($entry = $d->read()) {
      if ($entry != "." && $entry != "..") {
        if (is_dir($dirName."/".$entry)) {
          if ($entry == 'CVS') {
          // skip
          } else {
            getDirList($dirName."/".$entry);
          }
        } else {
          if (substr($entry, strrpos($entry, '.')) == $file_extension) {

jacque

Just knowledgeable enough to be dangerous.

12 Oct 2006, 4:05 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Info Pages Problem

That problem was resolved in v1.3 :)
It was grabbing non-Zen Cart folders for the search.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

12 Oct 2006, 3:00 PM
#5
jacque427 avatar

jacque427

Zen Follower

Join Date:
Apr 2005
Location:
Spokane, Washington
Posts:
324
Plugin Contributions:
0

Re: Info Pages Problem

Yikes! Can I get it to work before I upgrade? As soon as I get the $$ I'll be contacting you to get it done. Just need a fix till then.

Just knowledgeable enough to be dangerous.

12 Oct 2006, 7:12 PM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Info Pages Problem

I think you can probably safely grab the /admin/developers_toolkit.php from the latest v1.3 version and use it in 1.2.7.
Just rename the old one with _old and upload the new one.
Give it a try... won't harm anything.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

13 Oct 2006, 3:52 PM
#7
jacque427 avatar

jacque427

Zen Follower

Join Date:
Apr 2005
Location:
Spokane, Washington
Posts:
324
Plugin Contributions:
0

Re: Info Pages Problem

That did the trick! Dang! You're good. I'll be PM'ing you for the upgrade when we get the funds.

That's way above me.

Jacque

Just knowledgeable enough to be dangerous.

13 Oct 2006, 4:01 PM
#8
jacque427 avatar

jacque427

Zen Follower

Join Date:
Apr 2005
Location:
Spokane, Washington
Posts:
324
Plugin Contributions:
0

Re: Info Pages Problem

For those that do a search and find this thread and have the same problem..

Edit /includes/extra_datafiles/infopages_filenames.php around line 23 and remove the .php from infopages so that it looks like this

define('FILENAME_INFOPAGES', 'infopages');

jacque

Just knowledgeable enough to be dangerous.