Jump to content

Archived

This topic is now archived and is closed to further replies.

laide234

**solved** How do I put a variable into a header?

Recommended Posts

I have a variable $job_id that contains a numeric value I would like to append to a header.
i.e. if  $job_id = 5
go to  listing.php?view=thanks&job_id=5

Here is what I tried

[code]header('Location: listing.php?view=thanks&job_id='echo $job_id;'');[/code]

Apperently, this isnt working. Any suggestions?

Share this post


Link to post
Share on other sites
[code]<?php

header('Location: listing.php?view=thanks&job_id=' . $job_id);

?>[/code]

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.