Bug #16663 Updated: Different syntax for embedding HTML in PHP

2002-04-23 Thread tbrinkman

 ID:   16663
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: Linux
 PHP Version:  4.2.0
 New Comment:

Don't think of it as including HTML in PHP.  Think of it as including
PHP in HTML.  That way you have your block-level delimiters as the
standard PHP start/end tags.

Whether this is a problem is completely dependant on your point of
view.


Previous Comments:


[2002-04-17 17:39:12] [EMAIL PROTECTED]

Well, I found another bug report #8685 which clued me in about where to
find the documentation for this type of
construct, which is a heredoc text entry.  Interestingly,
the other report was also from someone trying to write readable,
block-structured code, and was also classified as bogus.  I guess us
old guys who were around when Pascal was invented just have some weird
ideas about how code should be organized to be people friendly.



[2002-04-17 17:00:04] [EMAIL PROTECTED]

There is nothing wrong with your alternative except that I can't find
info about the contstruct

echo HTML
some more html
HTML

in the online documentation.  Should I add this to the notes regarding
Example 5-2. Advanced escaping on

http://www.php.net/manual/en/language.basic-syntax.php

in the online documentation, since this is apparently an additional
method for disabling the PHP parser ?

NOTE: I did try to search the online documentation for  without
any result. I also spoke to a PHP programmer with considerably more
experience than me, who was also unfamiliar with this construct.



[2002-04-17 16:01:32] [EMAIL PROTECTED]

What's wrong with

?php
  echo Ene mene foobr /\n;
  echo HTML
hr
Some more html
hr
HTML

?

Any, unlikely SUCH a change is done. Ever. :-)



[2002-04-17 12:29:12] [EMAIL PROTECTED]

I can't seem to figure out how to edit the submission,
so I can't fix the missing  on html



[2002-04-17 12:24:55] [EMAIL PROTECTED]

Missed the opening  on html



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/16663

-- 
Edit this bug report at http://bugs.php.net/?id=16663edit=1




Bug #16663 Updated: Different syntax for embedding HTML in PHP

2002-04-17 Thread mfischer

 ID:   16663
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: Linux
 PHP Version:  4.2.0
 New Comment:

What's wrong with

?php
  echo Ene mene foobr /\n;
  echo HTML
hr
Some more html
hr
HTML

?

Any, unlikely SUCH a change is done. Ever. :-)


Previous Comments:


[2002-04-17 12:29:12] [EMAIL PROTECTED]

I can't seem to figure out how to edit the submission,
so I can't fix the missing  on html



[2002-04-17 12:24:55] [EMAIL PROTECTED]

Missed the opening  on html



[2002-04-17 12:18:47] [EMAIL PROTECTED]

The following can be confusing to read:

html
brThis is plain HTML
?
echo brThis is a PHP Block;
?
brThis is raw html text embedded in PHP.
?
echo brThis is the same outer PHP block;
?
brThis is more plain HTML
/html

The following is easier to read, at least for me,
with a C programming background:

html
brThis is plain HTML
?
echo brThis is a PHP Block;
HTML
{
brThis is raw html text embedded in PHP.
}
echo brThis is the same outer PHP block;
?
brThis is more plain HTML
/html

This would make HTML a reserved word that would turn off
the PHP parser within the following set of braces, or if
braces aren't present, until the next semicolon.  The
advantage of this style is it makes it easier to see the
underlying block structure of the PHP code, yet avoids
having to use echo or print to output chunks of HTML code.





-- 
Edit this bug report at http://bugs.php.net/?id=16663edit=1




Bug #16663 Updated: Different syntax for embedding HTML in PHP

2002-04-17 Thread bill

 ID:   16663
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: Linux
 PHP Version:  4.2.0
 New Comment:

There is nothing wrong with your alternative except that I can't find
info about the contstruct

echo HTML
some more html
HTML

in the online documentation.  Should I add this to the notes regarding
Example 5-2. Advanced escaping on

http://www.php.net/manual/en/language.basic-syntax.php

in the online documentation, since this is apparently an additional
method for disabling the PHP parser ?

