Download Firefox: WindowsMac OS X
logo       
Google Custom Search
    AddThis Social Bookmark Button

Re: Emilda Questions: msg#00007

Subject: Re: Emilda Questions
Erik Berglund wrote:
E. Naeher said:

All right, I got the password changed.  Now when I try to search I get:

"Fatal error: Call to undefined function: yaz_connect() in
/var/www/html/emilda/search.inc on line 49"

I do have the yaz, libyaz, and libyaz-devel packages (RPMs) installed.



Hello,

The error concerning yaz_connect() indeed seems to be originated from not having YAZ compiled into PHP. The problem with PHP in comparison e.g. with Perl is that You have to compile modules into the code itself. This is done by supplying the compile command '--with-yaz' when compiling PHP (in addition to all other compile commands) which however does not seem to be the optimal alternative as You apparently are using RPM's. In this case i would suggest to use the 'external module'-option also suggested by Erik. For this, You have to download the php-dev (php-devel) package, which will supply You with the 'phpize'-script which will allow You to compile modules externally from PHP.

After installing php-dev, You have to get the 'yaz-module'-sources from somewhere, which however is of the same version as Your PHP. A simple solution is to download the source of PHP being the same vesion as Your installed PHP-version. After this, You extract the source, go to the 'extensions' folder and locate 'yaz'. Copy the contents from the 'yaz'-extensions folder to some arbitrary location (e.g. /tmp/new_module) with the '-a' option supplied to cp for identical permissions on files. After copying the files, 'cd' into the temporary folder (cd /tmp/new_folder), and type 'phpize'. This script should work for some seconds, and supply some output, depending on Your PHP-version. Now You have a complete, indenpendant environment to compile the module. You now can compile the module by typing './configure && make', and you should have a file called 'yaz.so' in one of the subfolders. This file has now to be copied to the PHP-extensions folder, which i however, cannot give now, as they vary greatly from distribution to distribution. Last but not least, after copying the file to the PHP-extensions folder, You have to tell PHP to include the module into PHP. This is done by adding a line 'extension yaz.so' into php.ini (typically /etc/php.ini) and restarting Apache (or Your web-server.)

To see if it worked out correctly, You can create a file called e.g. phpinfo.php somewhere in Your www-root with the contents

<?php phpinfo() ?>

which will tell exactly Your PHP-configuration.

By pointing Your browser to the location of phpinfo.php, You should see a page with the PHP-info. There, look for a 'Yaz'-section.


Please let me know if it worked out. If not, we will have to see what wen wrong...=)



You need to have Yaz compiled into PHP or use Yaz as an external module.
We'll give you more details soon as I'm not the right person to answer
questions on this part of the installation.


--Eli Naeher
 Lower Cape Fear Historical Society


 ----- Original Message -----
 From: E. Naeher
 To: emilda@xxxxxxxxxxxxxxxxxx
 Sent: Friday, December 05, 2003 12:59 PM
 Subject: [Emilda] Emilda Questions


 Hello,

 Emilda looks extremely interesting -- nice and clean and slick.  Even
the installation was impressively simple.  A few questions and
comments--


Thanks =)


 - What is the default admin password!?  The login screen is beautiful
but I'd like to see more. :)


The default password is 'test'.


 - I'm not a PHP person so maybe I'm missing something obvious --
however, index.php (and login.php and so on) couldn't find the .inc
files in ./lib as it wasn't in PHP's include_path -- perhaps these files
should set the include path before using require()?  I got around this
by copying the contents of ./lib to the main Emilda directory but I'm
not sure how stable that is.


'./lib' needs to be defined as an include directory for PHP. This can be
done globally via php.ini or locally using a virtualhost in httpd.conf
(see http://www.realnode.fi/index.php?location=241012e6ea - Sample
Configurations for reference).

You can also try using a .htaccess file with the following line in the
Emilda src directory:

php_value include_path ".:./lib"


 Thanks,

 --Eli Naeher
   Lower Cape Fear Historical Society




------------------------------------------------------------------------------


 _______________________________________________
 Emilda mailing list
 Emilda@xxxxxxxxxxxxxxxxxx
 http://lists.realnode.com/mailman/listinfo/emilda
_______________________________________________
Emilda mailing list
Emilda@xxxxxxxxxxxxxxxxxx
http://lists.realnode.com/mailman/listinfo/emilda



Thanks again for your interest in Emilda,

--
Erik Berglund
Partner, Marketing
Oy Realnode Ab
berglund [at] realnode.com
www.realnode.com
_______________________________________________
Emilda mailing list
Emilda@xxxxxxxxxxxxxxxxxx
http://lists.realnode.com/mailman/listinfo/emilda





<Prev in Thread] Current Thread [Next in Thread>