Forum Moderators: coopster

Message Too Old, No Replies

Call-time pass-by-reference has been deprecated?

         

marlita

11:13 pm on Oct 9, 2006 (gmt 0)

10+ Year Member



I saw a similar post but it wasn't exactly the same issue. My website is located at <snipped personal url>. If you try clicking on the "Who's Who" forum, you'll see my issue. I'm using vBulletin 3.6.0 and I'm not sure what I did but now I'm getting these warnings:

This message:

Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of convert_bits_to_array(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /home/content/r/e/v/revolveopp/html/example/forum/showthread.php(103) : eval()'d code on line 677

And this message:

Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of convert_bits_to_array(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /home/content/r/e/v/revolveopp/html/example/forum/forumdisplay.php(106) : eval()'d code on line 212

And this one:

Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of convert_bits_to_array(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /home/content/r/e/v/revolveopp/html/example/forum/showthread.php(103) : eval()'d code on line 677

Warning: Cannot modify header information - headers already sent by (output started at /home/content/r/e/v/revolveopp/html/example/forum/showthread.php(103) : eval()'d code:677) in /includes/functions.php on line 2480

Please help if you know how! Thank you so much!

[edited by: coopster at 1:52 pm (utc) on Oct. 10, 2006]
[edit reason] removed url per TOS [webmasterworld.com] [/edit]

coopster

2:01 pm on Oct 10, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Welcome to WebmasterWorld, marlita.

The PHP manual pages explain references [php.net] better than I can. You will want to pay particular attention to Passing by Reference [php.net].

marlita

4:33 am on Oct 11, 2006 (gmt 0)

10+ Year Member



=( This really is a foreign language to me. I looked it over and have been reading quite a few articles, but i can't seem to make heads or tails about how to fix this... I still can't figure out how this happened. *sigh*

Thank you for attempting to point me in the right direction, though. If there's anything more anyone can offer to help me figure this out, please feel free to share.

coopster

1:18 pm on Oct 11, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



If it was just a sudden change and if it wasn't that your PHP installation was upgraded then perhaps your error_reporting was turned up. On a live site you should not be displaying your errors anyway, log them instead. Since they are warning errors you could get away with suppressing them by turning off error_reporting() [php.net] but that is not a very good long term solution. Turn them off for now, but then get to work fixing the problem.

surfin2u

6:06 pm on Oct 11, 2006 (gmt 0)

10+ Year Member



Sounds like Marlita is not a PHP programmer, so her best option would be to contact the developer of the code that she's using and try to get them to fix the problem.

Turn down or off error reporting seems like a good temporary solution.

I find it hard to believe that pass-by-reference is depracated, since it's such a useful feature of the language, but that's a very technical question for this thread.

coopster

7:30 pm on Oct 12, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Pass-by-reference isn't deprecated, "Call-time pass-by-reference" is deprecated


Note that there's no reference sign on function call - only on function definition. Function definition alone is enough to correctly pass the argument by reference. In recent versions of PHP you will get a warning saying that "Call-time pass-by-reference" is deprecated when you use a & in foo(&$a);.

surfin2u

4:38 pm on Oct 13, 2006 (gmt 0)

10+ Year Member



Thanks for the clarification, coopster, now that makes sense to me.

marlita

4:47 pm on Oct 13, 2006 (gmt 0)

10+ Year Member



Guys,

Thank you so much for posting. You're right: I'm not a programmer =(, but I am trying hard to fix this. I went to the link re:turning the error messages off. Unfortunately, I don't know where or how to get to the .ini file. =/ i know how to log into the database, and I know how to log into the php files, by typing in the ftp address. I just don't know where to look for the .ini file.

As far as how this thing happened, well, I was on the vbulletin site trying to add mods. I had successfully added about 20 or 25 mods with no issues. I added a few more back to back, and the next thing I know this message comes up, and I have no clue which mod did it. I don't understand what the message means, and I'm contemplating just erasing the whole database and starting from scratch, which makes me sad since so many people have already signed up and added posts to the site. I know that other people have a test forum where they try things out first, but I can't figure out how to do that =/. I just learned how to back up the database, but I'm thinking that this is less of a database issue, and more of a php file issue since my messages reference the various php and their lines. Now, if only I knew what to do about those lines, then maybe I could fix this.

Do any of you who actually know what you're doing work on sites like mine?

Whatever this issue is, it's even affecting some of the links on the site, making it all the more difficult for people to use the site.

Please help if you know how!

Thank you again!

Marlita