470,870 Members | 1,475 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,870 developers. It's quick & easy.

Display HTML before PHP output?

I have a menu that outputs an RSS newsfeed using a PHP script (CaRP -
http://www.geckotribe.com/rss/carp)...however it ALWAYS displays the PHP
outputted HTML before the embedded HTML. This happens regardless of the
order; HTML first PHP second, or visa versa. I am assuming that the PHP
engine writes the PHP output first by default??

Is there a way to force the PHP to output in the order it is
"written"...at least, can I control it?

TIA,

Miki
Jul 17 '05 #1
7 3118
Michelle <miki_b@spam_me.org> wrote or quoted:
I have a menu that outputs an RSS newsfeed using a PHP script (CaRP -
http://www.geckotribe.com/rss/carp)...however it ALWAYS displays the PHP
outputted HTML before the embedded HTML. This happens regardless of the
order; HTML first PHP second, or visa versa. I am assuming that the PHP
engine writes the PHP output first by default??


Not correct - it /normally/ behaves the way you say you want it to.
--
__________
|im |yler http://timtyler.org/ ti*@tt1lock.org Remove lock to reply.
Jul 17 '05 #2
Tim Tyler wrote:
Michelle <miki_b@spam_me.org> wrote or quoted:

I have a menu that outputs an RSS newsfeed using a PHP script (CaRP -
http://www.geckotribe.com/rss/carp)...however it ALWAYS displays the PHP
outputted HTML before the embedded HTML. This happens regardless of the
order; HTML first PHP second, or visa versa. I am assuming that the PHP
engine writes the PHP output first by default??

Not correct - it /normally/ behaves the way you say you want it to.

So how do I make it behave the way I want it to...?
Jul 17 '05 #3
*** Michelle escribió/wrote (Sun, 12 Sep 2004 00:14:55 GMT):
So how do I make it behave the way I want it to...?


Write then in the order you want them.

Won't you tell us how you're doing it?

--
-+ Álvaro G. Vicario - Burgos, Spain
+- http://www.demogracia.com (la web de humor barnizada para la intemperie)
++ Las dudas informáticas recibidas por correo irán directas a la papelera
-+ I'm not a free help desk, please don't e-mail me your questions
--
Jul 17 '05 #4
Alvaro G. Vicario wrote:
*** Michelle escribió/wrote (Sun, 12 Sep 2004 00:14:55 GMT):
So how do I make it behave the way I want it to...?

Write then in the order you want them.

Won't you tell us how you're doing it?

I am writing them in order, in fact they HTML creates a table and the
PHP is placed in the LAST row. The funny thing is that when you view
the source it is correct; HTML first and PHP at the end. The display is
not so...both with Mozilla and IE.

Look here:
http://s92414411.onlinehome.us/index.php

The menu (which I helped write and have been trying to fix for the
owner) is an include.

Miki
Jul 17 '05 #5
*** Michelle escribió/wrote (Sun, 12 Sep 2004 16:09:08 GMT):
I am writing them in order, in fact they HTML creates a table and the
PHP is placed in the LAST row. The funny thing is that when you view
the source it is correct; HTML first and PHP at the end. The display is
not so...both with Mozilla and IE.
Then I'd say that there's something wrong with your HTML. Of course I can't
tell which part comes from PHP and which doesn't, but a quick look at your
page revelaed code like this:
</tr>
<tr>
</ br></ br><span
Table rows can only contain table cells.

http://s92414411.onlinehome.us/index.php

--
-+ Álvaro G. Vicario - Burgos, Spain
+- http://www.demogracia.com (la web de humor barnizada para la intemperie)
++ Las dudas informáticas recibidas por correo irán directas a la papelera
-+ I'm not a free help desk, please don't e-mail me your questions
--
Jul 17 '05 #6
*** Michelle escribió/wrote (Sun, 12 Sep 2004 16:09:08 GMT):
I am writing them in order, in fact they HTML creates a table and the
PHP is placed in the LAST row. The funny thing is that when you view
the source it is correct; HTML first and PHP at the end. The display is
not so...both with Mozilla and IE.
Then I'd say that there's something wrong with your HTML. Of course I can't
tell which part comes from PHP and which doesn't, but a quick look at your
page revealed code like this:
</tr>
<tr>
</ br></ br><span
Table rows can only contain table cells. Apart from that, there isn't such
tag as </ br>. Pass your site through this app: http://validator.w3.org/

http://s92414411.onlinehome.us/index.php

--
-+ Álvaro G. Vicario - Burgos, Spain
+- http://www.demogracia.com (la web de humor barnizada para la intemperie)
++ Las dudas informáticas recibidas por correo irán directas a la papelera
-+ I'm not a free help desk, please don't e-mail me your questions
--
Jul 17 '05 #7
Thank you Alvaro! Both The website ownwer and I looked all over for the
solution. I, being the most "skilled" in PHP and HTML, looked it over
for hours not noticing the missing opening cell tag...the closing tag
was there, so adding the <td> fixed it!

The </br > tags were a miss type apparently both of us know that the
correct ones are either <br /> or <br>. I usually do run pages through
the Validator...and this page use to have a link icon on it...but due to
space limitations I removed it...hmmm.

Thanks, again.

Miki

Alvaro G. Vicario wrote:
*** Michelle escribió/wrote (Sun, 12 Sep 2004 16:09:08 GMT):
I am writing them in order, in fact they HTML creates a table and the
PHP is placed in the LAST row. The funny thing is that when you view
the source it is correct; HTML first and PHP at the end. The display is
not so...both with Mozilla and IE.

Then I'd say that there's something wrong with your HTML. Of course I can't
tell which part comes from PHP and which doesn't, but a quick look at your
page revealed code like this:
</tr>
<tr>
</ br></ br><span
Table rows can only contain table cells. Apart from that, there isn't such
tag as </ br>. Pass your site through this app: http://validator.w3.org/
http://s92414411.onlinehome.us/index.php


Jul 17 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Yann.K | last post: by
23 posts views Thread by Mat | last post: by
6 posts views Thread by Roy Chastain | last post: by
5 posts views Thread by Peter Lapic | last post: by
18 posts views Thread by Terry Holland | last post: by
11 posts views Thread by nickyeng | last post: by
3 posts views Thread by koutoo | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.