Method: Padrino::Helpers::AssetTagHelpers#image_path

Defined in:
padrino-helpers/lib/padrino-helpers/asset_tag_helpers.rb

#image_path(src) ⇒ String

Returns the path to the image, either relative or absolute. We search it in your appname.public_folder like app/public/images for inclusion. You can provide also a full path.

Examples:

# Generates: /images/foo.jpg?1269008689
image_path("foo.jpg")

Parameters:

  • src (String)

    The path to the image file (relative or absolute).

Returns:

  • (String)

    Path to an image given the kind and source.


289
290
291
# File 'padrino-helpers/lib/padrino-helpers/asset_tag_helpers.rb', line 289

def image_path(src)
  asset_path(:images, src)
end