0

On Standard detail page I have custom button with execute javascript functionality, based on the condition true the button want opens a jQuery popup with another VF page and the condition false the button will open the Direct Visual force page. Please some one help me on this issue.

1 Answer 1

1

You can do something like this as the javascript for the button. Just change the condition, apexpages, Ttitle,etc in what you want.

if ({!Account.Phone}=='123') {
openPopupFocusEscapePounds('/apex/apexpage1','Title',1024,768,'width=1024,height=768,resizable=yes,toolbar=yes,status=yes,scrollbars=yes,menubar=yes,directories=no,location=yes,dependant=no','false','false');
} else {
window.top.location='/apex/apexpage2';
}

It's pretty much self explanatory. If you want to use jquery, that is a different story, but I don't see why you would need that. Maybe you have some requirements that warrants the use of jQuery?

2
  • Thanks you so much, your suggestion is great but I am using jQuery popup,
    – raghusfdc
    Oct 30, 2013 at 7:43
  • Yes I have a requirements that I should use the jQuery for very nice UI and also freez the background.
    – raghusfdc
    Oct 30, 2013 at 7:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .