You need to sign in to do that
Don't have an account?
window.open in partner portal not open in parent URL
Hi All,
I have a simple JS function.
function openNewVfpage(){
window.open('/apex/GRID_portalSearch?searchText='+document.getElementById('{!$Component.formId.SearchKeyWord}').value,'_parent');
return true;
}
it working in salesforce when I am clicking on button. but in portal I am using the same VF page and clicking on button and it opens only
https://c.cs12.visual.force.com/apex/GRID_portalSearch
but I need this URL with the parameter ?searchText=value
it should be
https://c.cs12.visual.force.com/apex/GRID_portalSearch?searchText=value
can anyone please help me out ?
Thanks
Vijay
Thanks for reply
Already I checked , there is no error in console. Even if error occured then it will be in salesforce VF page it self.
Yes I had fix some alerts as well , and I am getting the exact URL in alert before calling it in window.open.
?searchtext=Test
Yes Bhawani,
Almost I checked every probality even I tried to check other properties of windows like window.location.heref and all others but still not work. Ok fine.
Now again I am trying to write another button code and will try to open some other hard coded URL and lets see what happens. I know it is silly work but still some time we used to do :)
Its not working , I understood the problem. I have another commandLink or button on Portal Header as VF page in Iframe if I am clicking from header part it works for window.open but if we are in the portal VF page then the same code doesnot override the parent URL.
Also did you try with parent.location.href?
Yes , I wrote in my previsous reply.
Thanks.
I have done my job using pagereference method. But still it should work with window.open.