Start And End Date From Week Number

Use this code:

<?php
$week = 36;
$year = 2012;

$timestamp_tmp = mktime( 0, 0, 0, 1, 1,  $year ) + ( $week * 7 * 24 * 60 * 60 );
$timestamp_start = $timestamp_tmp - 86400 * ( date( 'N', $timestamp_tmp ) - 1 );

$date_start = date( 'd M,Y', $timestamp_start );
$date_end = date( 'd M,Y', strtotime('+6 days',$timestamp_start) );
?>


Here :
$week = entered week number,
$year = entered year number,
$date_start = start date of the week,
$date_end = end date of the week,