Re: [PHP] PHP newbie question on xslt

2007-03-26 Thread Miguel J. Jiménez
Timothy Murphy escribió: I've been trying some of the programs in the PHP manual at in chapters CLXXXI and CLXXXII to work, for example // Example 2519. Creating an XSLTProcessor load($xsl_filename); $xsl->importStyleSheet($doc); $doc

Re: [PHP] php newbie question with xml files

2005-05-04 Thread Jason Barnett
PHP5: http://php.net/manual/en/ref.dom.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] php newbie question with xml files

2005-05-04 Thread disguised.jedi
> I have an xml document storing some data I need. What I want to do is this: > 1. Scan to the end of the file. > 2. Find the closing tag. > 3. Insert a new entry in before the closing tag. There are specific classes and functions in the PHP core that can help you do just this. > I've tried: > 1.

Re: [PHP] php newbie question with xml files

2005-05-04 Thread Mark Cain
This should get you started: $old_data = file_get_contents('./test.txt'); $my_data = "foo bar"; $pattern = '/(.*)(<\/.*>)$/i'; $replacement = '$1' . $my_data . '$2'; $new_data = preg_replace($pattern, $replacement, $old_data); echo $new_data; or a little more succinctly $my_data = "foo bar"; $n

Re: [PHP] php newbie question with xml files

2005-05-04 Thread Mark Cain
This should get you started: $old_data = file_get_contents('./test.txt'); $my_data = "foo bar"; $pattern = '/(.*)(<\/.*>)$/i'; $replacement = '$1' . $my_data . '$2'; $new_data = preg_replace($pattern, $replacement, $old_data); echo $new_data; or a little more succinctly $my_data = "foo bar"; $n

RE: [PHP] php NEWBIE Question

2003-08-24 Thread Dennis Dujan - Partycult.de
Ok thank you very much -Ursprungliche Nachricht- Von: Chris Kay [mailto:[EMAIL PROTECTED] Gesendet: Montag, 25. August 2003 01:37 An: 'Dennis Dujan - Partycult.de' Betreff: RE: [PHP] php NEWBIE Question Try http://au.php.net/manual/en/function.fsockopen.php If your loo

Re: [PHP] php NEWBIE Question

2003-08-24 Thread Curt Zirzow
* Thus wrote Dennis Dujan - Partycult.de ([EMAIL PROTECTED]): > Hi, > can you tell me how is it possible to connect to a linux shell via PHP? Ok, i suppose I should reply to this before you ask the same question with less details, again. Please be a little more specific in your question, like wha

Re: [PHP] PHP Newbie question

2002-11-18 Thread Maxim Maletsky
Steps: 1. Install PHP. Already installed? 2. make a file accessible via browser and call it test.php 3. put this into it: "; phpinfo(); ?> 4. Now, access that file. If you see "Hello World" outputted followed by a long blue-gray table with lots of server data -

Re: [PHP] PHP Newbie question

2002-11-18 Thread Stolen
http://www.php.net/manual/en/tutorial.php Bryan Cassidy wrote: This might sound stupid but what the hell. I am running Red Hat 8.0 with Apache. I have apache working fine right now. I am wanting to learn some php but really don't know where to start/look or anything to tell the truth. I do "eve

RE: [PHP] PHP newbie question

2001-01-11 Thread Ignacio Vazquez-Abrams
On Thu, 11 Jan 2001, Neil Zanella wrote: > > You are right. According to the PHP manual there is no boolean type > as none is listed in chapter 2.6 but there are variables called TRUE and > FALSE which evaluate to a true value and a false value respectively as > indicated in chapter 2.8. Thanks f

RE: [PHP] PHP newbie question

2001-01-11 Thread Neil Zanella
You are right. According to the PHP manual there is no boolean type as none is listed in chapter 2.6 but there are variables called TRUE and FALSE which evaluate to a true value and a false value respectively as indicated in chapter 2.8. Thanks for quoting from chapter 9. I should be paying more

RE: [PHP] PHP newbie question

2001-01-11 Thread Bryne Jørg Vidar
ion... hence $a is evaluated to "", or 0 if compared to numbers, false if compared to boolean. -Jørg -Original Message- From: Neil Zanella [mailto:[EMAIL PROTECTED]] Sent: 10. januar 2001 19:33 To: Toby Butzon Cc: PHP General Mailing List Subject: Re: [PHP] PHP newbie

Re: [PHP] PHP newbie question

2001-01-10 Thread Hsieh, Wen-Yang
- Original Message - From: "Neil Zanella" <[EMAIL PROTECTED]> To: "Hsieh, Wen-Yang" <[EMAIL PROTECTED]> Cc: "PHP General Mailing List" <[EMAIL PROTECTED]> Sent: Wednesday, January 10, 2001 1:11 PM Subject: Re: [PHP] PHP newbie question

Re: [PHP] PHP newbie question

2001-01-10 Thread Neil Zanella
On Wed, 10 Jan 2001, Hsieh, Wen-Yang wrote: > "" is false. The following three seem to be the same in PHP3: 1) false 2) "" 3) 0 I guess that "" is automatically cast to 0 or to false wherever an integer is required. Where can I find the exact casting rules in PHP3/4 ? Thanks, Neil -- PHP

