function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Merry SMerry S 

Invalid Page Redirection on a custom button to a flow that worked until yesterday (3/1/16)

I have two flows, one that converts a lead and a second that creates an oportunity (a wizard that walks through making sure the account & contact have all the needed info, then creating an opportunity, a closed task for the user and an open task for the sales person, and then sending an email to the sales person withh the option to cc the user.)

There is one controller for these two flows. It was brought to my attention yesterday that when clicking on the custom button to create the opportunity the user gets this error:
Error is in expression '{!interviewDisplay}' in component <apex:page> in component interview.apexc

When I try the custom button in the sandbox I get this:
Invalid Page Redirection
The page you attempted to access has been blocked due to a redirection to an outside website or an improperly coded link or button. Please contact your Administrator for assistance. For more information, see Insufficient Privileges Errors. 
Click here to return to the previous page.

I have searched for the answer - found an old article for a known issue in Summer '14 - that was marked as Fixed, but nothing that really helped. 

Here is the VF I use for the custom button:
<apex:page standardcontroller="Contact" extensions="FlowController">
<flow:interview name="Opportunity_Creation_New" interview="{!myflow}" finishLocation="{!FlowID}" >
            <apex:param name="var_UserId" value="{!$User.Id}"/> 
            <apex:param name="var_UserDept" value="{!$User.Department}"/> 
            <apex:param name="var_ContactID" value="{!ContactID}"/> 


And here is the controller: see *****Opportunity Wizard Section***** 
public class FlowController{
		// *****Convert lead for Partner Opp Registration Section*****
 public FlowController(ApexPages.StandardController stdController) {}
		    public String LeadId { 
		    		String lid = ApexPages.currentPage().getParameters().get('id');
		    		return lid;
		       set { LeadId = value; }
		// Instanciate the Flow for use by the Controller - linked by VF interview attribute
		public Flow.Interview.Partner_Registration_Lead_Conversion_and_Opp_Creation flowInstance {get;set;}
		// Set the page reference accessor methods
		public PageReference finishLocation {
		get {
		PageReference pageRef = new PageReference('/' + newRecordId);
		return pageRef;
		set { finishLocation = value; }
		// Set the accessor methods for the flow output variable
		public String newRecordId {
		get {
		String strTemp = '';
		if(flowInstance != null) {
		strTemp = string.valueOf(flowInstance.getVariableValue('vOpportunityId'));
		return strTemp;
		set { newRecordId = value; }
		// *****Opportunity Wizard Section*****
		    public String ContactID { 
		    		String cid = ApexPages.currentPage().getParameters().get('id');
		    		return cid;
		       set { ContactID = value; }

		// Instanciate the Flow for use by the Controller - linked by VF interview attribute
		public Flow.Interview.Opportunity_Creation_New myFlow { get; set; }
		private String getmyID() {
		if (myFlow==null) return '';
		else if (myFlow.vOppId == null) return myflow.var_AcctId;
		else return myFlow.vOppId;
		public PageReference getFlowID(){
		PageReference p = new PageReference('/' + getmyID() );
		return p;

I am also putting in a ticket with SF, but since I don't have permium support I am not sure how much they can help. 
James LoghryJames Loghry
I would start by checking the Setup Audit Trail to see if you can find anything there first.  Also, open the flow determine if you can run it manually / outside of Visualforce.