Redirecting
You can redirect users from your cbwire components similar to how you would in ColdBox using relocate.
// File: ./wires/FindADeveloper.cfc
component extends="cbwire.models.Component"{
function findADev(){
return this.relocate( URL="https://www.ortussolutions.com" );
}
function renderIt(){
return this.renderView( "wires/findADev" );
}
}
// File: ./views/wires/findADev.cfm
<cfoutput>
<div>
<button wire:click="findADev">Help mah code!</button>
</div>
</cfoutput>In fact, cbwire uses ColdBox's internal relocate() method, so any of the arguments that ColdBox accepts can also be used with cbwire.
Last updated
Was this helpful?