This page last changed on Feb 17, 2006 by [email protected].

Tag - createLinkTo

Description

Creates a link that can be used where necessary (for example in an href, javascript, ajax call etc.)

Parameters

  • dir (optional) - the name of the directory within the grails app to link to
  • file (optional) - the name of the file within the grails app t link to

Examples

Example usages for the "shop" app:

<g:createLinkTo dir="css" file="main.css" /> == /shop/css/main.css

Examle as a method call in GSP only:

<link type="text/css" href="${createLinkTo(dir:'css',file:'main.css')}" />

Results in:

<link type="text/css" href="/shop/css/main.css" />
Document generated by Confluence on Mar 29, 2006 08:46