-2

Possible Duplicate:
How to enable PHP short tags?

I am doing some JavaScript work on a Wordpress based legacy side. I am trying to get the page to run on my dev machine (OS X Lion), but am encountering a problem with code in the template not being interpreted. The template contains some code tags that look like <? echo($subpage_title); ?>. Those don't get interpreted. If I replace that with <?php echo($subpage_title); ?>, it gets interpreted correctly. I don't really want to replace that everywhere and it obviously works on the production server. Is there any server setting I have to change for this to work?

This is probably a silly question, but I have practically no PHP experience and Google is not really helpful when looking for symbols.

Thank you very much for any help!

4
  • 6
    It's called short_open_tag Commented Nov 14, 2011 at 1:02
  • 1
    Singular, actually -- short_open_tag. Commented Nov 14, 2011 at 1:03
  • lol...we all answered this withing 10 seconds of each other. Commented Nov 14, 2011 at 1:04
  • Thanks everyone for the extremely fast answers! Commented Nov 14, 2011 at 2:45

4 Answers 4

5

Enable the setting called short_open_tag in the php.ini file.

Sign up to request clarification or add additional context in comments.

Comments

2

This is controlled by the PHP short_open_tag configuration value. Turn that on for your dev machine and you should be good.

Comments

2

The short_open_tag configuration setting should be a good start.

Comments

2

Check short_open_tag PHP.INI directive.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.