WordPress.org

Forums

Create .opml file as a download? (6 posts)

  1. mixmastermichael
    Member
    Posted 5 years ago #

    Hello,

    For a blog post, I would like to include a .opml file available as a download so that when users click on it, they will be able to download the file to their desktops.

    Can someone please give me a little advice on how I might be able to do this? Does the .mime file have to be configured for .ompl files to be able to just upload it to the server and then have it become available?

    Thanks,
    Mike

  2. jceresini
    Member
    Posted 5 years ago #

    You will most likely need to set the mime type to "application/octet-stream" in your web server to have it be forced as a download, rather than your browser trying to decide what program should open it. For apache you can add the following line to the httpd.conf file

    AddType application/octet-stream .opml

    [signature moderated Please read the Forum Rules]

  3. or1gb1u3
    Member
    Posted 5 years ago #

    another option would be to use an compression program and rar or zip it as well.

  4. jceresini
    Member
    Posted 5 years ago #

    Thats true but your web server would need to have a mime type set for the file extension of the zip format you use. Sure Apache and IIS probably default to having them set for most popular formats, but I think it would be better to not expect the client to have a compression program.

    Joe

  5. iridiax
    Member
    Posted 5 years ago #

    I think it would be better to not expect the client to have a compression program.

    Although a user sophisticated enough to use an OPML file could probably figure out how to unzip something. ;-)

  6. mixmastermichael
    Member
    Posted 5 years ago #

    Thanks a lot for your help guys! I think the .zip file format is a very simple solution for it. I will get in touch with my server to set up the mime permissions as well to see if I can get it to work.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.