如何将包含get值的链接发送到电子邮件?

I want my site to email a a link to users using passed in variables from get. in the form of www.test.com/test.php&test=testing+this+is+a+test

but when i do something like this,

$msg= "testing".$_GET('details');

It spits out "www.test.com/test.php&test=testing this is a test" [with spaces and not '+' signs]

Any ideas how i can pass it in unformatted?

Use urlencode() on any string you intend to use as a GET parameter.