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

Forums / Developing with Sitefinity / news list pagination urls

news list pagination urls

6 posts, 0 answered
  1. Nick
    Nick avatar
    91 posts
    Registered:
    04 Aug 2008
    28 Jul 2009
    Link to this post
    Hello!

    I have encountered this following dilemma involving the URLs of the pagination repeater in the news list in sitefinity 3.2 sp2

    It is worth noting that in our live environment this issue does not seem to be present (and i cannot find any code that would do some kind of rewriting of the URLs).

    Basically, we have our test CMS sitting on a server that is not publicly accessible. Our test site is publicly accessible and all calls to the content area of the site are routed to the CMS and then returned through our front end.

    On the live web server (e.g. www.live-site.com) all links in the pagination are as expected: http://www.live-site.com/news?page=2.

    However, in the test server (e.g. www.test-site.com) all links seem to be absolute and are pointing directly to the CMS server (e.g. on an IP address 10.11.12.13) so that the pagination links are http://10.11.12.13/news?page=2. As i said, due to our CMS server not being directly publicly accessible, this means that the links cannot be followed.

    The fact that it works in the live environment could mean that someone has put code in place to rewrite these URLs, but even so, why is it that absolute URLs are used? wouldn't it be better to use a relative URL so that such problems aren't encountered? Is there any way that i can change this behaviour?

    Thanks for your help and suggestions in advance. This is the only problem stopping us going live with a major redesign and so i wish to get this fixed so that i don't have any more people barking down my neck ;-)

    Cheers,
    Nick!
  2. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    30 Jul 2009
    Link to this post
    Hi Nick,

    This is most probably a browser behavior. If you take a look in the page's source and find the links, you will see them dynamic. When you point over them, the browser shows them as static.

    Can you confirm this on your end as well? We should not be producing full path static links. 

    Greetings,
    Georgi
    the Telerik team

    Instantly find answers to your questions on the newTelerik Support Portal.
    Check out the tipsfor optimizing your support resource searches.
  3. Nick
    Nick avatar
    91 posts
    Registered:
    04 Aug 2008
    30 Jul 2009
    Link to this post
    Hi Georgi!

    You always seem to be sorting out my problems, so thank you for that!

    No it is not a browser issue, i have checked the source of the HTML and can confirm that it is an absolute URL.

    I have temporarily fixed the issue by adding an OnPreRender handler to the parts of the pager and manually stripped out any domains from the URLs - this shows that the URLs being generated are somehow absolute.

    Any suggestions?

    I have used .net reflector to analyse your UI assembly and it does indeed seem to use absolute URLs. The Pager.GetPageUrl(int) method formulates the pages URL based off Context.Request.Url which is indeed absolute in nature.
  4. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    30 Jul 2009
    Link to this post
    Hi Nick,

    Hmm, you are right. I didn't checked the version. It seems we have changed this functionality. The change though appeared in Sitefinity 3.5. Unfortunately I can only suggest you an upgrade this time, if you do not want to use the fix you have.

    I apologize for the inconvenience.

    Regards,
    Georgi
    the Telerik team

    Instantly find answers to your questions on the newTelerik Support Portal.
    Check out the tipsfor optimizing your support resource searches.
  5. Nick
    Nick avatar
    91 posts
    Registered:
    04 Aug 2008
    30 Jul 2009
    Link to this post
    Upgrading is on our to do list, but for now this release takes precedence :-)

    thanks for confirming my suspicions though, Georgi, as i worried that the issue being already "fixed" in our live environment could clash with my alternative "fix" in the test environment, when it gets promoted upwards - and thus cause a breakage even though both environments work functionally, independently.

    Hopefully our upgrade to v3.5 will shortly follow our release, and we will enjoy the numerous fixes in the system :-)

    Thanks once again for your help and your prompt replies!
    Nick
  6. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    30 Jul 2009
    Link to this post
    Hello Nick,

    Thank you too for the understanding!
    Let us know if you experience anything unusual with Sitefinity.

    Greetings,
    Georgi
    the Telerik team

    Instantly find answers to your questions on the newTelerik Support Portal.
    Check out the tipsfor optimizing your support resource searches.
Register for webinar
6 posts, 0 answered