Call to undefined function mysql_connect

Discussion in 'Install/Upgrade Support' started by faik371, Mar 2, 2016.

  1. faik371

    faik371 New Member

    Joined:
    Jan 30, 2016
    Messages:
    17
    Likes Received:
    1
    Hi. I have 2 websites with your engine. On the first when i tried to install all was good. Now, since 2 moths i try to install webid on the second site.

    I tried to download engine from main website, also from github, also i copied the ftp folder with first site, and always i have the same error:

    Fatal error: Uncaught Error: Call to undefined function mysql_connect() in /home/faik371/SITE.COM/includes/functions_global.php:26 Stack trace: #0 /home/faik371/SITE.COMcommon.php(49): global_class->global_class() #1 /home/faik371/SITE.COM/admin/index.php(17): include('/home/faik371/a...') #2 {main} thrown in /home/faik371/SITE.COM/includes/functions_global.php on line 26
     
  2. renlok

    renlok Administrator Staff Member

    Joined:
    Oct 20, 2008
    Messages:
    2,858
    Likes Received:
    330
    If you have PHP7 on your server you will get this error? see if its possible to use a lower version
     
    david62311 likes this.
  3. faik371

    faik371 New Member

    Joined:
    Jan 30, 2016
    Messages:
    17
    Likes Received:
    1
    I dont know how to check verstion and use other version, but this 2 website are on 1 hosting and on 1 site works fine, other has an error.
     
  4. Box Lot

    Box Lot Super Moderator Staff Member Developer

    Joined:
    Dec 18, 2008
    Messages:
    2,621
    Likes Received:
    165
    It should be in your host's control panel for your domain(s).

    It is possible to have one domain on one version and another on a different version. That could explain one working and another not working.
     
    faik371 likes this.
  5. faik371

    faik371 New Member

    Joined:
    Jan 30, 2016
    Messages:
    17
    Likes Received:
    1
    Thank you very much. Webid dont works with PHP7, but works with 5.6
     
    david62311 likes this.
  6. nay27uk

    nay27uk Super Moderator Staff Member

    Joined:
    Nov 24, 2009
    Messages:
    5,572
    Likes Received:
    547
    No it won't work on PHP7 because WeBid at present is mysql and mysql has been dropped from PHP as of PHP7 in favour of PDO. The next version of WeBid currently in production will be PDO so will work on PHP7.
     
  7. thehippyelf

    thehippyelf Member

    Joined:
    Aug 25, 2015
    Messages:
    239
    Likes Received:
    10
    I changed from PHP7 to v5.6.37 because of the previously mentioned error but am now seeing the following;

    Deprecated: mysql_query(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /srv/disk14/2552227/www/tradelanz.com/includes/messages.inc.php on line 23

    Warning: mysql_query(): No such file or directory in /srv/disk14/2552227/www/tradelanz.com/includes/messages.inc.php on line 23

    Warning: mysql_query(): A link to the server could not be established in /srv/disk14/2552227/www/tradelanz.com/includes/messages.inc.php on line 23

    What am I missing here? :-/

    Please help :-O
     
  8. pani100

    pani100 Well-Known Member

    Joined:
    May 9, 2011
    Messages:
    2,327
    Likes Received:
    449
    What version of Webid are you using?
     
  9. thehippyelf

    thehippyelf Member

    Joined:
    Aug 25, 2015
    Messages:
    239
    Likes Received:
    10
    I was running v7 and after changing to v5 the problem was sorted

    Thanks all
     

Share This Page