[Oracle Client] ORA-01019 unable to allocate memory in the user side


Deskripsi
    - This is caused by some of the resources that need by oracle client is protected by operating system (privilage level ?) , usually appear on windows 7 or 8 even the account is Administrator. the solution is simple , just TURN OFF the UAC (User Account Control).

How to 

  1. Open User Account Control Settings by clicking the Start button Picture of the Start button, and then clicking Control Panel. In the search box, type uac, and then click Change User Account Control settings.
  2. Do one of the following:
    • To turn off UAC, move the slider to the Never notify position, and then click OKAdministrator permission required If you're prompted for an administrator password or confirmation, type the password or provide confirmation. 
    • To turn on UAC, move the slider to choose when you want to be notified, and then click OKAdministrator permission required If you're prompted for an administrator password or confirmation, type the password or provide confirmation.
    3. Don't forget to RESTART THE COMPUTER (it doesn't effect if you not restart).

    4. If still occured , reinstall oracle client with UAC off. 

* i tried to figure it out for 3 days LOL :)

[Crystal Report] unable to get the window handle for the axcrviewer9 control Windows 7

Deskripsi 
 Software installation crystal report was success but this component get error when running in windows 7 , in another operating system run well for example windows XP.

 Howto 
1. Just turn OFF DEP (Data Execution Prevention)
2. to turn off go to : START > RUN > CMD > bcdedit.exe /set {current} nx AlwaysOff
3. if the result failed or access denied , CMD must run in administrator, START > RUN > type CMD > Right click CMD and Run in Administrator , and go to step 2 again.
4. Restart Computer

[Cakephp] Styling Pagination Number

Description
        Styling pagination number in cakephp framework.

Requirement
       - Understand cakephp pagination

Howto
1. in view use this code :
<div id="paging">
<?php
echo $this->Paginator->prev('Sebelumnya', array('escape' => FALSE,'tag' => "div class='prevnext'"));
        echo $this->Paginator->numbers(array('separator'=>false,'currentTag'=>"div class='paginationCurrentNumber'",'before' => '','after' => '','tag' => "div class='paginationNumber'"));
        echo $this->Paginator->next('Selanjutnya', array('escape' => FALSE,'tag' => "div class='prevnext'"));
?>
</div>

2. in css add this :
.prevnext{
    color:white;
    text-align: center;
    display:inline-block;
    padding-left: 5px;
    padding-right: 5px;
    margin-left: 1px;
    margin-right: 1px;
    border:1px solid black;
    background: rgb(96,108,136); /* Old browsers */
    background: -moz-linear-gradient(top,  rgba(96,108,136,1) 0%, rgba(63,76,107,1) 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(96,108,136,1)), color-stop(100%,rgba(63,76,107,1))); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* IE10+ */
    background: linear-gradient(to bottom,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#606c88', endColorstr='#3f4c6b',GradientType=0 ); /* IE6-8 */
}

.prevnext:hover{
    background: orange !important;
}

.prevnext a:visited,a:link,a:active{
   color:white;
   text-decoration:none !important;
}

.paginationNumber{
    width:20px;
    display:inline-block;
    text-align: center;
    margin-left: 1px;
    margin-right: 1px;
    color:white;
    border:1px solid black;
    background: rgb(96,108,136); /* Old browsers */
    background: -moz-linear-gradient(top,  rgba(96,108,136,1) 0%, rgba(63,76,107,1) 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(96,108,136,1)), color-stop(100%,rgba(63,76,107,1))); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* IE10+ */
    background: linear-gradient(to bottom,  rgba(96,108,136,1) 0%,rgba(63,76,107,1) 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#606c88', endColorstr='#3f4c6b',GradientType=0 ); /* IE6-8 */
}

.paginationNumber a:visited,a:link,a:active{
   color:white;
   text-decoration:none !important;
}

.paginationNumber:hover{
   background: orange !important;
}

.paginationNumber .current{
   background: white !important;
}

.paginationCurrentNumber{
   width:100%;
   height:100%;
   background:red !important;
}


the result :


*Note : don't forget to declare your css in view.


