Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Chris Houston 530 posts 957 karma points admin c-trib
    Dec 13, 2013 @ 13:42
    Chris Houston
    0

    Feed URL seems to be cropped?

    Hi,

    When we add a client's XML feed URL to uMirror and save it, the URL is cropped and hence it does not work, is this something you can fix? It might be a DB column length that is the issue, but I've not dug down into why this is happening.

    The URL is relatively long, but still a valid URL.

    Cheers,

    Chris

  • Antoine 176 posts 1482 karma points
    Dec 13, 2013 @ 14:55
    Antoine
    100

    Hello Chris

    uMirror is not allowed to receive URL, only absolute path. Your case is quite similare to the example described in the documentation.

    You just have to create a proxy method for read the Feed and save it in your disk, you can do it with few lines of code. I give you a simple example:

    const string FilePathUmbracoBlog = "\\App_Data\\umirror\\Umbracoblog.xml";
    
    [UMirrorProxy(FilePathUmbracoBlog)]
    public static void UmbracoBlogRssProxy()
    {
    
            // Read umbraco blog feed
            XDocument myXDocument = new XDocument();
            myXDocument = XDocument.Load("http://feeds.feedburner.com/umbracoblog");
    
            // Save the Xml 
            myXDocument.Save(HttpContext.Current.Server.MapPath(FilePathUmbracoBlog));
    
    }
    

    Then, in your umirror project, specify that you are using this method and try it:

    enter image description here

    Let me know, if you have any other question !

    Regard

  • Chris Houston 530 posts 957 karma points admin c-trib
    Dec 16, 2013 @ 15:29
    Chris Houston
    0

    Thanks Antoine,

    Perfect solution, out of interest, how come you did not make this work out of the box, I would think a lot of people would like to use external feeds?

    Cheers, Chris

  • Antoine 176 posts 1482 karma points
    Dec 16, 2013 @ 15:46
    Antoine
    0

    I have been thinking about that, you are right, It would be very useful ! I have just added it in our backlog list :)

    Thanks.

    Antoine

Please Sign in or register to post replies

Write your reply to:

Draft