Re: Making Php Libraries

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am new to this list so forgive me if this has already been addressed. What I would like to do is keep a library of php scripts on my site. I would like customer sites to call the functions in my library, but have their server do the work. I would like to keep the proprietary code off of their site. I have been able to do this by changing the extension of the library file from php to inc. Unfortunately, this also makes the library file readable if the user puts the url for the file into the browser. Thanks.

Chris Taylor

Chris:

Interesting problem.

First, I don't immediately see the need to change the file's suffix to .inc.

However, considering the apparent need, you may want to use a password and logon to access your library folder/directory.

Granted, the client would be able to see the logon and password if they viewed their client code, but you might make it for them difficult by mixing their client ID with current date for logon. They would both need to understand what's happening AND know that they will identify themselves in stealing your code. Your logs could show who accessed what.

You can access a protected folder via curl operation and require that for your client's php code access to your library via authorization. I've done a similar thing in connecting a Macintosh application to an on-line mySQL dB.

In any event, that's where I would start.

HTH's.

tedd
--
--------------------------------------------------------------------------------
http://sperling.com/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux