Re: [PHP] unset()- newbie question

2001-05-22 Thread Chris Sano

?

$array[ 'test' ] = chris;
echo before  . $array[ 'test' ] . br;

unset( $array[ 'test' ] );
echo after  . $array[ 'test' ];

?

returns:
before chris
after

hence, the unset function works fine for me. what version of php are you
running?


Tom [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 I can't seem to get unset() to work when I'm strying to delete an
 element from an array.

 I have a select list that is populated by an array, and i need to
 be able to delete items from the list by deleting them from the
 array, but I don't know how.

 I tried using unset($array['element']); but it doesn't work.
 Does anyone know why?
 Does anyone know of a way to use array_diff() to delete elements
 from an array?

 Thanks,
 Tom







 --
 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]




-- 
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]




Re: [PHP] PHP and XHTML

2001-05-20 Thread Chris Sano

XHTML is just making your HTML documents XML ready. This means closing your
tags, etc..

And Rasmus is right when he says PHP is 100% compatible with XHTML.

-C

[EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 i won't pretend to be an XML guru, but isn't saying php won't work with
XHTML akin to saying
 php won't work with javascript1.3, dhtml, netscape 6 etc?
 php generates code...html, dhtml, whatever...i fail to see how php
couldn't generate
 what anyone would need for XHTML, or anything else along those lines

 -jack

 - Original Message -
 From: Rasmus Lerdorf [EMAIL PROTECTED]
 Date: Friday, May 18, 2001 6:59 pm
 Subject: Re: [PHP] PHP and XHTML

   I would like to start using the XHTML syntax for my future
  projects, but I
   heard that PHP is not compatible with XHTML. For example, in
  XHTML the ID
   attribute is used in place of the deprecated NAME tag. But PHP
  depends on
   the NAME attribute in forms, etc. Is there any way around this?
  Has anyone
   used XHTML and PHP together successfully, and if so how did you
  get around
   the previously mentioned problem? Any help woould be much
  appreciated, thanks in advance.
 
  Completely false.  PHP works fine with XHTML.
 
  -Rasmus
 
 
  --
  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: php-list-
  [EMAIL PROTECTED]
 



 --
 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]




-- 
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]




Re: [PHP] Network Connectivity help please

2001-05-20 Thread Chris Sano

You could always do a cron job and have a script run every 10-15 minutes,
load the existing and connecting IP's in a text file and use another script
to print out the latest successful pings.

-C

Brian [EMAIL PROTECTED] wrote in message
9e4msm$e5a$[EMAIL PROTECTED]">news:9e4msm$e5a$[EMAIL PROTECTED]...
 Good point, I considered, doing it that way, I was just hoping that there
 might be a 'prettier' way to do it from within PHP.  Right now I'm using
 fping from within a php loop that steps through the class C.  The machine
 I'm doing this on is dog slow though, so I'm hoping that when I move the
 final version over to our main webserver it will run the script at an
 acceptable speed.  If not though, I have a feeling that I will most likely
 implement your suggestion, unless someone knows of the 'pretty' solution
 that I seek :)

 Brian
 He did not know the strength of my Kung fu
 --Wong Fei Hung The Iron Monkey

 Mohamed LRHAZI [EMAIL PROTECTED] wrote in message
 [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
  Brian,
 
  Why don't leave the pinging to some other script, and have that other
  script run continuesouly and upfate a sql table with the ststus of each
  and time stamp of when it was last ping'ed...etc
 
  Mohamed~
 
  Brian wrote:
  
   I'm writing a script to help us manage one of our Class C networks.
The
   page loads all of the host IPs, who owns them, phys desc. of the box,
 and
   does a forward reverse lookup on all of the addresses.  I'd like to
add
 a
   column that shows which machines are currently reachable on the
network.
 A
   simple ping would probably be easiest, but parsing a standard ping for
 254
   hosts would cause the script to have about a 10 minute load time. are
 there
   any quick easy, and most importly, low system overhead, solutions to
 this
   problem?
  
   Brian Artiaco
   [EMAIL PROTECTED]
  
   --
   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]
 
  --
  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]
 



 --
 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]




-- 
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]




[PHP] .phps on win32 (IIS5)

2001-05-18 Thread Chris Sano

Does anyone know how to create a PHP source file (.phps) in windows? I tried
looking on the PHP site and had no luck.. Any help would be greatly
appreciated..

Am running IIS5.0 with PHP4.0.5

Thanks!




-- 
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]