Jump to content

[SOLVED] Session variable not passing


transparencia

Recommended Posts

Greetings :)!

 

I want users to agree on a document...

 

 

//Document.PHP file
if( $kernel->vars['document_agree'] == true )
{
	$_SESSION['document_agree'] = true;


		header( "Location: download.php?id=" . $kernel->vars['file_id'] ); exit;
}	

 

....and then be allowed to donwload:

 

 

 

//Download.PHP file
if( !isset( $_SESSION['document_agree'] ) AND $category_doc_id > 0 )
	{
		header( "Location: document.php?id=" . $category_doc_id . "&file_id=" . $kernel->vars['id'] ); exit;
	}

 

 

I want to pass the session variable from document.php to download.php. I've declared the session variable in the download.php file and it works fine so I assume the session variable is not passing through.  What can be wrong?

Link to comment
https://forums.phpfreaks.com/topic/178542-solved-session-variable-not-passing/
Share on other sites

Archived

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

×
×
  • Create New...

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.