Unstoppable Domains

Odd php problem

Spaceship Spaceship
Watch

Coolprogram

Established Member
Impact
7
Okay i need some serious help with php. okay i am just learning this stuff but oh well.I am trying to save a .php file but it isn't working.Here is the code.I am literaly just learning so dont laugh well go ahead and laugh.
Code:
<html>
</body>
<?php 
echo "hellow world"; ?>
</body>
</html>
whoever helps me thank you very mucj but whoever doesnt help me then well i hope you can find it in your hearts to help me.lol ;)
thanks,
Coolprogram
;)
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
There is nothing wrong with that code. Make sure you are saving it as .php, and also that your host suppors PHP.
 
0
•••
What's the output of that from viewing the page source? Or is that the output?
 
0
•••
okay i should have made this post more clearley.It wont save as a .php file i didnt know if it was the php code or what it just wont save it saves as a txt file not a php file.
 
0
•••
Coolprogram said:
okay i should have made this post more clearley.It wont save as a .php file i didnt know if it was the php code or what it just wont save it saves as a txt file not a php file.
Are you using windows or unix? In windows you can force an extension by quoting, for instance in notepad, saving as "1.php" will save it as 1.php even if the extension in the type box is txt.
 
0
•••
Okay i just tried that but it didnt work.I put exactly this "1.php" without the quotes.
 
0
•••
Heh...I guess I was unclear on that. Do it WITH the quotes.
 
0
•••
Oh okay

Thank you thank you thank you
 
0
•••
Coolprogram said:
Okay i need some serious help with php. okay i am just learning this stuff but oh well.I am trying to save a .php file but it isn't working.Here is the code.I am literaly just learning so dont laugh well go ahead and laugh.
Code:
<html>
</body>
<?php 
echo "hellow world"; ?>
</body>
</html>
whoever helps me thank you very mucj but whoever doesnt help me then well i hope you can find it in your hearts to help me.lol ;)
thanks,
Coolprogram
;)

umm... try:

Code:
<?php
echo "Hello World";
?>

-RageD :P
 
0
•••
RageD said:
umm... try:

Code:
<?php
echo "Hello World";
?>

-RageD :P

there was nothing wrong with his code (except for spelling helloe incorrectly :hehe: ) his problem as stated was saving it on his computor as a php file. Best to read the whole post before replying.

Try using a php ide such as http://www.mpsoftware.dk/phpdesigner.php, this will not give you any problems saving as a php file. Also it should help whern coding as it will be easier to spot silly mistakes etc.
 
0
•••
LOL you spelled "Hello" incorrectly too, filth :D

Make sure you get rid of the </body> tag on that second line there.
 
0
•••
Okay thanks you guys really were a big help and thanks again.If anyone here wants to add a link(s) to my sig tell me okay.And it can be there for 5NP$ per link + that will stay per month.Also you can add your link to my website if you pay 15NP$ okay thanks again for the help and please add your website to my sig or my website.
-Coolprogram
 
0
•••
I was reading over and everything, seeing your probs fixed, congrats.
Not neccessarily a problem but
Code:
<html>
</body> You never started the body tag ;)
<?php 
echo "hellow world"; ?>
</body>
</html>
Should be

Code:
<html>
<body>
<?php 
echo "hellow world"; ?>
</body>
</html>
 
0
•••
CoolProgram - This should be a totally different topic in a totally different board.
2nd Version - That's just what I said.... O.o
 
0
•••
compuXP said:
LOL you spelled "Hello" incorrectly too, filth :D

lol so I did :]
 
0
•••
Dynadot โ€” .com Registration $8.99Dynadot โ€” .com Registration $8.99
Appraise.net
Unstoppable Domains
Domain Recover
DomainEasy โ€” Live Options
  • The sidebar remains visible by scrolling at a speed relative to the pageโ€™s height.
Back