but if you prefer using bootstrap you use this css (found this code in stackoverflow , works great) :
<div class="pagination pagination-large">
            <ul class="pagination">
                <?php
                    echo $this->Paginator->prev(__('prev'), array('tag' => 'li'), null, array('tag' => 'li','class' => 'disabled','disabledTag' => 'a'));
                    echo $this->Paginator->numbers(array('separator' => '','currentTag' => 'a', 'currentClass' => 'active','tag' => 'li','first' => 1));
                    echo $this->Paginator->next(__('next'), array('tag' => 'li','currentClass' => 'disabled'), null, array('tag' => 'li','class' => 'disabled','disabledTag' => 'a'));
                ?>
            </ul>
          </div>

[HTML] Highlight row when click on table using jquery


description
        - Create table grid with active color (highlight) when clicked a row using javascript (jquery).

howto
1. download jquery.
2. create index.html , css folder(inside the folder create style.css)
    and js folder (inside the folder put jquery file).
3. here's the code :
     - declare js and css.
        <script type="text/javascript" src="js/jquery-1.10.2.js"></script>
        <script type="text/javascript" src="js/jquery-ui-1.10.4.custom.min.js"></script>
        <script type="text/javascript" src="js/jquery-ui-1.10.4.custom.js"></script>
        <link rel="stylesheet" type="text/css" href="css/jquery-ui-1.10.4.custom.css">
        <link rel="stylesheet" type="text/css" href="css/style.css">
 
     - create simple table grid :
       * for row table , give id for example #rowtable
       <table>
            <tr>
                 <th>row 1 , cell 1 , this is header 1</td>
                 <th>row 1 , cell 2 , this is header 2</td>
            </tr>
            <tr id="rowtable">
                 <td>row 2 , cell 1 , this is values 1</td>
                 <td>row 2 , cell 1 , this is values 2</td>
            </tr>
            <tr id="rowtable">
                 <td>row 3 , cell 1 , this is values 1</td>
                 <td>row 3,  cell 1 , this is values 2</td>
            </tr>
       </table>

      - add css code to your style.css
        tr{ /* make sure change cursor when over row , it looks like profesional LOL */
            cursor: pointer;
            cursor: hand;
        }

        #rowtable:hover{
            background:orange !important;
        }

        #rowtable.clicked{ /*it means id='rowtable' class='clicked'*/
            background:orange;
        }

      - now add javascript code using jquery
        $("document").ready(function(){
             $('tr').click(function() {
                      $(this).removeClass("clicked")
                      $(this).addClass("clicked").siblings().removeClass("clicked");
             });
        });

4. DONE , now you can highlight the row when click , and it's automatic remove highlight
    when change to another row :)
     

[PHP] Install Sqlserver driver and extention for PHP


Description
     Install driver and extention sql for php.

Requirement 
     -  OS x86 or 32 bit (XP , MS Win Server 2003)
     -  Apache (Wamp / XAMPP)

Sofware Download info :
    1. Microsoft sqlserver native client 2008 R2
    2. sqlserver extention support for php version under 5.4 but higher than 5.3
    3. if your php version higher 5.4, download extention here
        Microsoft Drivers 3.0 for PHP for SQL Server 

How to
    1. Download sqlserver native client 2008 R2 and sqlserver ext (Download Here)
    2. install sqlserver native client 2008 R2 or higher.
    3. in folder php extention (download in step-1) you will found file with name like
        -php_pdo_sqlsrv_53_ts_vc6.dll
        -php_sqlsrv_53_ts_vc6.dll
        -php_pdo_sqlsrv_53_nts_vc6.dll
        -php_sqlsrv_53_nts_vc6.dll
     here's the meaning :
          * 53 is the meaning for php version higher than 5.3
          * ts / nts (thread safe / non thread safe) , i preffered using thread safe but the default php is nts
          * vc6 , compiler visual c++ 6
     4. for example we use thread safe , so just 2 files we use (if you want use nts is okay )
        -php_pdo_sqlsrv_53_ts_vc6.dll
        -php_sqlsrv_53_ts_vc6.dll
     5. copy that file to C:\wamp\bin\php\php5.3.1\ext\[paste here] (WAMP)
     6. open php.ini and add this line :
         extension=php_pdo_sqlsrv_53_ts_vc6.dll
         extension=php_sqlsrv_53_ts_vc6.dll
     7. restart your webserver, and check the effect when connect sqlserver
     8. if still problem, may be u use OS like Win Server 2012 or later that need ODBC SQL. you can download msodbcsql HERE

NOTE :
     - please always read compatibility(OS) every software requirement before install the software. !!