iconv() problem

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
web_master
Forum Newbie
Posts: 3
Joined: Tue Oct 09, 2007 9:16 am

iconv() problem

Post by web_master »

Hi,

I got problem with iconv()

I use this script, and its work fine on my computer, on my servermachine

Code: Select all

setlocale(LC_TIME, 'hungarian');
    $HeadDate = iconv("Latin1", "utf-8//TRANSLIT", (strftime('%Y. %B %d. (%A)', mktime('0', '0', '0', $REQUESTHEAD['programs_month'], $REQUESTHEAD['programs_day'], $REQUESTHEAD['date_year']))));
but when I put that on server (internet) I got error message:
Fatal error: Call to undefined function: iconv() in /home/...

But, I put into database new post (row), and list that post than its work fine, when I refresh 2 times the browser I get the error message. If I put another line into database, again is OK untill I dont refresh the browser 2 times.

Can You help me, what is the problem?

Thanx

T
amargharat
Forum Commoner
Posts: 82
Joined: Wed Sep 16, 2009 2:43 am
Location: Mumbai, India
Contact:

Re: iconv() problem

Post by amargharat »

This extension is enabled by default, although it may be disabled by compiling with --without-iconv.

The optional --with-iconv-dir directive is used to specify the location of iconv on the system that PHP is being compiled on, otherwise only the default locations are scanned.
web_master
Forum Newbie
Posts: 3
Joined: Tue Oct 09, 2007 9:16 am

Re: iconv() problem

Post by web_master »

amargharat wrote:This extension is enabled by default, although it may be disabled by compiling with --without-iconv.

The optional --with-iconv-dir directive is used to specify the location of iconv on the system that PHP is being compiled on, otherwise only the default locations are scanned.
Ill try now phpinfo() and cant find iconv() :(
Phoenixheart
Forum Contributor
Posts: 123
Joined: Tue Nov 16, 2004 7:46 am
Contact:

Re: iconv() problem

Post by Phoenixheart »

Then I suggest you find another host with iconv() enabled.
Post Reply