Forum Moderators: coopster

Message Too Old, No Replies

how to output a varible's value from header()

         

xbl01234

2:35 am on Jan 17, 2009 (gmt 0)

10+ Year Member



Hi;
i'd like to how to output some varible's value from the header().

for instance;
header('location:search_p2.php?business_type=$business_type&country=$country&province_state_territor ies=$province_state_territories&city=$city');

i want the result as following;
http://www.example.com/search_p2.php?business_type=$business_type&country=Australia&province_state_territories=nsw&city=sydney

i don't want as following;
http://www.example.com/search_p2.php?business_type=$business_type&country=$country&province_state_territories=$province_sta te_territories&city=$city

Could anyone help me, thanks.

[edited by: coopster at 1:18 pm (utc) on Jan. 17, 2009]
[edit reason] please use example.com, thanks! [/edit]

cameraman

5:53 am on Jan 17, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Change your single quotes to double quotes:
header("location:search_p2.php?business_type=$business_type&country=$country&province_state_territor ies=$province_state_territories&city=$city");