Posts

Showing posts from June, 2011

Facebook things done by Rupak Nepali

How to make facebook like button for the dynamic page <iframe style="overflow: hidden; border: 0px none; width: 120px; height: 35px;" src="//www.facebook.com/plugins/like.php?href=<?php echo urlencode(" http://%22.$_server[%22server_name%22].$_server[%22request_uri/ "]); ?>&amp;layout=button_count&amp;show_faces=false&amp;width=150&amp;action=like&amp;font=arial&amp;layout=button_count"></iframe> In this <iframe make space for the facebook to comunicate with the site style="overflow: hidden; border: 0px none; width: 120px; height: 35px;" style for the frame's data src="//www.facebook.com/plugins/like.php?href=<?php echo urlencode(" http://%22.$_server[%22server_name%22].$_server[%22request_uri/ "]); ?> source file to be liked. <?php echo urlencode(" http://%22.$_server[%22server_name%22].$_server[%22request_uri/ "]); ?> url that we inserted other are optional f

Collection of function and objects

currency: set($currency): Set the currency to be used in overall site. public function set($currency) {                 $this->code = $currency;                 if ((!isset($this->session->data['currency'])) || ($this->session->data['currency'] != $currency)) {                                 $this->session->data['currency'] = $currency;                 }                 if ((!isset($this->request->cookie['currency'])) || ($this->request->cookie['currency'] != $currency)) {                                                 setcookie('currency', $currency, time() + 60 * 60 * 24 * 30, '/', $this->request->server['HTTP_HOST']);                 }                 } format($number, $currency = '', $value = '', $format = TRUE): public function format($number, $currency = '', $value = '', $format = TRUE) {                                 if ($currency &&