Fatal error: Call to undefined function _()
Posted by: chrisguk (95.211.138.---)
Date: July 09, 2012 07:34PM

Hi there, I keep getting this error when trying to load my site. I know it works because I developed it in a nix environment and seem to work perfectly:

Fatal error: Call to undefined function _() in C:\wamp\www\mysite\include\header.php on line 27
Call Stack

I have attached a screen shot here:

[img207.imageshack.us]

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: stevenmartin99 (Moderator)
Date: July 09, 2012 07:35PM

looks like incompatiable php versions..


what php version was linux using and which are you using now?

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: chrisguk (95.211.138.---)
Date: July 09, 2012 07:47PM

Linux was 5.3.10.1ubuntu3.2

and Windows WAMP is

5.4.3

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: stevenmartin99 (Moderator)
Date: July 09, 2012 07:48PM

can you paste the line with the error...

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: chrisguk (95.211.138.---)
Date: July 09, 2012 08:10PM

It says this but I have the $base_url defined?

print "<a href=$base_url/support>". _("Support"winking smiley. "</a>\n";

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: stevenmartin99 (Moderator)
Date: July 09, 2012 08:20PM

but its calling a function

i think your doing something that is deprecated.

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: chrisguk (95.211.138.---)
Date: July 09, 2012 09:10PM

I cant think what could possibly be depreciated, I just have basic functions

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: chrisguk (95.211.138.---)
Date: July 09, 2012 09:13PM

Voila!!!


Found it, the issue was that gettext was not enabled in php

Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: stevenmartin99 (Moderator)
Date: July 09, 2012 09:23PM


Options: ReplyQuote
Re: Fatal error: Call to undefined function _()
Posted by: chrisguk (95.211.138.---)
Date: July 09, 2012 09:30PM

I was starting to doubt my php dev skills then lol

Options: ReplyQuote


Sorry, only registered users may post in this forum.