Im new to PHP programming.
I get this error when running the following PHP code to generate a URL.
Im using PHP 5.3.5.
( ! ) Parse error: syntax error, unexpected
T_CONSTANT_ENCAPSED_STRING, expecting ‘&’ or T_VARIABLE in
C:\wamp\www\test\urlgen.php on line 30
function bg_gen_secure_uri(
'http://demo.com/abc/secure/movie/movie-full-film_256x144-150.mp4',
'MqG9$fso2lt7(',
$expiry = 0,
$allowed_countries = '',
$disallowed_countries = '',
$allowed_ip = '',
$allowed_useragent = '',
$allowed_metros = '',
$disallowed_metros = '', $progressive_start = '', $progressive_end = '',
$extra_params = '' )
{
return $url;
}
I will be very thankful if I get an answer.
Why are you giving two constants as parameters?
That part is wrong. Assign using something, may be like this:
And there’s no
<php>tag. Remove that!