You need to sign in to do that
Don't have an account?
shrey.tyagi88@tcs.com
Pass <Apex:input text> value to a link of <apex:command link>
Hi Everyone,
I have a pretty straightforward requirement here. I have an <apex:input text > box on my page and a <apex:commandbutton>. The command button point to a website e.g. google.com . I want when user enters the value in input text and clicks on the button , the button should open a new page with google.com/inputtextvalue. Can anyone please help me with this?
<apex:inputtext value="{!searchText}" id="DocumentText" rendered="true" />
<apex:commandLink > id="linkt" action="{!processLinkClick}">Search OnBase</apex:commandLink>
apex Code:
public string searchText{get;set;}
public PageReference processLinkClick() {
return new PageReference('www.google.com/'+searchText);
}
I have a pretty straightforward requirement here. I have an <apex:input text > box on my page and a <apex:commandbutton>. The command button point to a website e.g. google.com . I want when user enters the value in input text and clicks on the button , the button should open a new page with google.com/inputtextvalue. Can anyone please help me with this?
<apex:inputtext value="{!searchText}" id="DocumentText" rendered="true" />
<apex:commandLink > id="linkt" action="{!processLinkClick}">Search OnBase</apex:commandLink>
apex Code:
public string searchText{get;set;}
public PageReference processLinkClick() {
return new PageReference('www.google.com/'+searchText);
}
Best Answer chosen by shrey.tyagi88@tcs.com
Raj Vakati
Use this code