How urlgen url with variables?

I need URLENCODE:

<?php echo 'chart.php?api_url=http://0.chart.apis.google.com/chart?'.$chart1title.$chart1type.$chart1size.$chart1barsize.$chart1gridlines.$chart1data.$chart1color.$chart1bgcolor.$chart1visibleaxis.$chart1axislabels.$chart1axisdatascale.$chart1axisranges.'alt="answeredcalls"';?> 

And then decrypt it from the other side. How can i do this???

+4
source share
2 answers
 'chart.php?api_url=' . urlencode('http://0.chart.apis.google.com/chart?'.$chart1title.$chart1type.$chart1size.$chart1barsize.$chart1gridlines.$chart1data.$chart1color.$chart1bgcolor.$chart1visibleaxis.$chart1axislabels.$chart1axisdatascale.$chart1axisranges.'alt="answeredcalls"'); 
+6
source

Generally, you do not need to use urldecode() when accessing $ _GET parameters in PHP. It will, in fact, be decoded for you.

The previous answer is a good solution for the coding part of the question.

0
source

All Articles