<a href="https://console.cloud.google.com/apis/credentials">Get Your Api Credentials Here</a> <a href="https://calendar.google.com/calendar">Get your Calender ID</a> <?php include_once("wp-load.php"); function get_calender_events() { $params = array(); /*Get current date*/ $current_date = date('Y-m-d H:i:s'); /*Convert it to google calendar's rfc_format */ $rfc_format = date("c", strtotime($current_date)); $params[] = 'orderBy=startTime'; $params[] ='maxResults=100'; $params[] = 'timeMin='.urlencode($rfc_format); $url_param = ''; foreach($params as $param) { $url_param.= '&'.$param; } $calender_id = "calender_id"; $client_key = "client_key"; $url = "https://www.googleapis.com/calendar/v3/calendars/".$calender_id."/events?key=".$client_key."&singleEvents=true".$url_param; $list_events = wp_remote_post($url, ...
Magento: get skin url, get media url, get base url, get store url
To Retrieve URL path in STATIC BLOCK
To get SKIN URL{{skin url='images/sampleimage.jpg'}}To get Media URL
{{media url='/sampleimage.jpg'}}To get Store URL
{{store url='mypage.html'}}To get Base URL
{{base url='yourstore/mypage.html'}}
TO Retrieve URL path in PHTML
Note: In editing PHTML don't forget to enclode the following code with PHP tagNot secure Skin URL:
<?php echo $this->getSkinUrl('images/sampleimage.jpg') ?>Secure Skin URL
<?php echo $this->getSkinUrl('images/ sampleimage.gif', array('_secure'=>true)) ?>Get Current URL
$current_url = Mage::helper('core/url')->getCurrentUrl();Get Home URL
$home_url = Mage::helper('core/url')->getHomeUrl();Get Magento Media Url
Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK);
Get Magento Media Url
Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA);Get Magento Skin Url
Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_SKIN);Get Magento Store Url
Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB);Get Magento Js Url
Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_JS);
Comments
Post a Comment