The below code is connected to a contact form. On submit, you receive one of two messages. How can I add span and h1 styles to these messages?
<?php
if($_GET['message'] == "thanks") {
$message = "Message received! Thank you for contacting us.";
} else {
if($_GET['message'] == "wrongcaptcha")
$message = "We are having problems processing your message. The captcha code you entered was incorrect.";
}
?>
<div id="thankyoubox">
<p><?php echo $message?><p>
</div><!--end of thankyoubox-->
Thanks!
Either of these two ways will work:
$message = '<h1 style="color:#333;font-weight:bold;" >Message received! <span>Thank you</span> for contacting us.</h1>';
or
<h1><?php echo $message?><h1>
Alter your $message
variable. For example:
$message = "<h1>Message received!</h1> Thank you for contacting us.";