Re: [PHP] PHP Interview questions

2003-08-26 Thread Michael A Smith
CPT John W. Holmes wrote:

From: Jay Blanchard [EMAIL PROTECTED]

 

Also ask a couple of other questions that require thought, but have
nothing else to do with code. such as...
In one room you have 3 light switches, each connected to one light bulb
in another room. How many trips must you make to determine which switch
is connected to which light bulb?
   

PHP is server side, so it obviously cannot control light bulbs. Use
javascript.
---John Holmes...

 

That was good. :)

-Michael

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


[PHP] HELP! I'm Desperate...

2003-08-19 Thread Michael A Smith
Hi,

I'm going off to school and won't have computer access for like 9 
months... :-\ .. and I need someone with a couple of hours every week to 
monitor my CMS for bug reports, and to fix bugs (if they want). I would 
appreciate it so much. The project resides at: 
http://sourceforgen.net/projects/prattcms/. Please let me know in the 
next week!

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


Re: [PHP] (^*$*(^*$% ensim web appliance

2003-08-19 Thread Michael A Smith
Do you have

AllowOverride All

in your httpd.conf file for that dir?

-Michael
Dennis Gearon wrote:
please cc me 

Anyone on a shared, name-based IP, ensim web appliance hosted website?

Can you tell me how to set the freekin':

php_value auto_prepend_file 
/some_freekin_unknown_real_directory_path_to_HOME/my_paths/prepend.php

value in my .htaccess file?




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


Re: [PHP] READ RECEIPTS [WAS: $GLOBAL question]

2003-08-18 Thread Michael A Smith
Would all who are, quit requesting read receipts on their messages? 
It's really annoying and I don't think you want to know of the 100+ 
users on this list how many read the message...

Thanks!
-Michael
Robin Kopetzky wrote:
Good Morning!!

I'm trying to print $GLOBALs this way and it doesn't work:
?php
   $aTest = This is a test;
   
   function GlobalCheck()
   {
   print {$GLOBAL['aTest']};
   }
   
   GlobalCheck();
?
Does someone know the 'right' way to do this??

Robin 'Sparky' Kopetzky
Black Mesa Computers/Internet Service
Grants, NM 87020 

 



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


Re: [PHP] READ RECEIPTS [WAS: $GLOBAL question]

2003-08-18 Thread Michael A Smith
Dan Anderson wrote:

On Mon, 2003-08-18 at 17:22, Robert Cummings wrote:
 

This is pretty off topic -- but most clients also let you refuse to send
receipts automatically -- which is how I deal with them.
   

Yes but read reciepts do exist for a purpose.  If you happen to work at
a place where you /want/ read receipts to be replied to that doesn't
work.  :)  However if that is this guys case he should create a second
account for mailing lists only and block read receipts till his hearts
content.
-Dan
 

My point exactly.

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


Re: [PHP] READ RECEIPTS [WAS: $GLOBAL question]

2003-08-18 Thread Michael A Smith
Thanks, I'd forgotten about that setting which I just did... I'm sorry 
if everyone feels I've been too harsh, but I'm not saying I'm sorry for 
what I said. :-)

-Michael
Robert Cummings wrote:
This is pretty off topic -- but most clients also let you refuse to send
receipts automatically -- which is how I deal with them.
Cheers,
Rob.
On Mon, 2003-08-18 at 17:04, Dan Anderson wrote:
 

p.s. Is there not an option on your mail reader to automatically send
read receipts? I mean, can't you have it by default send the receipt
instead of requesting your intervention? If not, you might like to think
about getting a better client. thanks!
 

You ever open a spam and 30 seconds later get a follow up spam?  That's
what happens from automatically sending read reciepts.  Also, spammers
love to use them as a tool to figure out who actually reads spam -- even
if you just click on it for a second to press the DEL key.
However, so many people request read reciepts that even though I wish
they didn't exist I can't see complaining to a mailing list about them.
-Dan
   

 



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


Re: [PHP] Mail() Problem Sending

2003-08-18 Thread Michael A Smith
My ideas: (in order of likelihood)

Idea #1: Your computer hates you.
Idea #2: Sendmail isn't running.
Idea #3: Sendmail isn't setup correctly.
Idea #4: You have been hacked by Saddam.
-Michael

:-)
Ben C. wrote:
I have recently had php installed on my server with sendmail.  The server is behind a firewall and SMTP is open on the firewall.  However, when I execute the mail(), it appears to have sent the mail, but I never receive it.  I am not getting any error messages.  Has anyone ever run into this problem?  Does anyone have any ideas?

 



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


