Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2006
    Posts
    10
    Plugin Contributions
    0

    Default file is there but keep getting 404

    Hello,

    www.8fstudios.com/

    under Photography Services - Portrait

    If you look at the status bar it can't find the file so I get the Page Not Found page.

    I have the following files in these directories:

    \includes\languages\english\portrait.php
    \includes\languages\english\html_includes\define_portrait.php
    \includes\templates\template_default\templates\tpl_portrait_default.php
    \includes\languages\english\html_includes\classic\define_portrait.php

    Here is the code that would call out the portrait.php file:

    if (DEFINE_PORTRAIT_STATUS <= 1) {
    $photography_services[] = '<a href="' . zen_href_link(FILENAME_PORTRAIT) . '">' . BOX_INFORMATION_PORTRAIT . '</a>';
    }

    Help? It's a matter of telling whatever file to find that portrait.php file and I can't figure out who is lost.

    Thank you!

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: file is there but keep getting 404

    Looking at your other pages like wedding = http://8fstudios.com/index.php?main_page=page_4

    and then to the portrait = http://8fstudios.com/index.php?main_...ENAME_PORTRAIT

    I would double check the define for this name as this is usually the issue when this happens. Check that the description is contained in single quotes and syntax is like others.

  3. #3
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: file is there but keep getting 404

    You are essentially creating another page for your site. You need to define the filename for it.

    You can create your own definition for your portrait file:
    /includes/extra_datafiles/portrait_filenames.php

    PHP Code:
    <?php
    define
    ('FILENAME_PORTRAIT''portrait');
    ?>
    .
    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.

  4. #4
    Join Date
    Nov 2006
    Posts
    10
    Plugin Contributions
    0

    Default Re: file is there but keep getting 404

    Hello,

    I've checked them all and they all are correct. I checked each of the spelling and they all are portrait.

    When I type in manually "http://8fstudios.com/index.php?main_page=portrait" the page does exist.

    Could you tell me where this "FILENAME_PORTRAIT" is supposed to be located in? Maybe that's where I am supposed to look into. I did a search for anything *page_3*.* and I changed each file/directory to see if I can get the same problem as the Portrait but unfortunately no luck. So I'm guessing there is a directory or another file that I need to modify. Question is where?

    Thank you!

  5. #5
    Join Date
    Nov 2006
    Posts
    10
    Plugin Contributions
    0

    Default Re: file is there but keep getting 404

    Apparently this works. MR. DRBYTE

    Could you enlighten me why your code works? Versus this default ==>

    PHP Code:
      if (DEFINE_PAGE_3_STATUS <= 1) {
        
    $photography_services[] = '<a href="' zen_href_link(FILENAME_PAGE_3) . '">' BOX_INFORMATION_PAGE_3 '</a>';
      } 
    where all I did was rename PAGE_3 to PORTRAIT and all files associated to PAGE_3



    Thanks!


    Quote Originally Posted by DrByte View Post
    You are essentially creating another page for your site. You need to define the filename for it.

    You can create your own definition for your portrait file:
    /includes/extra_datafiles/portrait_filenames.php

    PHP Code:
    <?php
    define
    ('FILENAME_PORTRAIT''portrait');
    ?>

  6. #6
    Join Date
    Nov 2006
    Posts
    10
    Plugin Contributions
    0

    Default Re: file is there but keep getting 404

    Oh!!!

    I think I know now. After looking at your code again.... I realized... oh it's because FILENAME_PORTRAIT is not defined. Then I read your post again and yeah... IT PAYS TO READ!!!!

    :)

    THANKS!

  7. #7
    Join Date
    Jan 2004
    Posts
    66,450
    Plugin Contributions
    81

    Default Re: file is there but keep getting 404

    exactly.

    Glad it's working for you.
    .
    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.

 

 

Similar Threads

  1. Replies: 9
    Last Post: 20 Jan 2014, 08:58 AM
  2. Getting 404 error after replacing a file.
    By veronicathecow in forum General Questions
    Replies: 3
    Last Post: 15 Dec 2011, 09:46 PM
  3. it's getting there... but I still need help
    By secondnature in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 16 Mar 2011, 09:47 AM
  4. Froogle File Complete - But Not There
    By MeltDown in forum General Questions
    Replies: 14
    Last Post: 20 Sep 2006, 04:34 PM
  5. Installed, Error Says "No Such File" but file is there!
    By plumloopy in forum Installing on a Linux/Unix Server
    Replies: 9
    Last Post: 30 Aug 2006, 01:34 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg