Results 1 to 9 of 9

Thread: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

  1. #1
    nathanwheeler
    Guest


    Default Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    Deprecated: Function eregi() is deprecated in Campphtdocsnewoscmaxsiteincludesclasseslanguage.php on line 87
    is the error mages I get after installing latest oscmax version on the latest xampp package.
    It has php5.3 in which the eregi is deprecated but I cannot figure out with which to replace that function in classes/....

    Anyone here maybe?

    Thank you!

  2. #2
    osCMax Developer


    Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    michael_s's Avatar
    Join Date
    Jul 2002
    Location
    Phoenix, AZ
    Posts
    22,983
    Total Contributions For

    michael_s     $ 10.00
    Rep Power
    591


    Default Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    Michael Sasek

    osCmax 2.5.4 is now available via auto-installation using Softaculous!

    Stay Up To Date with everything osCMax:
    osCmax on Twitter - Up to the minute info as it happens. Know it first.

    osCmax Documentation

  3. #3
    nathanwheeler
    Guest


    Default Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    Right, found that too, changed the code but then get an error
    - preg_match not found ..
    and after that a problem: ^ is without delimiter.
    But solution is this IF I am not mistaken * site works although some more eregi's must be replaced.

    if (preg_match('/^(' . $value . ')(;q=[0-9]\.[0-9])?$/i', $this->browser_languages[$i]) && isset($this->catalog_languages[$key])) {
    $this->language = $this->catalog_languages[$key];

  4. #4
    osCMax Developer


    Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    michael_s's Avatar
    Join Date
    Jul 2002
    Location
    Phoenix, AZ
    Posts
    22,983
    Total Contributions For

    michael_s     $ 10.00
    Rep Power
    591


    Default Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    There are several hundred instances of ereg() in osCMax that will have to be changed. I have already completed about 80% of these changes and should have the commit ready for SVN (2.1) in a couple of days. I want to test the changes before committing, since there are so many.
    Michael Sasek

    osCmax 2.5.4 is now available via auto-installation using Softaculous!

    Stay Up To Date with everything osCMax:
    osCmax on Twitter - Up to the minute info as it happens. Know it first.

    osCmax Documentation

  5. #5
    vitoox
    Guest


    Default Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    Recently I was bombarded all over catalog and admin areas with ereg() and eregi() errors too. Latest ver. of osCMax is tested on local machine under XAMPP Lite 1.7.2. For ex.: " Deprecated: Function ereg() is deprecated in C:\xampplite\htdocs\catalog\includes\configure_bts .php on line 167 " . Ereg() change to preg_match() results this - "Warning: preg_match() [function.preg-match]: No ending delimiter '^' found in C:\xampplite\htdocs\catalog\includes\configure_bts .php on line 167
    Illegal template directory!" .
    Is there any cure for these errors? Thanks

  6. #6
    osCMax Development Team

    Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    pgmarshall's Avatar
    Join Date
    Feb 2009
    Location
    London
    Posts
    3,517
    Total Contributions For

    pgmarshall     $ 35.00
    Rep Power
    77


    Wink Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    What version of PHP are you using? Sounds like your server has upgraded php and not told you ... If you are using php v5.3 then you are going to get a load of these errors ...

    Read the link that Michael posted ... it will explain what is going wrong ... in the meantime you can wait for Michael to change the source or simply use a host that uses a lower version of PHP - I am surprised to hear that your host is already using v5.3 - (if this is the case).

    If you know what you are doing then perhaps you might be able to offer to help Michael out making/testing the changes to the code ...

    Regards,
    Last edited by pgmarshall; 08-30-2009 at 02:30 PM. Reason: typo
    pgmarshall
    _______________________________

  7. #7
    vitoox
    Guest


    Post osCMax v.2.0.3 and XAMPP v.1.7.2 problem with Deprecated functions ereg() &/or eregi() - solved

    If ocCMax v2.0.3 is tested/developed on localhost under XAMPP (Lite) v.1.7.2 , the shortest way to skip Deprecated errors of eregi() &/or ereg() functions is simple - downgrade Xampp to ver.1.7.1 with PHP 5.2.9.

    At least at the moment this post is written.

  8. #8
    bkpie
    Guest


    Default Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    Most are easily fixed. But what would be the solution when you have ereg(’^’) If you do it based on the instructions in the link Michael had above you get an unknown modifier error.

    specifically

    if (!ereg('^' . DIR_FS_DOCUMENT_ROOT, $current_path)) $current_path = DIR_FS_DOCUMENT_ROOT;

    does not work as

    if (preg_match('/^/' . DIR_FS_DOCUMENT_ROOT, $current_path)) $current_path = DIR_FS_DOCUMENT_ROOT;

  9. #9
    osCMax Developer


    Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    michael_s's Avatar
    Join Date
    Jul 2002
    Location
    Phoenix, AZ
    Posts
    22,983
    Total Contributions For

    michael_s     $ 10.00
    Rep Power
    591


    Default Re: Deprecated: Function eregi() is deprecated in C:xampphtdocsdali-designincludesclasseslanguage.php on line 87

    Here is a workaround until we roll out the patch.

    In includes/application_top.php and admin/includes/application_top.php

    find:
    PHP Code:
     //set the level of error reporting
      
    error_reporting(E_ALL & ~E_NOTICE); 
    replace with:

    PHP Code:
    //set the level of error reporting
    error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED); 
    Michael Sasek

    osCmax 2.5.4 is now available via auto-installation using Softaculous!

    Stay Up To Date with everything osCMax:
    osCmax on Twitter - Up to the minute info as it happens. Know it first.

    osCmax Documentation

Similar Threads

  1. Replies: 0
    Last Post: 03-25-2009, 02:59 AM
  2. search function
    By silverchair in forum osCommerce 2.2 Modification Help
    Replies: 8
    Last Post: 03-09-2009, 09:29 PM
  3. Get Price Function
    By michael_s in forum New osCommerce Contributions
    Replies: 0
    Last Post: 03-17-2008, 10:11 AM
  4. Replies: 3
    Last Post: 03-08-2008, 03:32 PM
  5. administrator function
    By jloyzaga in forum osCmax v1.7 Discussion
    Replies: 0
    Last Post: 03-29-2004, 03:14 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
  •