Re: [PHP] Updating inherited attributes without __construct()

2008-06-06 Thread Tyson Vanover
or anything, im merely offering it as an alternative to your current solution. -nathan On Thu, Jun 5, 2008 at 12:15 PM, Tyson Vanover [EMAIL PROTECTED] wrote: I have a class that has a list of valid keys, and an array of values. When a value is added to the array it's key is first checked

[PHP] Updating inherited attributes without __construct()

2008-06-05 Thread Tyson Vanover
I have a class that has a list of valid keys, and an array of values. When a value is added to the array it's key is first checked against the list of valid keys (this is to prevent injection issues we have been having later on in the project). class parent{ private $validkeys =

[PHP] Quickly verifying single word.

2008-06-04 Thread Tyson Vanover
I need a quick way to make sure that a string is a single word with no white spaces. I would prefer that it is a command that could fit on a single line. Or at least an if block. I have a few thoughts on this but it involves things like explode(), stripslashes(), etc. -- PHP General

[PHP] Still not getting Includes right.

2008-05-19 Thread Tyson Vanover
So have developed some nice tools for generating forms, connecting to databases, things that I do repeatedly. When I run test pages that include these utility files in the same directory as the utility files it works fine. The are included no problem. As soon as I have scripts in other

[PHP] Re: Still not getting Includes right.

2008-05-19 Thread Tyson Vanover
Nevermind, working. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Still not getting Includes right.

2008-05-19 Thread Tyson Vanover
nevermind. It is working now. Thanks all! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Problems with includes

2008-05-16 Thread Tyson Vanover
I am trying to keep my tools and pages segregated for a variety of reasons (organization, security, etc). And I am having problems with my includes on my LAMP box. My user facing tools are not including my utility classes and files. The root directory of my web server (www.hostname.com/)

Re: [PHP] Problems with includes

2008-05-16 Thread Tyson Vanover
Dan Joseph wrote: I'm pretty sure you're gonna need to include the entire path: require( /srv/www/html/Tools/tool2/tool2.php ); for both of your tools. So when php runs it's paths are drawn from the OS's structure and not apache's? hun. thanks! -- PHP General Mailing List

Re: [PHP] Problems with includes

2008-05-16 Thread Tyson Vanover
Jim Lucas wrote: Their are two ways that come to mind. 1. Like Dan suggested, use the full path. 2. (I prefer this way), change your include_path setting either in your php.ini file, virtual host, .htaccess or in your script to include the base path for your web site /srv/www/html/ and then

Re: [PHP] Problems with includes

2008-05-16 Thread Tyson Vanover
Jim Lucas wrote: Their are two ways that come to mind. 1. Like Dan suggested, use the full path. 2. (I prefer this way), change your include_path setting either in your php.ini file, virtual host, .htaccess or in your script to include the base path for your web site /srv/www/html/ and then

Re: [PHP] Problems with includes

2008-05-16 Thread Tyson Vanover
Dan Joseph wrote: Ok, I have changed my php.ini and restarted apache. My include_path is set to include_path = .:/srv/www/html but when I try from /srv/www/html/library/index.php: require '/Tools/dbtools/dbtool.php'; or require 'Tools/dbtools/dbtool.php'; or require

Re: [PHP] Problems with includes

2008-05-16 Thread Tyson Vanover
Jim Lucas wrote: Possibly that apache is chroot'ed. I know you said LAMP. But which OS/etc... Sometimes you can see from the cli if httpd is rooted. run 'ps aux | grep httpd' and see if httpd says anything about chroot I don't see anything here root 1937 0.0 5.2 25600 13456 ?

[PHP] Tracking down the elusive expecting T_PAAMAYIM_NEKUDOTAYIM

2008-05-14 Thread Tyson Vanover
I have a class that is throwing the error: syntax error, unexpected ')', expecting T_PAAMAYIM_NEKUDOTAYIM ... It is appearing in the constructor of a parent class abstract class parent { protected $titles = array('title1','title2','title3'); protected $a; function

[PHP] Re: Two word array Value

2008-05-14 Thread Tyson Vanover
Mark Bomgardner wrote: When I submit the form I am only getting the following having checked the boxes for Mail Classroom and Break Out Classroom. If I eliminate the spaces between the words, I get everything, but when I put the spaces between the words in the array, it cuts off the second

Re: [PHP] Tracking down the elusive expecting T_PAAMAYIM_NEKUDOTAYIM

2008-05-14 Thread Tyson Vanover
Daniel Brown wrote: ?php foreach($set as $key = $value) { // You just missed the $ before value. ? This seems to be the culprit. Also, check this line: ?php if (array_key_exists($key,$this-titles) ? You're missing a ')' to close the if() statement. It's not causing

[PHP] Variable Scope from child to parent

2008-05-14 Thread Tyson Vanover
I am trying to get a child class to pass an array of valid keys to it's parent when the constructor is run, and the parent appends the data to one of it's array of valid keys. Then it walks through an array pulling out values that have valid keys, and putting them in an array for processing

Re: [PHP] Mic check 1, 2, 3...

2008-05-14 Thread Tyson Vanover
tedd wrote: At 1:50 PM -0700 5/14/08, Jim Lucas wrote: Just wondering if the mailing list is working. I have not received anything from this list today. -- Jim Lucas If you don't receive this, please let me know. Cheers, tedd Wait... the recursive not testing of that statement just