Results 1 to 4 of 4
  1. #1
    Join Date
    Jul 2020
    Location
    Traralgon
    Posts
    9
    Plugin Contributions
    0

    Default PHP Deprecated: Non-static method ozpost::ozp_cfg_select_option() should not be stati

    Hope I'm posting this in the right place.
    Zencart version 1.5.7c

    I am getting the following debug error pop up when turning ozpost postage module on/off.

    [15-May-2021 04:21:39 Australia/Melbourne] Request URI: /ADMIN/index.php?cmd=modules&set=shipping&module=ozpost&action=edit, IP address: 111.208.204.181
    #1 eval() called at [/users/MYSITE/public_html/ADMIN/modules.php:335]
    #2 require(/users/MYSITE/public_html/ADMIN/modules.php) called at [/users/MYSITE/public_html/ADMIN/index.php:11]
    --> PHP Deprecated: Non-static method ozpost::ozp_cfg_select_option() should not be called statically in /users/MYSITE/public_html/ADMIN/modules.php(335) : eval()'d code on line 1.

    modules.php line 335
    Is there a left parenthesis missing??

  2. #2
    Join Date
    Jan 2004
    Posts
    66,364
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: PHP Deprecated: Non-static method ozpost::ozp_cfg_select_option() should not be s

    Quote Originally Posted by VacuumDog View Post
    modules.php line 335
    Is there a left parenthesis missing??
    No, the left-parenthesis is in the module's defined helper function as described in the db. That's normal.
    .

    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.

  3. #3
    Join Date
    Jan 2004
    Posts
    66,364
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: PHP Deprecated: Non-static method ozpost::ozp_cfg_select_option() should not be s

    Quote Originally Posted by VacuumDog View Post
    PHP Deprecated: Non-static method ozpost::ozp_cfg_select_option() should not be called statically
    Probably the ozpost module shouldn't be using the :: syntax for calling the function.
    .

    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
    Jul 2012
    Posts
    16,718
    Plugin Contributions
    17

    Default Re: PHP Deprecated: Non-static method ozpost::ozp_cfg_select_option() should not be s

    While not familiar with the particular plugin's internals, I have resolved something like this before by modifying the code in the affected area from:
    Code:
     ozpost::ozp_cfg_select_option()

    to:
    Code:
     $oz_var = new ozpost;
     $oz_var->ozp_cfg_select_option();
    Now mind you in the above, I don't know if there are parameters that are part of the class' method or if there is some assignment being done, etc... But, doing something like the above allowed generating a variable that could be used to call the non-static method. There may be other solutions as well. Unfortunately the original author is no longer available to update the plugin.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. v151 Non-static method m1_loader::getinstance() should not be called statically
    By louisapple in forum All Other Contributions/Addons
    Replies: 4
    Last Post: 17 Jul 2014, 12:49 AM
  2. v150 Strict Standards: Non-static method String::convertCharset() should not be called sta
    By Limitless in forum Installing on a Linux/Unix Server
    Replies: 2
    Last Post: 24 Sep 2013, 11:19 PM
  3. Replies: 2
    Last Post: 21 Aug 2010, 09:13 PM
  4. Replies: 4
    Last Post: 16 Jan 2010, 02:11 AM

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR