cancel
Showing results for 
Search instead for 
Did you mean: 

PHP Script is not working with HTML

former_member450736
Active Participant
0 Kudos

Hi,

i Have included below code in one of BSP pages, HTML code is working fine, however PHP scripting is not been recognized...

please suggest what could be the reason, is my current server does not support PHP processing.

<html>

<body>

<h1>This is heading 1</h1>

<?php

$myString = "Hello!";
echo $myString;
echo "<h5>I love using PHP!</h5>";
?>

</body>
</html>

output is 'This is heading 1' but Hello or i love using PHP is not coming?? no idea why?

this is being executed on EHP5 SAP

Thanks,

Kranthi.

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member184675
Active Participant
0 Kudos

Hi,

From what i know you can't write PHP inside BSP. BSP only interprets ABAP, HTML and Javascript.

Please correct me if i am wrong.

Former Member
0 Kudos

There is a number of different reasons why php would not be executed.

First I would suggest you check the source of what is displayed.

Your browser might only display "This is heading 1" but looking at the source (right-click>View source)you might notice that the php tags are still there as well althought not displaying.

This would obviously mean that the php is not being executed.

You can also try phpInfo() to see how (if it does execute) your php install is made

http://php.net/manual/en/function.phpinfo.php