<script>
    

        function message(msgType, msgTitle, msgContent){
            $("#_msgbox").modal('show');
            $("#_msgicon").attr("class",msgType);
            $("#_title").empty();
            $("#_title").append(msgTitle);
            $("#_message").empty();
            $("#_message").append(msgContent);
            var btn ='';
            switch (msgType) {
             case 'infos':
                btn = '<button class="btn btn-primary" data-dismiss="modal" >OK</buton>';
                break;
             case 'warning':
                 btn = '<button class="btn btn-warning" data-dismiss="modal" >OK</buton>';
            break;
            case 'stop':
                    btn = '<button class="btn btn-danger" data-dismiss="modal" >OK</buton>';
                break;
                
                case 'criticalQuestion':
                btn = '<button class="btn btn-danger" data-dismiss="modal" >OK</buton> <button class="btn" data-dismiss="modal" >Cancel</buton>';
                break;
             case 'simpleQuestion':
                  btn = '<button class="btn btn-primary" data-dismiss="modal" >OK</buton> <button class="btn" data-dismiss="modal" >Cancel</buton>';
                break;
            case 'successmsg':
                    btn = '<button class="btn btn-success" data-dismiss="modal" >OK</buton>';
                break;
                
                 case 'errormsg':
                    btn = '<button class="btn btn-danger" data-dismiss="modal" >OK</buton>';
                break;
        }
                 $("#_msgfooter").empty();
            $("#_msgfooter").append(btn);

            
        }



</script>

<style>
    .infos{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 0; width: 128px; height: 128px;
    }
     .warning{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 -178px; width: 128px; height: 128px;
    }
     .stop{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 -890px; width: 128px; height: 128px;
    }
     .criticalQuestion{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 -356px; width: 128px; height: 128px;
    }
     .simpleQuestion{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 -534px; width: 128px; height: 128px;
    }
     .successmsg{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 -1068px; width: 128px; height: 128px;
    }
     .errormsg{
        background: url(../img/msg.png) no-repeat top left;
        background-position: 0 -712px; width: 128px; height: 128px;
    }
    
</style>
<!--

.sprite-1407224123_kdeprint-printer-infos{ background-position: 0 0; width: 128px; height: 128px; } 
.sprite-4449_1309_128_error_warning_icon{ background-position: 0 -178px; width: 128px; height: 128px; } 
.sprite-49950_27380_QuestionMark_128x128_questionmark_icon{ background-position: 0 -356px; width: 128px; height: 128px; } 
.sprite-QuestionMark{ background-position: 0 -534px; width: 128px; height: 128px; } 
.sprite-icontexto_webdev_cancel{ background-position: 0 -712px; width: 128px; height: 128px; } 
.sprite-no{ background-position: 0 -890px; width: 128px; height: 128px; } 
.sprite-ok_check_yes_tick_accept_success-128{ background-position: 0 -1068px; width: 128px; height: 128px; } 

-->
   <div id="content">                        
    <div class="wrap">
        <div style="margin:10px;">
            <a onclick="message('infos','USD SHDBBSUD USD','GJKZJD ADHA JD JAD FJKA CHA F A ADSHAS')" class="btn btn-primary">infos</a>
            <a onclick="message('warning','HXCJS SJHD ','hjjhfdjf jafhkaj ajhf a')" class="btn btn-primary">warning</a>
            <a onclick="message('criticalQuestion','sdD','SDS ADGFAH AG DGA CASGBDU CAH  ?')" class="btn btn-primary">criticalQuestion</a>
            <a onclick="message('stop','GDAJ C JASD JA C',' Z AGD AC ASG DGCAH C')" class="btn btn-primary">stop</a>
            <a onclick="message('simpleQuestion','GAS Dgbucs csaugdbcuaw','ueni  audb  ad')" class="btn btn-primary">simpleQuestion</a>
            <a onclick="message('successmsg','ADH UDBAU CAD ADCC','ed  DU HD CUASD')" class="btn btn-primary">successmsg</a>
            <a onclick="message('errormsg','ADAJ JA DA SDUASD  C','DS  ADU A DHASDS k')" class="btn btn-primary">errormsg</a>
            
        </div>
        
</div>
   </div>
