+ Start a Discussion

Need to use controller + jsremoting for page redirect

I'm trying to pump a string into a visualforce page that creates a CSV. The problem I'm having is when I return the page reference to the JS Remoting event, no redirect actually happens...The console just shows the page I want to redirect to.
Here's my code from the controller...

    global static PageReference HTMLDump(string html) {
        PageReference pageRef=page.CSV_ExportPage;
        return pageRef;


                   function(result, event)

 After doing a system.debug in the controller I was able to verify that the string is being passed in fine...it's just the redirect that isn't working. I have a feeling it has something to do with the way I'm using the JS remoting but I'm not sure how else to go about it.


Any help in the right direction would be greatly appreciated!