NOTE: I did try to search the online documentation for  without
any result. I also spoke to a PHP programmer with considerably more
experience than me, who was also unfamiliar with this construct.


Previous Comments:


[2002-04-17 16:01:32] [EMAIL PROTECTED]

What's wrong with

?php
  echo Ene mene foobr /\n;
  echo HTML
hr
Some more html
hr
HTML

?

Any, unlikely SUCH a change is done. Ever. :-)



[2002-04-17 12:29:12] [EMAIL PROTECTED]

I can't seem to figure out how to edit the submission,
so I can't fix the missing  on html



[2002-04-17 12:24:55] [EMAIL PROTECTED]

Missed the opening  on html



[2002-04-17 12:18:47] [EMAIL PROTECTED]

The following can be confusing to read:

html
brThis is plain HTML
?
echo brThis is a PHP Block;
?
brThis is raw html text embedded in PHP.
?
echo brThis is the same outer PHP block;
?
brThis is more plain HTML
/html

The following is easier to read, at least for me,
with a C programming background:

html
brThis is plain HTML
?
echo brThis is a PHP Block;
HTML
{
brThis is raw html text embedded in PHP.
}
echo brThis is the same outer PHP block;
?
brThis is more plain HTML
/html

This would make HTML a reserved word that would turn off
the PHP parser within the following set of braces, or if
braces aren't present, until the next semicolon.  The
advantage of this style is it makes it easier to see the
underlying block structure of the PHP code, yet avoids
having to use echo or print to output chunks of HTML code.





-- 
Edit this bug report at http://bugs.php.net/?id=16663edit=1




Bug #16663 Updated: Different syntax for embedding HTML in PHP

2002-04-17 Thread bill

 ID:   16663
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: Linux
 PHP Version:  4.2.0
 New Comment:

Well, I found another bug report #8685 which clued me in about where to
find the documentation for this type of
construct, which is a heredoc text entry.  Interestingly,
the other report was also from someone trying to write readable,
block-structured code, and was also classified as bogus.  I guess us
old guys who were around when Pascal was invented just have some weird
ideas about how code should be organized to be people friendly.


Previous Comments:


[2002-04-17 17:00:04] [EMAIL PROTECTED]

There is nothing wrong with your alternative except that I can't find
info about the contstruct

echo HTML
some more html
HTML

in the online documentation.  Should I add this to the notes regarding
Example 5-2. Advanced escaping on

http://www.php.net/manual/en/language.basic-syntax.php

in the online documentation, since this is apparently an additional
method for disabling the PHP parser ?

NOTE: I did try to search the online documentation for  without
any result. I also spoke to a PHP programmer with considerably more
experience than me, who was also unfamiliar with this construct.



[2002-04-17 16:01:32] [EMAIL PROTECTED]

What's wrong with

?php
  echo Ene mene foobr /\n;
  echo HTML
hr
Some more html
hr
HTML

?

Any, unlikely SUCH a change is done. Ever. :-)



[2002-04-17 12:29:12] [EMAIL PROTECTED]

I can't seem to figure out how to edit the submission,
so I can't fix the missing  on html



[2002-04-17 12:24:55] [EMAIL PROTECTED]

Missed the opening  on html



[2002-04-17 12:18:47] [EMAIL PROTECTED]

The following can be confusing to read:

html
brThis is plain HTML
?
echo brThis is a PHP Block;
?
brThis is raw html text embedded in PHP.
?
echo brThis is the same outer PHP block;
?
brThis is more plain HTML
/html

The following is easier to read, at least for me,
with a C programming background:

html
brThis is plain HTML
?
echo brThis is a PHP Block;
HTML
{
brThis is raw html text embedded in PHP.
}
echo brThis is the same outer PHP block;
?
brThis is more plain HTML
/html

This would make HTML a reserved word that would turn off
the PHP parser within the following set of braces, or if
braces aren't present, until the next semicolon.  The
advantage of this style is it makes it easier to see the
underlying block structure of the PHP code, yet avoids
having to use echo or print to output chunks of HTML code.





-- 
Edit this bug report at http://bugs.php.net/?id=16663edit=1