Title: HTML code inside PHP code
Last modified: August 21, 2016

---

# HTML code inside PHP code

 *  [Sajgon](https://wordpress.org/support/users/sajgon/)
 * (@sajgon)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/html-code-inside-php-code/)
 * Hey! I need help before I explode because of frustration.
 * I am using the plugin “Allow PHP in Posts and Pages” –
    And I want to echo out
   the HTML code inside my PHP code but it doesn’t react.. I’ll give you an example:
 * [php]$numb = 1;
    switch ($numb){ case 1: echo ‘`<a href="url">Link text</a>`‘;
   break; default: echo “Something went wrong! Please contact admin!”; }[/php]
 * But it doesnt respond as html text – the output is just plain text: “Link text”..
 * How can I solve this? I tried to..
    _echo ‘[/php]`<a href="url">Link text</a>`[
   php]‘;_ But I reed that everything needs to be within the [php]&[/php]
 * Thank you for further help!

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [GenealogyCoach](https://wordpress.org/support/users/samatva/)
 * (@samatva)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/html-code-inside-php-code/#post-4405972)
 * This is a plugin issue. Perhaps someone in [that plugin’s support forum](http://wordpress.org/support/plugin/allow-php-in-posts-and-pages)
   could help?
 *  Thread Starter [Sajgon](https://wordpress.org/support/users/sajgon/)
 * (@sajgon)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/html-code-inside-php-code/#post-4405977)
 * Thank you Samatva!
    Seems like many other have this problem and this plugin seems
   to be broken at this part of coding.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘HTML code inside PHP code’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [Sajgon](https://wordpress.org/support/users/sajgon/)
 * Last activity: [12 years, 5 months ago](https://wordpress.org/support/topic/html-code-inside-php-code/#post-4405977)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