Re: [PHP] project management php system

2003-08-14 Thread Michael A Smith
I've developed PrattCMS... (Try out the latest RC, it's quite stable and 
note that 2.0 will be out later today or tomorrow depending...).

It's:
-GPL'ed
-PHP/MySQL (Could support other databases, with small amount of work.)
-Has an error reporting class to send notes when a db query fails (by 
e-mail).
-Has an in-line WYSIWYG editor that runs in IE 5.5+ and Mozilla 1.3+.
-Has a _really_ easy way to install/switch templates.
-Uses .xml files that exist inside the right directory to get 
information about each template.
-Creating a new template is easy... just look at the four provided, 
use smarty templates, and look at and *.xml file in the templates/ 
directory.
-Switching templates is as easy as clicking 1 button.
-Has customizable style-sheet values.
-Works fine with web spiders (uses ?id=num to get different files).
-Doesn't require register_globals (never tested with register_globals 
on... ought to work though).
-Has user groups so that only certain users are allowed to create new 
users/edit site-wide configuration/change templates and you can even 
restrict which pages they are allowed to modify as well as whether they 
are allowed to create new pages or not.
-Has a front-page module so you can have an entry page (you can disable 
by emptying the modules table, but then you'll have to make a simple 
modification so that your home page will exist... you can ask me later 
if you want)
-You can backup all your information (pages, database configuration, 
downloads you've uploaded, images you've uploaded... requires --with-zlib)
-Has stats: Number of visitors, Country graph of where you're users come 
from, Browser detection, Most visited pages, Where the users came from, 
Graph of Hourly visits (does _not_ require GD).
-Has a SELECT only Database viewer that runs in PEAR::DB (just like the 
rest of the CMS).

It shouldn't be too hard to customize if you need to. You can create new 
templates/etc., obviously for yourself.

Webpage:
http://prattcms.sourceforge.net/
(You can try it out by visiting: http://opensourcecms.com/ and clicking 
the PrattCMS link on the left hand side.)

HTH!
-Michael
[EMAIL PROTECTED] wrote:
Hi guys ok i am doing it now, but i'm not asking for you to code something
for me, i'm looking for a classy project management system possibly in an
open source format in PHP and Mysql.
I was wondering who has implemented such a system they could recommend, i
am investigation to look into customising an already developed system or we
have to develop one from scratch to suit our needs.
Let me know.

Thanks

Dan



 



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


Re: [PHP] PHP - MySQL Query...

2003-08-14 Thread Michael A Smith
Steven Kallstrom wrote:

Hello all...

I'm embarrassed by this one...  I think it should work but it isn't...

$dbh = mysql_connect(localhost, login, password) or
   die('cannot connect to the database because: ' . mysql_error());
mysql_select_db(database);
  $query = 'SELECT * FROM cities';
$result = mysql_query($query); 
Try this instead;
$result = mysql_query($query) or die(Query died:  . mysql_error());
Cheers!

