Get Last NID into Variable
You might be able to create a rule based on this:


event: After content has been saved...
condition:  content is new
condition:  content is type (select type)
action: page redirect:  fill in page here with tokens based up content above


In the page direct you can create a query variable after the ?, eg foo=[TOKEN], and then in your page, you can access that variable via $_GET['foo'] or $_REQUEST['foo'].