Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    PHP




Displaying A List Of All Modules (extensions) Installed


I just signed up for a web hosting service. They have PHP, but can't
tell me which modules (extensions) are installed.

Is there a function, or some other easy way, to show all modules
(extensions) that are installed? phpinfo() doesn't do this.




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Remove File Extensions From A Directory List
I'm running a small script which lists files in a directory by last modified and with under scores in file names replaced with spaces. I'd also like to remove the file extension, but cant figure out how. I found this code. $ext = substr($value, -4); ....though i'm unsure how to implement it PHP Code:

Displaying List W/out Repeats
I'm working on a project that will allow people to upload content and make entries to a database. I want to build a menu that will display the different values for a certain field, but I know that there will be identical values throughout the table. Do I need to dump values into a separate table, or can I use the values that are there and somehow ignore the repeats?

Displaying A List Of Members Logged In
I wish to display all of the current members who are logged into the system. I figure I can do this using their session id's and matching their usernames accordingly. Or I could create a separate table containing their username and INSERT when someone logs in and DELETE when someone logs out. Then i could display the contents of the table.

Displaying Table Field List
I got a function that displays a list of the fields in a certain mysql table.  I got it off of this site.  The problem is that it only displays the word Array and I'm not sure why.  This is the code for the function: Code:

Displaying A List Of Categories From A Database In A Select Box
Could someone please tell me why this outputs nothing

