-6

I have variable like:

$Name = "filedownload-random"

The result of variable $Name is random.

Now every visitor will have his own file. How Can I echo variable $Name into that hyperlink?

echo 'You Can Download it <a href="http://sample.com/mp/download/variable-should-comehere.zip">Here</a>';

Thanks

2 Answers2

4

Try it like this:

echo 'You Can Download it <a href="http://sample.com/mp/download/'.$Name.'">Here</a>';
Robin
  • 1,208
  • 8
  • 17
0

Read more about php and then ask :)

echo 'You Can Download it <a href="http://address.com/folder/'.$Name.'">Here</a>';
  • For random number generating, you can use rand() function.
Farzad
  • 842
  • 2
  • 9
  • 26