Displaying php code within php echo
-
Hi
I am looking to display a <?php within a <?php echo in order to display the sidebar login for those who are not logged in.
I am currently using:
` if ( is_user_logged_in() ) {
echo (‘<div id=”topBanner”></div>’);
} else {
echo (‘<div id=”panel”>
<div id=”panel_contents”> </div>
<div class=”innerContainer clearfix”>
<h1>Login to the customer area using the fields below:</h1> <?php sidebarlogin(); ?>’)] }; ?>.. to display the login form if the user is not logged in however the html displays but the login form does not.
How do I successfully display the sidebar within the echo?
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Displaying php code within php echo’ is closed to new replies.