# How do you get a cookie in a radiant extension

**URL:** <https://www.ruby-forum.com/t/how-do-you-get-a-cookie-in-a-radiant-extension/144798>\
**Category:** Radiant CMS\
**Created:** [August 2, 2008, 5:46am UTC](https://www.ruby-forum.com/t/how-do-you-get-a-cookie-in-a-radiant-extension/144798 "2008-08-02T05:46:23Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![errolsiegel](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/c77e96/32.png) [@errolsiegel](https://www.ruby-forum.com/u/errolsiegel)\
**Post date:** [August 2, 2008, 5:46am UTC](https://www.ruby-forum.com/t/how-do-you-get-a-cookie-in-a-radiant-extension/144798/1 "2008-08-02T05:46:23Z")

</div>

I have written an extension that gives me a few customer tags for  
generating download links.

In my layout I use javascript to set a cookie according to what page  
referred the user to my site.

If that user later clicks over to the download page I want to customize  
the download link according to how (and if) the cookie is set.

Does anybody know how to retrieve a cookie from within a tag definition  
block?
