Sure thing:
The first code segment sets the 'foo' cookie, which will expire in an hour. Then it sets another cookie with the time at which the value of the first cookie should no longer be used.
Then, when you want to access the information stored in the 10-second cookie (probably in a different PHP file, or at least after the page is reloaded), do this:
if (isset($_COOKIE['foo'])) { // check if the cookie is set
if ($_COOKIE['expire_foo'] > time()) { // make sure we have not yet reached the time that the cookie was to expire
echo 'Your foo is '.$COOKIE['foo'].'!';
} else { // at least 10 seconds have passed since the cookie was set; do not use it and expire both cookies
setcookie('foo', false);
setcookie('expire_foo', false;
}
}