collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
* Search

* Board Stats
  • stats Total Members: 989
  • stats Total Posts: 18365
  • stats Total Topics: 2500
  • stats Total Categories: 7
  • stats Total Boards: 35
  • stats Most Online: 1144

Author Topic: BeBot on PHP 5.4  (Read 10490 times)

0 Members and 1 Guest are viewing this topic.

Offline BoA-Gert

  • BeBot User
  • **
  • Posts: 45
  • Karma: +0/-0
BeBot on PHP 5.4
« on: March 12, 2012, 04:22:10 pm »
Tried to get the bot running on PHP 5.4 but had problems - primarily:

PHP Notice: Undefined offset: 1 in /home/bebot/Sources/Conf.php on line 47

Fatal error: Call-time pass-by-reference has been removed in /home/bebot/Main.php on line 298

Running on Debian - anyone else have issues with PHP 5.4?  Reverting back to PHP 5.3 has no problems.

Offline maurograca

  • BeBot Rookie
  • *
  • Posts: 1
  • Karma: +0/-0
Re: BeBot on PHP 5.4
« Reply #1 on: March 12, 2012, 05:34:51 pm »
Same problem here, Bebot is no more compatible with new php version,

try this workaroud, i donĀ“t know if solves the problem, but...:

Edit all .php files on bebot folders and replace "&$bebot" wtih "$bebot", and all the other "&$" must be replaced too...

PHP now refuses this kind of parameters. Developers must update all the php code that uses "!$"
"pass-by-reference" variables

Maustoth

Offline Zeephonz

  • BeBot User
  • **
  • Posts: 43
  • Karma: +0/-0
Re: BeBot on PHP 5.4
« Reply #2 on: March 13, 2012, 01:12:10 am »
Had same problems when migrating bots to a new machine. Worked perfectly back at 5.3.6 so just installed that instead.

Offline Khalem

  • BeBot Founder
  • Administrator
  • ********
  • Posts: 1169
  • Karma: +0/-0
    • http://www.ancarim.com
Re: BeBot on PHP 5.4
« Reply #3 on: March 13, 2012, 02:11:19 am »
Stick with php 5.3 for now if possible. The workaround proposed by maurograca is not recommended as variables are usually passed by reference for a reason.

I'll see if I can find some time soon to work my way trough and rewrite all functions that currently use pass by reference.
BeBot Founder and Fixer Kingpin

Offline Khalem

  • BeBot Founder
  • Administrator
  • ********
  • Posts: 1169
  • Karma: +0/-0
    • http://www.ancarim.com
Re: BeBot on PHP 5.4
« Reply #4 on: May 28, 2012, 12:46:32 pm »
You can give the current snapshot a try.

I think most PHP 5.4 issues should be resolved now.
https://github.com/J-Soft/BeBot-legacy/zipball/master
BeBot Founder and Fixer Kingpin

 

* Recent Posts
0.8.x updates for AO by bitnykk
[June 23, 2024, 03:19:47 pm]


0.8.x updates for AoC by bitnykk
[June 23, 2024, 03:19:44 pm]


[AoC] special char for items module by bitnykk
[February 09, 2024, 09:41:18 pm]


BeBot still alive & kicking ! by bitnykk
[December 17, 2023, 12:58:44 am]


Bebot and Rasberry by bitnykk
[November 29, 2023, 11:04:14 pm]

* Who's Online
  • Dot Guests: 320
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.
* Forum Staff
bitnykk admin bitnykk
Administrator
Khalem admin Khalem
Administrator
WeZoN gmod WeZoN
Global Moderator
SimplePortal 2.3.7 © 2008-2024, SimplePortal