Re: [PHP] Can't even make a simple test RSS feed

2005-06-30 Thread Richard Lynch
On Fri, June 24, 2005 12:23 pm, Brian Dunning said:
 What am I doing wrong? This doesn't work. The browser does not even
 load the page, no error or anything:

 ?php

 echo '?xml version=1.0?rss version=2.0channel';
 echo 'item';
 echo 'titlehdfghdf/title';
 echo 'descriptiondfghdfh/description';
 echo 'linkhttp://somelink/link';
 echo '/item';
 echo '/channel/rss';

 ?

Now that you've got the browsers fooled with a .rss extension, go back
and rip out all those silly echo statemnts :-)

More seriously, unless this was just a test to make sure PHP was working
you really don't even need PHP for 90% of what you typed...

:-)

I'm assuing you'll actually put more complex PHP code in there now, but I
couldn't resist.

More seriously, you probably should have some embedded newlines in there,
even for the silly example that it is.

As it stands now, your XML is one giant long line.

Maybe XML parsers don't care, but the people who have to read your script
output *DO* care.

Take care that your PHP output is readable, as well as your PHP source.

Your PHP output *IS* source, or it will be to somebody, somewhere,
someday, if your site gets any traffic at all.

-- 
Like Music?
http://l-i-e.com/artists.htm

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



[PHP] Can't even make a simple test RSS feed

2005-06-24 Thread Brian Dunning
What am I doing wrong? This doesn't work. The browser does not even  
load the page, no error or anything:


?php

echo '?xml version=1.0?rss version=2.0channel';
echo 'item';
echo 'titlehdfghdf/title';
echo 'descriptiondfghdfh/description';
echo 'linkhttp://somelink/link';
echo '/item';
echo '/channel/rss';

?

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



Re: [PHP] Can't even make a simple test RSS feed

2005-06-24 Thread Joe Muddah
go view-source in your browser. Some browsers will not show the xml
all though it is in the source

On 6/24/05, Brian Dunning [EMAIL PROTECTED] wrote:
 What am I doing wrong? This doesn't work. The browser does not even
 load the page, no error or anything:
 
 ?php
 
 echo '?xml version=1.0?rss version=2.0channel';
 echo 'item';
 echo 'titlehdfghdf/title';
 echo 'descriptiondfghdfh/description';
 echo 'linkhttp://somelink/link';
 echo '/item';
 echo '/channel/rss';
 
 ?
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 


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



Re: [PHP] Can't even make a simple test RSS feed

2005-06-24 Thread Brian Dunning
I'm ahead of you there - that's not the problem. IE6 just acts like I  
didn't request a page. Safari returns a “unknown  
error” (NSURLErrorDomain:-1).

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



Re: [PHP] Can't even make a simple test RSS feed

2005-06-24 Thread Kevin L'Huillier
 On 6/24/05, Brian Dunning [EMAIL PROTECTED] wrote:
 What am I doing wrong? This doesn't work. The browser does not even
 load the page, no error or anything:

The script looks fine and executed as expected on my machine.

Try executing it from the command-line.   Often if nothing loads in
the browser, it is an error causing PHP to not send anything to the
web server, even its normal errors.

If you are using IIS it might also be the ISAPI module which has been
notorious for stability.  Restarting the Web Publishing Service
sometimes helps.

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



Re: [PHP] Can't even make a simple test RSS feed

2005-06-24 Thread Nicolas Diez
Well, I don't know if I have the solution, but when the page has the
..php file extension it doesn't work. But when it has the .rss file
extension, it works. It's the workaround I found.
Safari doesn't return an error now. 
I've tested the script under MacOSX 10.4.1 with Apache 2.0.54 and PHP 5.04.
Hope this will help you.

On 6/24/05, Brian Dunning [EMAIL PROTECTED] wrote:
 I'm ahead of you there - that's not the problem. IE6 just acts like I
 didn't request a page. Safari returns a unknown
 error (NSURLErrorDomain:-1).
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 


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