| | |
HTML codes in PHP
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
Just wanted to ask you guys how to properly call HTML tags into php. e.g.
As you can see above, the developer has design a form inside a the PHP inself. Where can I find useful resources on more examples on how to embed HTML into PHP.
*How to to do everything using echo statement
1. Any useful books?
2. Any useful links?
php Syntax (Toggle Plain Text)
echo "You are not authenticated. Please login.<br><br> <form method=POST action=admin.php bgcolor=\"C0C0C0\"> username: <input type=text name=\"username\"> password: <input type=password name=\"password\"> <input type=submit> </form>";
As you can see above, the developer has design a form inside a the PHP inself. Where can I find useful resources on more examples on how to embed HTML into PHP.
*How to to do everything using echo statement
1. Any useful books?
2. Any useful links?
Last edited by lordx78; Mar 2nd, 2008 at 4:23 am.
"I might not be the BEST but I'm not like the REST!"
•
•
Join Date: Apr 2006
Posts: 66
Reputation:
Solved Threads: 11
if it helps you:
echo "<p>Here is some text displayed in a paragraph tag </p>";
$str = "<table width='90%' align='center' border='1'>";
$str .= "<tr>";
$str .= "<td>some text here</td>";
$str .= "</tr>";
$str .= "</table>";
echo $str;
PM me if you need more help.
echo "<p>Here is some text displayed in a paragraph tag </p>";
$str = "<table width='90%' align='center' border='1'>";
$str .= "<tr>";
$str .= "<td>some text here</td>";
$str .= "</tr>";
$str .= "</table>";
echo $str;
PM me if you need more help.
i use this code for most of my html in the sites i have developed:
PHP Syntax (Toggle Plain Text)
$html =<<<HTML any html content contained here HTML;
![]() |
Similar Threads
- Newby to PHP here.... (Google Analytics) (PHP)
- HTML/ CSS Tutorials (HTML and CSS)
- Php coder.. Need Job (PHP)
- XHTML with PHP validation ??? (HTML and CSS)
- PHP's include function ??? (PHP)
- PHP file displaying wrongly ??? (PHP)
- PHP Downloads:Which one should I choose? *Newbie* (PHP)
Other Threads in the PHP Forum
- Previous Thread: pass variables across pages
- Next Thread: Pagination error..
| Thread Tools | Search this Thread |
apache api array beginner binary body broken buttons cakephp checkbox class cms code cron curl database date date/time display dynamic ebooks echo email error file files folder form forms function functions global google href htaccess html image include insert ip javascript joomla limit link list login mail mediawiki menu mlm msqli_multi_query multiple mycodeisbad mysql number oop parameter paypal pdf php phpincludeissue problem query radio random recourse recursion regex remote script search seo server sessions sms source sp space speed sql static subdomain syntax system table tag tutorial update upload url validator variable vbulletin video web webdesign white wordpress xml youtube