Re: [PHP] PHP newbie question

2001-01-10 Thread Hsieh, Wen-Yang
- Original Message - From: "Neil Zanella" <[EMAIL PROTECTED]> To: "PHP General Mailing List" <[EMAIL PROTECTED]> Sent: Wednesday, January 10, 2001 11:58 AM Subject: Re: [PHP] PHP newbie question > > > > "" is false. &

Re: [PHP] PHP newbie question

2001-01-10 Thread Neil Zanella
Thanks and sorry about the confusion... true == 1 and false == 0. To summarize this discussion: 1) Unset variables evaluate to the empty string: outputs the string "something" outputs the string "something" Note that $a == $b evaluates to true even though $a is not set b

Re: [PHP] PHP newbie question

2001-01-10 Thread Joe Stump
This is my weekly flamebait on the subject of unset variables and checking against those. isset() fails on form elements (ie a text box that is left empty) therefore the variable will be set, but it will be set to '' - to check thoroughly you would have to do if(isset($var) && !empty($var)) or,

Re: [PHP] PHP newbie question

2001-01-10 Thread Dave M.
AIL PROTECTED]> To: "Toby Butzon" <[EMAIL PROTECTED]> Cc: "PHP General Mailing List" <[EMAIL PROTECTED]> Sent: Wednesday, January 10, 2001 10:33 AM Subject: Re: [PHP] PHP newbie question > > On Wed, 10 Jan 2001, Toby Butzon wrote: > > > : > >

Re: [PHP] PHP newbie question

2001-01-10 Thread Cynic
since when is false equal to one? in PHP, false is represented by string(0) "", and true by 1. so, you really want At 19:33 10.1. 2001, Neil Zanella wrote the following: -- >On Wed, 10 Jan 2001, Toby Butzon wrote: > >> : >> >> $a

Re: [PHP] PHP newbie question

2001-01-10 Thread Neil Zanella
On Wed, 10 Jan 2001, Toby Butzon wrote: > : > > $a evaluates to false, the ! reverses it, and it prints "Hello, World!" What is bothering me is the following: if variables that are not assigned a value were to evaluate to false then since false is the same as the number 1 the following PHP sc

Re: [PHP] PHP newbie question

2001-01-10 Thread Toby Butzon
- Original Message - From: "Neil Zanella" <[EMAIL PROTECTED]> To: "PHP General Mailing List" <[EMAIL PROTECTED]> Sent: Tuesday, January 09, 2001 11:55 PM Subject: [PHP] PHP newbie question : : Hello, : : I have a question regarding the following 3 one line .php files: : : isset($a) ret