In this article I'm going to show you how to set up a link to a file using the NationBuilder interface.
The NationBuilder interface allows you to easily perform most website management tasks. Creating a new page, changing the header image, no problem. But if you're used to managing a traditional website, a few things can seem more complicated than they should be. Linking to files is one of them.
Say you just gave a presentation entitled Powering Your Car with Potato Chips and you want to post it to your site so anyone can download it. On a traditional site, this would be just a matter of uploading the PowerPoint file to your server and then pointing people to a URL like mysite.com/uploads/potato-car.ppt.
On NationBuilder the process is a little more involved:
- Create a new basic page on your site called 'Uploads'. You can name it whatever you want, but it will be the parent page for any files you want to upload to your site. Make sure to uncheck "Include in top nav" before you publish the page.
- Click on the 'Files' submenu of the "Uploads" page and upload your file.
- Right click on the file link once it's uploaded and copy the link address. It should look something like: http://d7mx.cloudfront.net/sitename/pages/24/attachments/original/potato-car.ppt?1329. You may want to paste it into a notepad file because we'll need it later.
- Begin to create a new sub-page of the Uploads page by clicking on "Subpages' -> 'New subpage'.
- Type the name of your file into the "Name" box of the new subpage. NationBuilder will automatically generate a URL-friendly name for the page (known as the 'slug') immediately below the "Name" box. In my case, the slug is potato_car_ppt. Make a note of the slug, because this is the page you'll be directing people to to download your file. Before creating the page, set the 'Type of page' to Redirect, and then save the page.
- Paste the long complicated URL we copied in step 3 into the box entitled "URL to redirect to"
- Set the page 'Status' to 'published" and click "Save redirect."
That's it! Now if you want to direct people to your presentation, you would simply send them to mysite.com/potato_car_ppt, replacing the 'potato_car_ppt' with your own slug.
Now, what about if, before you moved your site to NationBuilder, you had a file like mysite.com/really-important-file.zip on your server that a lot of people linked to? You need your file to be accessible at that exact address, but you can't create a page with a slug of really-important-file.zip.
This is where NationBuilder's legacy redirect system comes in. It allows you to redirect any arbitrary URL for your domain to one of your NationBuilder pages.
So in our case, if you want the link mysite.com/potato-car.ppt to work just as well as mysite.com/potato_car_ppt:
- Go to "Pages" -> "Legacy" -> "New Redirect"
- Enter '/potato-car.ppt' into the 'Legacy URL' box
- Enter 'potato_car_ppt" into the "What page should this redirect to?" box
- Click 'Save URL'
And now you're really finished. If you point someone to mysite.com/potato-car.ppt it will automatically redirect them to mysite.com/potato_car_ppt which will automatically redirect them to download your file.
I hope you have found this tutorial helpful. If you have any questions or need any assistance linking to files on your site, feel free to contact us!