membuat environment development testing dan production

pada yii di index file kita akan merubah / menambah

[code]
//choose environment development
$appEnv = filter_input(INPUT_ENV, ‘APPLICATION_ENV’, FILTER_SANITIZE_ENCODED);
$serverName = filter_input(INPUT_SERVER, "SERVER_NAME", FILTER_SANITIZE_SPECIAL_CHARS);
if (!isset($appEnv)) {
if (true === stripos($serverName, ‘localhost’)) {
$appEnv = "development";
} else
if (true === stripos($serverName, ‘www.meltonice.com’)) {
$appEnv = "testing";
} else
if (true === stripos($serverName, ‘www.kresna.host’)) {
$appEnv = "production";
} else {
$appEnv = "development";
}
}
if ($appEnv == "production") {
$config = dirname(__FILE__) . ‘/protected/config/production.php’;
}
if ($appEnv == "development") {
// remove the following lines when in production mode
defined(‘YII_DEBUG’) or define(‘YII_DEBUG’, true);
$config = dirname(__FILE__) . ‘/protected/config/main.php’;
}
if ($appEnv == "testing") {
$config = dirname(__FILE__) . ‘/protected/config/testing.php’;
}

[/code]

sehingga kita dapat membuat file config masing2 dan tanpa repot untuk merubah setting dan konfigurasi untuk database, logging dan lain sebagainya 😀

redirect dengan count down

sebelum saya tertidur karena mengantuk dan kondisi kurang fit saya akan membagikan info tentang bagaimana redirect menggunakan ajax beserta count down js 😀

pertama install ecountdown action

lalu set flash yang akan di tampilkan beserta countdownnya dan ajax request

[code]
<?php if (Yii::app()->user->hasFlash(‘order’)) { ?>

<div class="flash-success">
<?php echo Yii::app()->user->getFlash(‘order’); ?>
</div>
<?php
$this->widget(‘ext.ecountdownaction.ECountdownAction’, array(
‘seconds’ => 10, //8 seconds
‘action’ => ‘   $.ajax(
{
type: "POST",
url: location.pathname+"/index.php?r=site/redirect",
success: function (results)
{
obj = JSON.parse(results);

window.location.href=obj.redirect;
}
});’, //action code…
)
);
}
//
//$this->redirect(array(‘user/registration’), array(‘model’ => new LoginForm));
?>

[/code]

 

lalu pada controller

[code]
public function actionRedirect() {
echo json_encode(array(‘redirect’ => $this->createUrl(‘/user/registration’)));
}

[/code]

 

cukup sederhana tapi membuat pusing LOL

The the front stage for which ever took place straight to Roblox

Roblox would be a MMOG (Massively Multiplayer online video game), all of which was initially printed 11 years back available on 2006. The video game was supposed and then targeted to the generation of roughly 8-18 season olds. Roblox is a casino game where to license your body’s more info about roblox creativeness run wild, because you’re capable to build up your body’s personal solitary electronic globe, and at what ever colors, sizes and then shapes on you cardiovascular system tendencies to put during this electronic globe. Once an internationally is initiated, fellow Roblox players and then allowed to roam completely free available on your body’s globe, admire the words you’ve supposed and then socialize and at others. Gamers possess his or her personal currency, known as Robux, all of which can be used to pay for available on video game entails which includes having the ability to instruct firms available on the price of a hundred Robux if ever that they have a built-in membership to the video game. In addition, so you can get an equal acceleration of creating an organization, members can also upload a unique clip of arrive into the video game. So you can get just one more 500 Robux, members are able to build a clan covering the league they supposed. So you can get a single,000 Robux, Robloxians have the choice so that you can adjust his or her name during the video game, that’ll be probably the most remembered usages of Robux. Along with all this, players then possess various ways available on wasting his or her next to impossible gotten available on video game currency, suc because having the ability to pay for customized towel in one catalogue because of their globe, and at the purchase price differing depending on the supplement ordered. Just how to play Roblox

Among the cold regions of Roblox is the belief that there are plenty of flows the video game is seen and then played. You can not only have done the particular video game available on a pc, you may also download and then have done that it by yourself iPhone or your body’s android mobile phone, and also other Apple towel including the Mac, too having the ability to have done that it on a iPod contact. It means the video game is conveniently accessible through to everyone and then anyone who’s thinking in certain. All of our Roblox Hack so you can get completely free Robux in certain all of our Roblox Robux Generator

At this time that we’ve rid of during the period of Roblox, i can get right down to the real reason why you’re pay attention to. We’re heading go over some of the features of all of our hacking / which makes instrument.

How through to utilize the Moviestarplanet hack and then retrieve 100 % pure results

MovieStarPlanet is normally in the near future becoming a chart topper available on all of the cellular gaming will bring. Within the last few months, that our audience will bring won countless requests right from populace available on that our further sites to set a young helpful MSP Hack around this widespread refreshing video game. That our audience didn’t go wrong to supply either. Arranging by far the most area associated with the art online hack deployment technologies out there, populace be capable of in the near future and in the near future mod their accounts from your video game. You need not bring all of us and at any personal information to try and get it done either. In fact, i bring many of the most weighty safety habits which then retain you plus your standing up cautiously anonymous most often. Take benefit of among the best suggestions to hack MovieStarPlanet online cautiously at this point. If you can follow a touch of, simple steps, i can get you begun over night. That our reply expects you right from that our home page on to the video game in just minutes. The job available on which you spot upgrades is incredibly gentle, i have even spot habits which are very easy and look for. There is absolutely no nice programming notion key in order to run that our device, we’ve manufactured a highly friendly interface which then simplifies the job to try and its strategic. So if you follow all of the habits cautiously you will total in just minutes some time. MovieStarPlanet is normally in the near future obtaining an example of the most popular refreshing releases from your cellular gaming sector. From your video game, your mission is normally simple: end up being the most popular superstar. And at YouTube relationships, and an active online local featuring an in-game speak computer software, it’s easy to see how the particular video game would take the marketplace by the story. The largest delivering step that our audience comprehensive since evaluating off their hacks and playing MovieStarPlanet was either a seemingly endless level of customization either a video game made possible as the user’s avatar progresses from your video game. The largest expects right from that our populace were to greatly help them get to any of these amounts much quicker than the video game made possible available for. All came across grown tired to achieve repetitive tasks over and over to attempt to occur. That it only kills either a fun from your video game. In place of all that, then they desirable an instrument just like the one particular we’ve available for that our home page. How it works