<select name=categories>
<?
$cat_array = get_categories();
foreach($cat_array as $this_cat)
{
echo "<option value="";
echo $this_cat["category_id"];
echo """;
echo ">";
echo $this_cat["category_name"];
echo "
";
}
?>
</select>

==========================================================

function get_categories()
{
//get the list of categories from the database

$conn = mysql_pconnect("localhost", "user", "pwd");
$query = "select * from categories";
$result = mysql_query($query);
if(!$result)
return false;

$num_cats = mysql_num_rows($result);
if($num_cats == 0)
return false;

$result = db_result_to_array($result);
return $result;
}

//A function that returns a query to the database as an array
function db_result_to_array($result)
{
$res_array = array();
for($count=0; $row=@mysql_fetch_array($result); $count++)
$res_array[$count] = $row;

return $res_array;
}

Displaying Data From Mysql Database In A Drop Down List On Form.
I'm trying to do is display data from two different mysql tables from the same database in a drop down list on a html form. I have a fixtures table with the player1(userid), player2(userid), gameid, game, score1 and 2, what I want is to use the userid to get the players first name and surname from the members table (as it is a unique id), I need to do this bit before displaying it in the drop down. I think i need 2 querys to do this but when I have tried it it just echo's a blank value or the userid not the forname and surname that I want. I'm using the fetch_array function but just can't see where I'm going wrong, Code:

Php-gtk + Modules
I'm trying to move some server code to a php-gtk app (under windows). I've got it (binary download) working with the samples.
The code i'm trying to use uses functions from php_zlib.dll as well as others, so i'm trying to include them. However the binary version of php-gtk doesnt come with the modules, and if i use the modules from my version of php (4.0.6) it comes up with errors, and if i try and use php-gtk with my version of php it comes up with errors and crashes, though it says it should work from 4.0.5.

PHP Modules
I'm not sure whether this can be done or not, but I guess there's no harm in asking.

The site I've built utilizes the 'domxml' PHP module. Unfortunately, few hosting providers seem to utilize this module. Is there any way to utilize this module dynamically, despite that the server hosting the PHP script doesn't have it loaded?

PHP Script Modules
I have written a PHP application that numerous companies are paying to use. There are a few companies that request features to be added to the application that don't always benefit the other companies using it. In these situations I have typically used a few if and else statements to use the new functionality for that company but leave the default funcionality intact for everyone else. There are lots of these little "features" in the system and the code is becoming spaghetti code. I need a way to organize these features.

Are there better ways of doing this? What I would like to ultimately acheive is a way to add the new functionality as a module or something that can be turned on and off for each company depending on their preference. I have been brainstorming on this topic for a while now and I can't seem to come up with any simple solutions. Any ideas you have are greatly appreciated!

Compiling The Modules
I'm having a lot of difficulty with compiling the modules for PHP, In fact I don't know where to start, you see Im pretty good at script type languages like PHP and Perl but when it comes to 'C' I have zero experience. I would really like to learn how to do this but would also find it useful to have the precompiled DLLs (windows NT).

Help On Pear Modules
First of all, I'm not a very seasoned programmer. It's just a hobby grown
out of control.

For a project I am working on I need to be able to send and receive e-mail.
I wrote some code for this myself, but that is just not quite good enough.
So I did a little research and found the Pear modules. I installed all the
Pear modules that I am supposed to need, but I don't understand the
documentation.

Could someone please explain to me how I am supposed to compose, send,
receive and identify the various parts of an incoming e-mail? I am, of
course, in full control of the mailsever.

Running PHP 4 & PHP 5 Together As Modules
We would like to upgrade our servers to PHP 5 and PHP 4
together as modules on the same server (not as cgi, not passing
requests to another server). I did some extensive searching on
this and we ran some tests over a year ago and did not find a
solution (other than proxy forwarding to a PHP 5 configured server).

When PHP went to version 4 from version 3, it was possible
to run both at the same time, and have users select by file
extension, i.e. .php4,.php5. It seems a naming conflict within
the code itself prevents that from working with PHP 5. Has anyone
discovered a way to do this?

We are running apache 1.3.x on RHEL 4.

PHP Graphing Modules
The problem is that i currenttly need to draw a horizontal bar graph that has to look pretty. I am looking around for perl graphing modules that can do this but i havent found any yet. My question is.. does anyone know off the top of their head if PHP can do this or has modules to do it? Because i might consider switching if it can.

Also are there any specific advantages of PHP over perl? i actually dislike perl a bit because of its stupid syntax and naming conventions and i would like to possibly switch if i can find a good enough reason.

Custom PHP Modules
I have been trying to find information on how to create my own php modules. So far i've been through various search engines, dev boards and sites. Nobody seems to have anything on the subject. I couldn't even find a single book on the subject.

Adding Modules Into PHP
Is there any way to add modules into PHP without recompiling it?? I need to add the GB module (I think thats what its called), the one that can create GIF images. If I can't will I have to recompile it and apache and MySQL or just PHP?

How Can I Compile Dynamic PHP Modules?
Maybe I've just missed something in the documentation, but since I can't seem to find it, I thought I'd post my question here.

I have RedHat 7.3 and the PHP 4.1.2 RPM package it came with. I used to compile my own versions of Apache/PHP/OpenSSH/SSL/etc, but since it's much easier to keep my machine up to date using RPMs and the "up2date" management tool, I now tend to shy away from compiling my own applications unless I can't find what I need from RedHat.

I'm now trying to add some extra functionality to PHP that RedHat didn't include with their PHP RPM. RedHat's PHP does come with a number of dynamic PHP modules, however(mysql.so, imap.so, ldap.so, etc.) I'd like to figure out how to create new ones (e.g. mcrypt). With Apache, I know I can build add webserver modules using the "apxs" tool. Is there a similar tool for PHP that will let me build new modules without having to run through an entire compilation process?

Getting PEAR Modules To Work
I'm new to Linux, setting up and running webservers. I
purchased an unmanaged server that came with a lamp configuration and
Plesk installed. I am trying to get PEAR functioning. I put a
php_info() page up and in the "Configure Command" section there is a
long list of things and "--without-pear" is listed. I know this should
probably say "--with-pear". How do I change this?

When I do a "pear list" command I get the following error:

Failed loading /usr/lib/php4/php_ioncube_loader_lin_4.3.so: /usr/lib/
php4/php_ioncube_loader_lin_4.3.so: undefined symbol:
zend_hash_add_or_update

This is after I upgraded from PHP4 to PHP5.

PEAR Modules HTML_QuickForm
I am using HTML_QuickForm and would like to output individual form
elements within an html/php document instead of $form->display() which spits
them out right there. I have site templates that I would like to place the
output into.

Addon-system (modules)
I'm making a news-system, and I want to enable the users of it to create their own modules for it (or download what others have made).. It should be fully extendable.. The problem is that I don't know how I should do it..

PHP, Apache (Linux), And Modules
I plan on installing PHP and Apache on a Linux box. (Plan on doing it with
binaries that come with Linux distro.)

One thing I'm confused about is how PHP is run as a module. I'm not that
familiar with this stuff, and I would have thought that there's something
called mod_php that needs installing. But I can't find much reference to
anything like that anywhere.

(Want to install as little stuff as possible.)

Execution Times/Modules
I am encoutering the following performance problem with php 3.0.16, the latest apache, running with compiled in php_mod on a sun ultra1.

i have written a set of php class files, which i use througout the site. the execution time of my skripts is very fast, but it seems that the class files i require (about 30k) slow down the performance enourmously. when i benchmark the site using ab with a php file which simply does html output and nothing else. its really fast, if i require my class files and do nothing else than the html output, the performance drops incredibly (no db connection, no computation, nothing)

i always thought that php_mod also keeps a byte code for the required pages in memory (like for example perl_mod). but now i doubt that. it seems that every request, forces php_mod to reload and recompile (or totally interpret ?!?!??) every file needed. is there anyway to increase performance when using multiple phpclass files? I know of conditional includes, but thats IMHO not a pretty solution.

Deletion And Editing Of Modules
i'm creating a miniature CMS. At the moment i'm working on the creation/deletion and editing of modules. I've got the creation working. But i'm struggling on the deletion and editing.

This is what i was thinking:

[Deletion]

1. (ID) Module 1 [Delete] (Link: modules.php?do=delete?name=Module%201&id=1)

[Editing]

1. (ID) Module 1 [Edit] (Link: modules.php?do=edit?name=Module%201&id=1)

How would i make it so the URL was that?

Common Login For Diff Modules
I need to make a community site containing blog, forum, shoutbox, gallery, news, event calenders. Any one can give me suggestions like how can i make them accessible with one common login? Is it already handled by joomla or any other cms?

Running PHP 4 And PHP 5 Together As Modules, Linux, Apache 1.3.x
We have been running PHP 4.x on Apache 1.3.x with
no problems. After the first upgrade from php3 -> php4 were
were able to load both modules for php 3 and php 4 with no
problem. With an AddType directive we forced php 3 execution
for just those files ending in php3.

Thought we could do the same with php 5. We have a
lot of folks on 4 who may not be ready to upgrade yet, so
we were planning on letting php 4 handle anything ending in
..php or .php4 -- and use php 5 for just php5 extensions.

Did the same thing as before in our Apache Config,
we are running on Redhat 9 -- but can't get both 4 and 5
running together. It seems we can run one or the other, but
not both -- when we start apache we get ONE server process
that just sits there, nothing in the log files?

After some web searching could not find much, one
guy said there was a conflict in memory management and
you can't run the two together?

Anyone got this to work and how? Had posted this to
the alt..php group and still looking for a solution?

Apache 2.0.50 Php 5.1.2 - Modules Loads But Scripts Don't Run
I've compiled php 5.1.2 on a Madrake 10.1 box as an apache module. I have the following in my apache conf file:

LoadModule php5_module /usr/lib/apache2/libphp5.so
AddType application/x-httpd-php .php

The module is definately loading...I get this in the error_log:

[Fri Feb 10 15:24:03 2006] [notice] Apache-AdvancedExtranetServer/2.0.50 (Mandrakelinux/7.6.101mdk) PHP/5.1.2 mod_ssl/2.0.50 OpenSSL/0.9.7d configured -- resuming normal operations

So obviously the module is loading. When I try a simple test.php via apache, it sends the browser the text of the script as mime type application/x-php (which appears to be the mime type from apache-mime.types). I've done this countless times on other distros. What am I missing there? I thought those were the only two pertinent lines in the conf file.

PEAR Modules On A Hosted Server?
Is there any way to utilize PEAR, Specifically PEAR DB on a host (shared server) where I cannot install PEAR. I spent some time reading the Install documentation and my brain is numb, without drawing any conclusions. My host has a /php directory at the root, which appears to be a member of the include path. I have an object that requires PEAR DB and I do not think I can rewrite the DB calls in a reasonable amount of time.

Looking For A Couple Of Php Modules/libraries To Do Standard Web Stuff For Me
I've been contemplating two things for a php project I'm working on :

1) doing user security stuff (users, admins, super-admins etc), pref.
compatible with win32

2) doing pagination of large results lists

I've been looking (not terribly hard) for standard, mature php
libraries to help me do this. However I'm not confident of my own
opinion/evaluation of the little I've stumbled across, and have turned
to gin and tonic as an alternative. However, I've recently realised
that the gin isn't going to actually help me find these libraries.

Can anyone give me some recommendations?

I'm not looking for full-blown complex stuff. I'd rather have simple,
mature, stable, secure and EASY!

Installed CGI
Just installed CGI and had problems wif headers, got sum error, after research got hot fix from microsoft to solve it.  Now i when i submit a form to update or add etc its all mucked up, the form reloads again which its suppose to do but the css isnt working and its stays on the php page in the url box when its actually on the form page. Make no sense.

Help With Displaying Selecting A Date Range And Displaying Results
I wish to create a simple form that allows the selection of a start date and a stop date with the ability to select what columns to be displayed in the result page.

Installed PHP With IIS, But Get A Notice.
Here is what I get when I load my first php site. After I installed php (instashield), did I need to give permissions to something else? If so please outline it simply. I searched on these forums but the closest I came to this was giving security permissions to my site folder to access php. Not sure how to do that in IIS. The security tab seemed to just reflect the username & password of the user accounts on my computer.

Notice: Use of undefined constant HTTP_USER_AGENT - assumed 'HTTP_USER_AGENT' in D:Web Site Servermysitefolder\_librowserDetector.php on line 62

2 PHPs Installed?
So i'm porting my site over to my new server, and it's pretty bare.
I have apache 1.3 with php 4.3.11 and now apparently 4.4.0

why two version? i'll explain:

So i was trying to get the GD library working with my app. specifically it was telling me that it couldn't find the imagejpeg function. no biggie i thought, an excuse to upgrade to 4.4.0 i'll just recompile php with gd and everyone will be happy. i used this configure directive:

[code]
./configure
--with-apxs=/usr/local/apache/bin/apxs
--with-xml
--enable-bcmath
--enable-calendar
--enable-ftp
--enable-magic-quotes
--with-mysql=/usr
--enable-discard-path
--with-pear
--enable-sockets
--enable-track-vars
--enable-versioning
--with-zlib
--with-gd <--- w0ot!
[code]

anyways so i restart apache and voila... phpinfo() is telling me i have php4.4.0 - yay for me, so i go to resize my image and i'm stuck with the error. i gave up

This morning i was going through phpmyadmin and decided to check the php version it's using. and sure enough, a phpinfo() provoked from there is still 4.3.11 - so i'm wondering is it possible that apache is still pointing to the original php, and if so - where?! the problem is this stupid cpanel program they installed....

How Do I Know If Crypt Is Installed?
I'm trying to find out how to know if crypt is installed on the
system. With mcrypt there is a section in phpinfo() but I can't find
any similar section for crypt.

How To Determine Whether GD Is Installed?
I am trying to install a captcha form that required those graphic libraries. I got the error message "call to undefined function" which according to the authors of the form suggests that GD is not probably installed or enabled.

I created the usual <?phpinfo()?> report and the only part GD is mentioned is in the Configure Command section:

./configure'...'--with-gd=shared' '--enable-gd-native-ttf' '--without-gdbm' '--with-gettext' '--with-ncurses=shared' '--with-gmp' '--with-iconv'

Can you tell whether GD is installed from that? If I remember correctly, GD should have its own section within the PHP info report - but its not there.

Since my host isn't very responsive to my requests, I was thinking that I should try installing GD myself. Server is running Apache/2.0.52 (CentOS). Anyone aware of any tutorials that might help preventing me from screwing up things?

Host Has Installed 4.3.11-dev
The host of one of the domains I manage has installed 4.3.11-dev and as
a result file uploads no longer work with Internet Explorer.

Worth keeping an eye out for.

In the meantime I now need to ask why they have installed a development
version on a production server...

Is Mysqli Installed?
A server (which I have no access to yet) has been installed with PHP like
this:

What Software Is To Be Installed To Run PHP !
Hope you all doing great.

I am new to PHP and want to know what software is to be installed on
my server to run PHP scripts

and

what softwares are available for creating, editing, the PHP scripts.

Test If GD Is Installed
I know you can just open phpinfo() to find out but if I want to include this as part of an install script to test if GD is installed how do I do it?

Checking If Gd Has Already Installed
I installed php4.3.2 , apache 2.0.47 and mysql-standard-4.0.14.

1- it seems that they work properly , but i want to know how i can be sure if GD has been installed corrcetly. ??

2- BTW any clue about commands by which i can get the information ( like version ...) of a.m component??

'gd' PHP Extension Is Not Installed
I'm trying to install the Image_Color pear package. I keep getting the
following error:

"'gd' PHP extension is not installed"

phpinfo on my web server indicates that gd is enabled. when I try to
get info from my command line interface I don't see anything where it
was compiled with gd.

Am I right in assuming there are two ini files? One for the command
line and one for the web server?

A google search has revealed that others have run into this problem but
I have yet to find a solution.

Can anyone shed any light?

general info from the command line...
<pre>
Build Date =Apr 24 2006 19:54:25
Configure Command =>
'/SourceCache/apache_mod_php/apache_mod_php-18.4/php/configure'
'--prefix=/usr' '--mandir=/usr/share/man' '--infodir=/usr/share/info'
'--disable-dependency-tracking' '--with-apxs' '--with-ldap=/usr'
'--with-kerberos=/usr' '--enable-cli' '--with-zlib-dir=/usr'
'--enable-trans-sid' '--with-xml' '--enable-exif' '--enable-ftp'
'--enable-mbstring' '--enable-mbregex' '--enable-dbx'
'--enable-sockets' '--with-iodbc=/usr' '--with-curl=/usr'
'--with-config-file-path=/etc' '--sysconfdir=/private/etc'
'--with-mysql=/usr' '--with-mysql-sock=/var/mysql/mysql.sock'
Server API =Command Line Interface
Virtual Directory Support =disabled
Configuration File (php.ini) Path =/private/etc/php.ini
PHP API =20020918
PHP Extension =20020429
Zend Extension =20050606
Debug Build =no
Zend Memory Manager =enabled
Thread Safety =disabled
Registered PHP Streams =php, http, ftp, compress.zlib
</pre>

Anyone Successfuly Installed ..
PHP5beta2 with the latest Apache?

GD Thinks It's Installed, But Won't Work
I'm running PHP5 on a WinXP box using Apache2. I am having an unusual
problem and can't find a solution online at all.

I believe I have enabled the GD module properly. I modified the php.ini
and restarted apache (and later restarted my computer) to enable the
php_gd2.dll. When I run phpinfo() and gd_info() I get valid output:

Array
(
[GD Version] =bundled (2.0.28 compatible)
[FreeType Support] =1
[FreeType Linkage] =with freetype
[T1Lib Support] =1
[GIF Read Support] =1
[GIF Create Support] =1
[JPG Support] =1
[PNG Support] =1
[WBMP Support] =1
[XPM Support] =>
[XBM Support] =1
[JIS-mapped Japanese Font Support] =>
)

The problem, though, is that no gd functions work. I keep getting
"Fatal error: Call to undefined function imagecreate()" or any other
image___() functions. I've tried reinstalling php, restarting the
computer and apache, disabling and reenabling the dll, all with no
success. Does anyone have any idea why this GD installation is partial
and how I can get around it?

Php Cannot Be Installed On Linux - Newbie
I had to uninstall the php 4.2.2(that came along with linux
installation) to install 4.3.3 for some of my new applications to
work. The uninstallation went fine and the installation of 4.3.3 was
done in the following sequence after cd'ing into the php directory

../configure
make
make install

every thing seemed to go fine..

When i tried to see if package php is installed using
rpm -q php

I get the following message
package php not installed..

Having Problems Getting Mysqli Installed On PHP 5.2.1
I am having problems getting Apache 2.2.4 to read the php_mysqli.dll
file some my C:phpext directory. The following is the error that
Apache displays in the error log:

PHP Warning: PHP Startup: Unable to load dynamic library 'C:/php/ext/
php_mysqli.dll' - The specified procedure could not be found.
in
Unknown on line 0

The file is in the directory, but Apache won't load the file.

Can't Get Php_gd.dll Extension Installed
I am using WinMe, PHP 4.0.6, running Apache. I downloaded the extension, placed it in c:phpextensions. Changed in php.ini: extension_dir=c:phpextensions removed ";" infront of extension=php_gd.dll

Now I can't call any php files, when I try to access a .php file in the browser it just hangs there. No error message appears even after 10 minutes of waiting. If I put the ";" back infront of extension=php_gd.dll, I can again run php scripts, but of course the extension isn't accesible. Igot the gd extension from PHP Everywhere.

PHP Installed As An Apache Module?
I have been searching everywhere for instructions on how to install php as an apache module, rather than my current install which points to php.exe(cgi install) I am running apache on win2000.

Installed Php-4.3.3RC1 On Suse 8.2
I have installed php-4.3.3RC1 on Suse 8.2, and everything went fine
even the make install, but I do not see the new version in yast2
software packages, it still has the old version 4.3.1

any ideas ? is there another step I need to take, how do I check what
is really installed ?

ps apache is 2.0.46 and mysql is 4.1.0

Can PHP Be Installed On WinME Computer?
Is it possible to install PHP on a stand alone WinME computer, and have
the .php files work exactly like they do on an Internet server?

Installed PHP And Now Apache Won't Start
I installed Apache 2.2.3 per the instructions in the book I'm reading
'AJAX and PHP' by Darie et al. After installation, I confirmed that the
server was working. I then installed MySQL and PHP. After configuring
the system per the book's instructions, I now find that the Apache
server won't start.

What To Do If You Can't Get The GD Image Library Installed?
What can you do if your host will not install the GD library for images? are there any alternatives that you can FTP up?


Copyright © 2005-08 www.BigResource.com, All rights reserved