Re: setting function variables
| From: | Mark | Date: | Thu, 07 Aug 2003 19:52:31 +0000 |
| Subject: | Re: setting function variables | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-158723@lists.php.net to get a copy of this message | ||
Use a database abstraction class (ADODB, Pear, or something from
phpclasses.org). You're trying to assign a variable to a function's
actions, when you can only assign the variable to teh ooutput of the
function.
--- Micah Montoy <montmica@isu.edu> wrote:
> I am trying to specify a single php file to contain all the
> variables and I
> just call this file where necessary. What I am running into is
> that I want
> to do this for all the built in functions (i.e. mssql_query) as
> well. I've
> tried numerous attempts but can't get it to operate without wanting
> to run
> the functions or return an error. Something like this:
>
> $runQuery = @mssql_query;
> $qryResults = @mssql_result;
> $getRow = @mssql_fetch_row;
> $getRowNums = @mssql_num_rows;
>
> I've tried using the %, $, "",'', and the @ symbol without any
> luck. Anyone
> know of way to do this, so I can use a generic name for all the
> functions
> and be able to distribute it to those using either SQL Server or
> MySQL
> without them having to go through the code and manually change it?
>
> thanks
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
=====
Mark Weinstock
mark_weinstock@yahoo.com
***************************************
You can't demand something as a "right" unless you are willing to fight to death to
defend everyone else's right to the same thing.
***************************************
__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com