Welcome to Geeklog, Anonymous Friday, March 29 2024 @ 07:38 am EDT

Geeklog Forums

emailgeeklogstories - Fatal Error


Anonymous

Anonymous
Hi, I have a problem with emailgeeklogstories. I run it in terminal window typing /home/myaccount/emailgeeklogstories. I get the following error: <br /> <b>Fatal error</b>: Call to undefined function: mysql_connect() in <b>/home/myaccount/system/databases/mysql.class.php</b> on line <b>104</b><br /> But my Geeklog site is working fine - no problems at all.Here is also the content of emailgeeklogstories: #!/usr/bin/php4 -q <?php // This code snippet is responsible for emailing Geeklog stories to users // for the topics they select. // // For this script to work you must have compiled PHP so it can also be // used as a shell scripting language. You should call this script from // your crontab (man crontab). You will also need to set the exectuable // flags for this file. // Change this path to point to your lib-common.php file include('/home/myaccount/public_html/lib-common.php'); COM_emailUserTopics(); ?> I also took a look at mysql.class.php file... I entered var $_host = 'localhost'; var $_name = '***'; var $_user = '***'; var $_pass = '***'; ... but script don't want to work. Any idea?
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany

The emailgeeklogstories script uses the stand-alone (command line) version of PHP. It seems that version wasn't built with MySQL support. So you will need to recompile it (or ask your hosting service to do it for you).

In the meantime, you could use my Manual Digest plugin to send the Daily Digest manually.

bye, Dirk

 Quote

Anonymous

Anonymous
We have Debian installation, and our sysadmin compiled PHP interpretor. emailgeeklogstories works, if I run it as a PHP script through website (I moved it temporarly into public_html). So I think it is the problem with interpretor. But my sysadmin don't know what to do. He is aksing what exactly do you mean by MySQL support. What exactly should be installed?
 Quote

Status: offline

klync

Forum User
Newbie
Registered: 03/26/03
Posts: 5
note that the commandline interpreter uses a different config file. Check under /etc/php4/cgi/ ... you will need to edit that config file to load the mysql extension, just like what was done to /etc/php4/ apache/php.ini. That is, add a line saying: extension=mysql.so
 Quote

Status: offline

klync

Forum User
Newbie
Registered: 03/26/03
Posts: 5
Hi, See my earlier post for instructions on enabling mysql in the cgi (command line) version of php4. I just wanted to add: the binary that Debian distributes *does* have mysql compiled in, it's just not turned on!
 Quote

All times are EDT. The time is now 07:38 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content