asset.php 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <?php
  2. /**
  3. * Part of the Fuel framework.
  4. *
  5. * @package Fuel
  6. * @version 1.5
  7. * @author Fuel Development Team
  8. * @license MIT License
  9. * @copyright 2010 - 2013 Fuel Development Team
  10. * @link http://fuelphp.com
  11. */
  12. /**
  13. * NOTICE:
  14. *
  15. * If you need to make modifications to the default configuration, copy
  16. * this file to your app/config folder, and make them in there.
  17. *
  18. * This will allow you to upgrade fuel without losing your custom config.
  19. */
  20. return array(
  21. /**
  22. * An array of paths that will be searched for assets. Each path is a
  23. * RELATIVE path from the speficied url:
  24. *
  25. * array('assets/')
  26. *
  27. * These MUST include the trailing slash ('/')
  28. *
  29. * Paths specified here are suffixed with the sub-folder paths defined below.
  30. */
  31. 'paths' => array('assets/'),
  32. /**
  33. * Asset Sub-folders
  34. *
  35. * Names for the img, js and css folders (inside the asset search path).
  36. *
  37. * Examples:
  38. *
  39. * img/
  40. * js/
  41. * css/
  42. *
  43. * This MUST include the trailing slash ('/')
  44. */
  45. 'img_dir' => 'img/',
  46. 'js_dir' => 'js/',
  47. 'css_dir' => 'css/',
  48. /**
  49. * You can also specify one or more per asset-type folders. You don't have
  50. * to specify all of them. * Each folder is a RELATIVE path from the url
  51. * speficied below:
  52. *
  53. * array('css' => 'assets/css/')
  54. *
  55. * These MUST include the trailing slash ('/')
  56. *
  57. * Paths specified here are expected to contain the assets they point to
  58. */
  59. 'folders' => array(
  60. 'css' => array(),
  61. 'js' => array(),
  62. 'img' => array(),
  63. ),
  64. /**
  65. * URL to your Fuel root. Typically this will be your base URL:
  66. *
  67. * Config::get('base_url')
  68. *
  69. * These MUST include the trailing slash ('/')
  70. */
  71. 'url' => Config::get('base_url'),
  72. /**
  73. * Whether to append the assets last modified timestamp to the url.
  74. * This will aid in asset caching, and is recommended. It will create
  75. * tags like this:
  76. *
  77. * <link type="text/css" rel="stylesheet" src="/assets/css/styles.css?1303443763" />
  78. */
  79. 'add_mtime' => true,
  80. /**
  81. * The amount of indents to prefix to the generated asset tag(s).
  82. */
  83. 'indent_level' => 1,
  84. /**
  85. * What to use for indenting.
  86. */
  87. 'indent_with' => "\t",
  88. /**
  89. * What to do when an asset method is called without a group name. If true, it will
  90. * return the generated asset tag. If false, it will add it to the default group.
  91. */
  92. 'auto_render' => true,
  93. /**
  94. * Set to false to prevent an exception from being throw when a file is not found.
  95. * The asset will then be skipped.
  96. */
  97. 'fail_silently' => false,
  98. );