Class: Wovnrb::URL
- Inherits:
-
Object
- Object
- Wovnrb::URL
- Defined in:
- lib/wovnrb/services/url.rb
Class Method Summary collapse
-
.prepend_path(url, dir) ⇒ Object
Set the path lang to.
- .resolve_absolute_url(curr_location, rel_location) ⇒ Object
Class Method Details
.prepend_path(url, dir) ⇒ Object
Set the path lang to
7 8 9 10 |
# File 'lib/wovnrb/services/url.rb', line 7 def self.prepend_path(url, dir) result = url.sub(/(.+\.[^\/]+)(\/|$)/, '\1/' + dir + '\2') return result end |
.resolve_absolute_url(curr_location, rel_location) ⇒ Object
3 4 |
# File 'lib/wovnrb/services/url.rb', line 3 def self.resolve_absolute_url(curr_location, rel_location) end |