Link to home
Start Free TrialLog in
Avatar of pmmms
pmmms

asked on

php: meaning of "?@"

What is the meaning of ?@ in a construct like this
                  $var = array
                        (
                        '{?@Customer}' => $Customer,
                        '{?@Month}'    => $Month,
                        '{?@Year}'     => $Year,
                        );

Thank you in advance for any help.
@+ P Marione
Avatar of pmmms
pmmms

ASKER

I think that "?@Customer" is the convention to name a parameter in Crystal Report but I don't understand the meaning of the { } here.

@+P Marione
ASKER CERTIFIED SOLUTION
Avatar of ravenpl
ravenpl
Flag of Poland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
It means nothing, the single quotes don't invoke the interprerter, it would be different if it had double quotes.
Avatar of pmmms

ASKER

What would it means with double quotes?
hi!

php differs between two types of strings: the ones enclosed in double quotes, and the one enclosed in single quotes. the difference is the following: the double quotes are ecutally parsed by the php interpreter, and variables inside are properly filled with its values, while single quotet are not parsed at all, so are used for real string literals. a short example:

$var = 15;
echo '$var=$var';
echo "\$var=$var";

would give as an output:

$var=$var
$var=15

here the first string is enclosed by a single quote, so it is a real literate, while the second is first parsed by the php engine, and variables are replaced by their values. you can also write the first string this way:

$var = 15;
echo '$var=' . $var;
echo "\$var=$var";

now both stings would be the same....

that's why the above sample doesn't mean anything by the means of the php language itself, it is a real constant literal, not interpreted by the language itself, I guess it is just some convention to name parameter keys in some famework.....? where did you see this code?