Changeset 12786
- Timestamp:
- 11/08/08 22:37:26 (5 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
plugins/sfSmartyPlugin/trunk/lib/helper/AppUrlHelper.php
r11815 r12786 11 11 */ 12 12 function link_to_app($name = '', $internal_uri = '', $options = array(), $app = SF_APP) { 13 $environment = ( SF_ENVIRONMENT == 'prod') ? "" : "_".SF_ENVIRONMENT;13 $environment = (sfConfig::get('sf_environment') == 'prod') ? "" : "_".sfConfig::get('sf_environment'); 14 14 $protocol = (sfContext::getInstance()->getRequest()->isSecure()) ? "https" : "http"; 15 $url = $protocol."://".$_SERVER["SERVER_NAME"]. url_for("").strtolower($app).$environment. ".php/".$internal_uri;15 $url = $protocol."://".$_SERVER["SERVER_NAME"]."/".strtolower($app).$environment. ".php/".$internal_uri; 16 16 return link_to($name, $url, $options); 17 17 }