+1-888-365-2779
Try Now
More in this section

Forums / Designing with Sitefinity / Blog URL Redirection set-up question

Blog URL Redirection set-up question

3 posts, 1 answered
  1. Connections Academy Developer
    Connections Academy Developer avatar
    151 posts
    Registered:
    04 May 2005
    05 Nov 2009
    Link to this post
    Here's how our blog is currently set up:

    mysite.com/blog/ (page group)
    mysite.com/blog/home.aspx (page with Blog Posts Control)

    How do I get my post permalinks to look like this?

    Example: mysite.com/blog/yyyy-mm-dd/post-title.aspx

    I already have the web.config writing the date and post title the way I want, I just need want to know about the folder structure.

    Thanks in advance!
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    06 Nov 2009
    Link to this post
    Hi Connections Academy Developer,

    You cannot use blog as a group page and display posts there. Possible solution is setting blog.aspx as a normal page. Then drop blog posts control on this page and set BehaviorMode to detail. Create a simple control that will make response redirect to your ~blog//home.aspx in case someone tries to access blog.aspx. Generally we make a "fake" group page.

    protected void Page_Load(object sender, EventArgs e)
       {
          string url =  HttpContext.Current.Request.Url.ToString();
           if(url.EndsWith("blog.aspx"))
           {
               Response.Redirect("~/blog/home.aspx");
           }
       }

    On your home page drop BlogPosts control and set Use a page especially prepared to hold the full info to ~/blog.aspx

    All the best,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
    Answered
  3. simy
    simy avatar
    1 posts
    Registered:
    06 Jan 2011
    06 Jan 2011
    Link to this post
    I am having a problem with URL redirection using a mail submission form.

    The form is working and sends the mail successfully, the problem lies when I try to redirect the user to a thankyou.php page using header('Location: http://xxxxx.com/thankyou.php');

    When the form is filled in and submitted, the mailform.php page executes but the redirection does not occur, I just get the blank page mailform.php.

    Searching the web over my syntax for the header() script looks correct, is there anyway to debug this to see what exactly is occurring such PHP redirection problem? Do I need to do anything on the server side in order to allow this function to work properly?

    Thx
Register for webinar
3 posts, 1 answered