diff --git a/lib/wsoc/helpers/course.rb b/lib/wsoc/helpers/course.rb
index <HASH>..<HASH> 100644
--- a/lib/wsoc/helpers/course.rb
+++ b/lib/wsoc/helpers/course.rb
@@ -27,7 +27,13 @@ module WSOC
 
       def remote_url(path,port=nil)
         s = "#{request.scheme}://#{request.host}"
-        s << ":#{port}" if port
+
+        if port
+          s << ":#{port}"
+        elsif request.port != 80
+          s << ":#{request.port}"
+        end
+
         s << path
 
         return s
Make sure remote_url encodes the request.port.