-2

I have problem in my xampp server php file not work if I write it like this

<?
echo " Not Work " ;

?>

Work

<?php 

echo " it's work " ;

?>

the server will not read the content with the first status , how to fix it to work with both in same time ?

piokuc
  • 24,264
  • 10
  • 66
  • 98
samino sami
  • 125
  • 1
  • 1
  • 4

1 Answers1

0

You need to enable short tags to be able to use <? and ?> without the PHP bit.

Look for:short_open_tag in php.ini and set it to:

short_open_tag=On

Then restart Apache.

Fluffeh
  • 32,630
  • 16
  • 65
  • 80