Problems With Array's

[php]<?

$states = array (‘Alabama’, ‘Alaska’, ‘Arizona’, ‘Arkansas’, ‘California’, ‘Colorado’, ‘Connecticut’, ‘Delaware’);
print_r ($states);

?>
[/php]

I don’t understand what i have done wrong. I would highly appreciate the help!

Sincerely,

Nick Fowler

If I was to guess, I would say you didn’t enable your short_open_tag in your php.ini file.

Which means you can’t use <? and you have to use <?php

Like this.

[php]<?php

$states = array (‘Alabama’, ‘Alaska’, ‘Arizona’, ‘Arkansas’, ‘California’, ‘Colorado’, ‘Connecticut’, ‘Delaware’);
print_r ($states);

?>[/php]

Sponsor our Newsletter | Privacy Policy | Terms of Service