• Antra Shrivastava 8
  • NEWBIE
  • 0 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 2
    Replies
Hi All,

The Url rewriting class does not work when email is passed in url and the email passed contains dot(.)
Can anyone help with this??
Hi All,

The Url rewriting class does not work when email is passed in url and the email passed contains dot(.)
Can anyone help with this??

Hi all,

 

I am newbie to visual force.

I have created a visual force site, and provided a URL rewriter class to it.

My class implements Site.UrlRewriter interface. i have implemented mapRequestUrl() method and the other method is returning null.

I want to redirect the visual force page to site.com page.

i have written a very simplest mapping code as given below.

 

 

 

global class redirectingClass implements Site.UrlRewriter {
  String DIRECTORY = '/LoadOffersPage/';
  String internalDomain='https://sitepreview.ap1.force.com';
  global PageReference mapRequestUrl(PageReference externalUrl) {
       PageReference pageref= new PageReference(internalDomain + '/CLP/?category=a0290000006KSYAAA4');
               pageref.setRedirect(true);
               return pageref;
     }
  global List<PageReference> generateUrlFor(List<PageReference> myForcedotcomUrls) {
      return null;
  }
}

 

my site url is this.

http://abhishek-gupta-developer-edition.ap1.force.com/

 

is it possible to rewrite url in this way. Or where i am going wrong.

Also i read something about about "enabling url rewriting in the site" but didnt get anything about how???

Is it simply like associating the class as URL rewriter class for  the site.

 

thanks and regards

abhishek