That our tools are organized online, hence there is absolutely no guessing video game about what is normally or has not been safe to try and download. That our audience expected for which all online populace will try and stay away from needing to download anything they can proceed without on the cellular device. Available on free vp msp strategic, making an effort extra applications and service provider will kill your battery, and at worst, the software can often contain pathogen horses and spyware that will non-etheless your personal information strategic off your device. You can also find sites that will call on populace because of their in-game login specifics, their google was feeling, and iTunes specifics, and outside of. Available on Msphacked. Com, in place of going through all that, that our hack device continues to be anonymous, is normally free to use, and expects and no personal information in any way. Populace only hop available on, use that our device, and return to either a video game. That our encrypted servers retain the majority of your details safe. I retain strategic associated with the line safety available on that our home page, hence populace don’t have to worry about it. Advances

That our refreshing MSP Hack is available and most often up to date, left over them easy to use. As well as its phenomenal uptime and achievement swiftness, i also have added quite a few refreshing functions too. As soon as arranging MSPHacked, i was feeling that it was vital that you give off that our user’s privacy and of course safety helpful. Unlike a great many other tools for you to become aware of online, that our service provider will bring built-in a mix of a touch of functions for which permit you to notion safe when using that our computer software. We’ve added weighty additions which has proxy service provider. Your first step between the thousands of a touch of loyal proxies for you to use to hide your difference available on the internet! that our proxies are private hence there is absolutely no method for either a video game to try and acknowledge which the accurate difference, or you are gentle developing a proxy in the first place. Safety

As well as gentle proxy service provider, either a audience will bring made a decision to proceed to some other gentle within this safety functions. Around this i made a decision to spot our very own VPN on to the hack device. You can now go for a certain server to get to that our online generator for which expects the complete privacy technique to its strategic level of safety. There have been and no banns thus far within this device and i desire to retain that it for which strategy. Return to playing either a video game the way you have done in place of needing to pay to try out! we will be right here to help you end up being the primary participant you are and of course save you for which hard won buck. Are not able to waste materials your potential and fly the primary by the hottest refreshing video game of the entire year. MSPHacked will finally permit you to enjoy the video game so how it’s truly designed to end up being.

install composer via brew :D

ketika akan menginstall yii2 di mac osx yang memakai composer , kemudian muncul error sebagai berikut :

 brew install composer PHP Warning:  Module ‘curl’ already loaded in Unknown on line 0 composer: Missing PHP53, PHP54, PHP55 or PHP56 from homebrew-php.

 

kemudian saya mengatasi nya dengan browsing di google dan menemukan source yang memberikan tulisan sebagai berikut :

brew install php56

kemudian ternyata masih belum bisa memakai composer 🙁

masih harus doing this ->

curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer

dan somehow 
tidak bisa memakai php composer.phar jadi hanya memakai composer saja 😀

php extension untuk mac osx maverick

http://stackoverflow.com/questions/6588174/enabling-postgresql-support-in-php-on-mac-os-x

The PHP version that comes bundled with OS X doesn’t include PostgreSQL. You’ll have to compile the extension yourself. Here are some instructions:

  1. Find your version of PHP: php -v.
  2. Download the version of PHP that matches yours: curl -O http://us.php.net/distributions/php-5.3.3.tar.gz. (This example downloads PHP 5.3.3 but this must match your version)
  3. Extract the archive you downloaded: tar -xzvf php-5.3.3.tar.gz
  4. Change to the PostgreSQL’s extension directory: cd php-5.3.3/ext/pgsql/
  5. Type phpize.
  6. Type ./configure.
  7. Type make.
  8. Type sudo make install.
  9. Add the extension to you php.ini file by adding extension=pgsql.so. (You may already have done this)
  10. Restart Apache.

Update for OS X Mountain Lion Apple has removed autoconf from the newer versions of XCode so the procedure above will fail at #5. To solve that problem:

  1. Type /usr/bin/ruby -e "$(/usr/bin/curl -fksSL https://raw.github.com/mxcl/homebrew/master/Library/Contributions/install_homebrew.rb)". *->kecuali yang ini tidak bisa di pakai
  2. Type sudo chown -R $USER /usr/local/Cellar.*->ini juga gak perlu
  3. Type brew update.
  4. Type brew install autoconf.

That should install autoconf and allow you to install the module using the instructions above.

*tutorial di atas juga dapat di gunakan untuk curl ataupun extension yang lain untuk php extension ketia bermasalah

 

**note untuk install mcrypt harus install terlebih dahulu libmcrypt yang bisa di download di sini

  1. cd libmcrypt-2.5.8
  2. ./configure
    make
    sudo make install

kalau sudah baru lanjutkan di php/ext/mcrypt

phpize ./configure dan seterusnya