FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » why php echo does not show up in HTML?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: why php echo does not show up in HTML? [message #181630 is a reply to message #181614] Fri, 24 May 2013 13:25 Go to previous messageGo to previous message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma:
Senior Member
On 5/24/2013 4:50 AM, Andy wrote:
>
>
> "steve nospam" <steve(dot)nospamm(at)gmail(dot)com> wrote in message
> news:78f2c263-051b-4b12-b2fc-049aeae3fdd6(at)z8g2000yqd(dot)googlegroups(dot)com...
>> newbie.
>>
>> could someone explain why this does not work?
>>
>> <!DOCTYPE html>
>> <html>
>> <body>
>> <p>before
>>
>> <?php echo "do you see this?"; ?>
>>
>> <p>after
>> </body>
>> </html>
>>
>> I spend 2 hrs and tried everything and read many things, but message
>> in echo does not show on the browser. I upload this to the web server.
>> I also have local web server running. Both support php. I see no error
>> in the access log file and no error in the php error log file. So the
>> page is bring loaded OK by the web server. But I do not see the echo.
>> What Ami doing wrong?
>>
>> cheers,
>> steve
>>
>
> Hi Steve,
>
> I'm no expert but try these suggestions...
>
> 1: Ensure the file is named whatever.php and not whatever.html
>

Most probably the problem.

> 2: Put <?php at the very top of page (e.g. <?php // comment ?>)
>

Completely unnecessary. The <?php can appear anywhere in the page.

> 3: Try <?php $test = "do you see this?";?> <?php echo $test;?>
>

Which does nothing (except complicate the matter).

>
> Hope this helps
>
> Andy



--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: PHP Contact Form, mt-rand(), problem Validating 1 input
Next Topic: Parsing mbox files with Windows Php
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Wed Nov 27 18:55:43 GMT 2024

Total time taken to generate the page: 0.06092 seconds