-Michael

  while ($row = mysql_fetch_row($result)) {
   echo ('tr td class=city' . $row[0] . ', ' . $row[1] . '/td
   td' . $row[2] . '/td td' . $row[3] . /td /tr\n); }
getting this error:

*Warning*: mysql_fetch_row(): supplied argument is not a valid MySQL 
result resource in...

so... is the problem with the $query?
I don't see anything wrong (assuming my login and database selection 
is correct)
what are the common errors here?

Thanks,

SJK
**




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


Re: [PHP] PHP- accessing session var

2003-08-14 Thread Michael A Smith
That's what he was doing and he gave us the output. You can have an 
object stored in $_SESSION as long as the class and object were defined 
_before_ you stared the session.

You would therefore access it like this:

$some_var = $_SESSION['object_name']-varname;

Cheers!

-Michael
Chris Shiflett wrote:
--- Mignon Hunter [EMAIL PROTECTED] wrote:
 

When I print_r my session vars part of what get is:
   

Do this:

print_r($_SESSION);

Show us what that outputs.

Your output seemed to infer that you are doing something else when you print_r
your session vars, as _SESSION was listed as a key within another array. I'm
not sure what you're doing there.
Chris

=
Become a better Web developer with the HTTP Developer's Handbook
http://httphandbook.org/
 



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


[PHP] Large PHP Project... Need Project Manager

2003-08-14 Thread Michael A Smith
Hey,

I've got a nice CMS (in quite stable 2.0 form) that I need a Project 
Manager who can just deal with some bugs/answer questions for the next 9 
months while I'm away at school... anyone interested? It would simply 
mean watching bug reports on SourceForge and answering things. Also, if 
you would compile a list of feature requests that people seem to want 
I'll work on them next summer. You can (starting next summer) remain as 
a developer, or just hand the project over to me.

The project is: http://prattcms.sourceforge.net/, which isn't really 
updated for version 2.0 yet. It's licensed under the GPL.

-Michael



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


[PHP] Session Problem

2003-07-03 Thread Michael A Smith
Okay,

I'm starting session with 

session_name(PRATTCMS_ADMIN);
session_save_path($sess_path);
session_start();

This works on one server I have, compiled the almost exact same (except
without png and jpeg support for gd). They both use trans_sid. What's
going on here? In the session path, the session is being created, and
information is being put into it, but when you go to another page, or
another session_start(), it's like the cookie isn't being sent to the
browser. What's going on?

-Michael
-- 
Michael Smith
[EMAIL PROTECTED]

The great thing about democracy is that it gives 
every voter a chance to do something stupid. 
 -Art Spander


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



[PHP] PHP5 - Bugs

2003-07-01 Thread Michael A Smith
Hey,

Can't figure this out... whenever I try to use any mysql functions or
anything, I get problems. PHP throws a DNS error... what's up with that?

-Michael


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



[PHP] Bundled GD Webalizer

2003-06-27 Thread Michael A Smith
I compiled PHP 4.3.2 --with-gd, but now webalizer can't find GD? Where
is it? I tried installing the original library but that's not good
either.

-Michael
-- 
Michael Smith
[EMAIL PROTECTED]

The great thing about democracy is that it gives 
every voter a chance to do something stupid. 
 -Art Spander


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



Re: [PHP] Bundled GD Webalizer

2003-06-27 Thread Michael A Smith
No, you don't understand, I want to know where PHP installs GD.

-Michael
On Fri, 2003-06-27 at 08:06, Adam Voigt wrote:
 PHP did not remove your copy of GD, so this is
 a system question, not PHP.
 
 
 On Fri, 2003-06-27 at 12:03, Michael A Smith wrote:
  I compiled PHP 4.3.2 --with-gd, but now webalizer can't find GD? Where
  is it? I tried installing the original library but that's not good
  either.
  
  -Michael
  -- 
  Michael Smith
  [EMAIL PROTECTED]
  
  The great thing about democracy is that it gives 
  every voter a chance to do something stupid. 
   -Art Spander
-- 
Michael Smith
[EMAIL PROTECTED]

The great thing about democracy is that it gives 
every voter a chance to do something stupid. 
 -Art Spander


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



[PHP] ATTN: Steve Marquez [ Fwd: Re: [PHP] php.ini]

2003-06-25 Thread Michael A Smith
Take a look at this message first.
---BeginMessage---
Does the php.ini file always go in the same place no matter the OS? I 
did a
locate in the shell, and nothing came up. I could find .ini files, or 
php.
files, but no php.ini files.
In all likelihood, you don't have a php.ini file on your computer, 
which is why searching for it using conventional methods won't help. To 
create a php.ini file, you could download the PHP source code, take its 
php.ini and drop it in /usr/local/lib

Larry

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



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

[PHP] Sybase and PHP

2003-06-25 Thread Michael A Smith
Hi,

I want to connect to a Sybase database running on another windoze server
without having to a buy a copy of sybase for linux. How can I compile
PHP to have the sybase functions, but not the local database program.

-Michael
-- 
Michael A Smith [EMAIL PROTECTED]


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



[PHP] Search Engine

2003-06-20 Thread Michael A Smith
Hi,

I'm trying to find a script (PHP,Perl, Whatever) that will search
through a bunch text files, ignore certain keywords, and then generate a
text file with the line that each one is on, and what the words were.

Thanks,
-Michael


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



Re: [PHP] New word proposition (was: Re: [PHP] HTML and PHP)

2003-06-05 Thread Michael A Smith
Sounds good to me...
On Wed, 2003-06-04 at 12:49, Evan Nemerson wrote:
 Well since you seem to be in favor of confining usage to PHP, what about 
 phode- that way there's no association with the bullshit notices on 
 commercial advertisements that mean nothing since the address is always 
 either broken or just confirms your address... 
 
 
 On Wednesday 04 June 2003 01:43 pm, you wrote:
  Lol. That's pretty good. I think it sounds good. Ode tho is
  questionable... what about opt (ie _O_pening _P_hp _T_ag)?
 
  -Michael
 
  On Wed, 2003-06-04 at 12:36, Evan Nemerson wrote:
   Clode? I like it. Really, who wants to say closing php tag,
   terminating php tag, or whatever you say. Why not start calling it a
   clode? What does everyone else think?
  
   The only issue is if a closing php tag (or should it be a more general
   closing tag, with php being able to serve as a modifier when required,
   ie php clode) is a clode, would an opening [php] tag be an ode?
  
   Comments?
  
   On Wednesday 04 June 2003 12:47 pm, Christian Ista wrote:
Hello,
   
Look the code below. Is it an obligation to multiply the number of
?php ?. There is no other way ? not possible to use only an open php
tag (?php) and a clode php tag (?)  ?
   
Christian,
   
   
?php
   switch($constant_lastupdate[$i][3]){
   case '1' :?
img src=design/logo_windows.gif alt= width=12 height=10
border=0
?php
break;
   case '2' :?
img src=design/logo_mac.gif alt= width=10 height=10
border=0 ?php
break;
   case '3' :?
img src=design/logo_linux.gif alt= width=9 height=11
border=0
?php
break;
   }
  ?
  
   --
   Two hands working can do more than a thousand clasped in prayer.
  
   -Unknown


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



[PHP] POST Variables get passed as GET variables.

2003-06-05 Thread Michael A Smith
Hey,

So I've got this form that passes POST variables. However, they keep
getting passed as get variables. Example:

form action=?php echo $_SERVER['PHP_SELF']; ? method=post
input type=hidden name=action value=something
input type=submit value= Action 
/form

Get's sent to it as:

url.php?action=something

What's going on here? This is a new installation of PHP 4.3.1, Apache
1.3...

-Michael


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



[PHP] OpenSource PHP Project

2003-06-04 Thread Michael A Smith
Hi,

Anyone interested in helping out with an opensource CMS project.
PHP/MySQL/Smarty Templates/Modules checkout prattcms.sf.net. It's
different from other CMSs in that it is not user-driven. The pages use a
WYSIWYG editor (inline, htmlarea, also open-source). 

Thanks!

-Michael


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



[PHP] PEAR DB Error

2003-03-13 Thread Michael A Smith
Hello,

I am using a script running PEAR. I did a:
$db = DB::connect($database_string);
at I get the error:
Fatal error: Undefined class name 'db' in
/var/www/html/prattcms/variables/global.inc.php on line 17

Any ideas?

-Michael
-- 
Some people's minds are like cement; all mixed up and permanently set.



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



[PHP] trailing slash

2003-03-04 Thread Michael A Smith
Hi all,

How come some servers (like one of our RH7.3s) can accept a 
www.somewhere.com/foldername without the trailing slash and others (like
my RH8.0) gives a 404 error?

-Michael
-- 
Some people's minds are like cement; all mixed up and permanently set.
  Life is full of obstacle illusions.
  Don't buy antique furniture, it never lasts.
  I'm related to people to whom I don't relate. -Calvin ( Hobbes)
  An elephant is actually a mouse designed by a committee.


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



[PHP] Convert *.PST Files to Something Else (LDAP...)

2003-02-21 Thread Michael A Smith
Hi,

Is there any way using PHP (or any thing else, preferably PHP) to
convert a MS Outlook *.PST file to another file that would be usable by
PHP, using only PHP scripts, or even a CGI? I am working on an
open-source project called falconmail that needs to be able to import
all sorts of mail files from people's old programs.

Thanks,
-Michael
-- 
Some people's minds are like cement; all mixed up and permanently set.
  Life is full of obstacle illusions.
  Don't buy antique furniture, it never lasts.
  I'm related to people to whom I don't relate. -Calvin ( Hobbes)
  An elephant is actually a mouse designed by a committee.


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



[PHP] MySQL Functions Setup

2003-01-23 Thread Michael A Smith
Hello All,

I'm trying to setup a RedHat Psyche (8.0) server. So far, all well.
However, I just ran into a problem with MySQL. PHP doesn't have the
MySQL functions in it. Is there another way to install those without
having to re-compile PHP?

Thanks for any and all help,

-Michael Smith

Some peoples minds are like cement; all mixed up and permanently set.




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




[PHP] variable scope -- unsetting vars inside functions

2001-03-01 Thread Michael A. Smith

When a function finishes execution does it automatically clean up its local
variables or should I manually unset() them? For example:

function do_something() {
$local_var = 'something really big...';
return true;
}

Does $local_var immediately vanish from existence when do_something finishes
executing?

Thanks!
--
Michael A. Smith [EMAIL PROTECTED]
Director of Data Systems, wcities.com
ICQ: 35884415
:wq



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]