CSS is for styling, not content. Though you have some limited ability to inject content via CSS, I'm 99.9% sure you can't control an href attribute from CSS.
To elaborate on Barand's response to this, PHP will only interpolate variables in double-quoted strings. For instance,
$var = "you";
echo "Hi there, $var!";
This will output Hi there, you!
However,
$var = "you";
echo 'Hi there, $var!';
This will output Hi there, $var!
It's an important distinction.
What? <?php opens a PHP block, and ?> closes it. So OK, technically you're on the right track; however if you just type <? into HTML, you're going to get <? on your screen.