Using apex:outputLink you can link to record IDs. I would like to access a record through a JQuery click function. Is there a way to pass the value of the outputLink to javascript?
function clickTables()
{
('.propertyRateTable').click(function()
{
//OPEN LINK FROM COMMAND LINK
});
}
Output Link:
<apex:outputLink id="hkLink" value="/{!hk.id}" target="_blank">{!hk.Property__r.Name}</apex:outputLink>
EDIT
<div id="leftBottomBlock">
<apex:pageBlock id="todayReport" title="Today's Reports">
<div id="hkRecords">
<apex:outputLabel ><strong>Properties:</strong></apex:outputLabel>
<apex:repeat value="{!hk_records}" var="hk" id="hkRecordList">
<div class="propertyRateDiv">
<table class="hkRecordTable">
<apex:outputLink id="hkLink" value="/{!hk.id}" target="_blank">{!hk.Property__r.Name}</apex:outputLink>
<thead>
<tr>
<td>Supervisor: </td>
<td>{!hk.Supervisor__c}</td>
</tr>
<tr>........
Best Answer
<apex:outputLink>
is rendered as a normala
tag, so you can bind to it normally, like this:Example: