CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: Html & css

  1. #1
    Join Date
    Jul 2014
    Posts
    1

    Html & css

    <style>
    .msgBox{
    position:absolute;
    z-index:10;
    border-radius:5px;
    border:1px solid #F5F5F5;
    background-color:#DDD;
    box-shadow:1px 1px 5px #999;
    overflow:hidden;
    display:none}
    .msgBox ul, .msgBox li{
    list-style:none;
    padding:0;
    margin:0;
    border:0}
    .msgBox .title{
    border-bottom:#AAA solid 1px;
    padding:5px;
    background-color:#CCC;
    font-family:Gotham, "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-weight:bold;
    text-shadow:1px 1px #DDD;
    font-size:12px}
    .msgBox .msgContent{
    border-top:#F5F5F5 solid 1px;
    padding:5px;
    text-shadow:1px 1px #F1F1F1;
    font-family:Cambria, "Hoefler Text", "Liberation Serif", Times, "Times New Roman", serif;
    font-size:12px}
    .msgBox .ok{
    text-shadow:1px 1px #F1F1F1;
    font-family:Cambria, "Hoefler Text", "Liberation Serif", Times, "Times New Roman", serif;
    font-size:12px;
    margin:0 auto 5px auto;
    width:20px;
    padding:4px 5px 4px 5px;
    background-color:#CCC;
    text-align:center;
    cursorointer;
    transition:all 300ms linear;
    border:#DDD solid 1px;
    box-shadow:0 0 1px #AAA;
    border-radius:4px}
    .msgBox .ok:hover{
    background-color:#EEE}
    </style>
    <div class="msgBox">
    <ul class="title">Alert</ul>
    <ul class="msgContent">Friv 2015</ul>
    <ul>
    <li class="ok">Ok</li>
    </ul>
    </div>
    <script src=""></script>
    <script language="javascript">
    // Upgraded confirm function
    var msgBox = function(msg){
    var w =$(document).width(),
    h = $(document).height();
    var msgW = $('.msgBox').width(),
    msgH = $('.msgBox').height();
    $('.msgBox').css({leftw-msgW)/2, toph-msgH)/2});
    $('.msgBox')
    .show()
    .find('.msgContent').text(msg);
    $('.msgBox').find('.ok').click(function(){
    $('.msgBox').hide();
    });
    $(document).keyup(function(event){
    if(event.which==13){
    $('.msgBox').hide();
    }
    });
    }
    msgBox('Enter your message!');
    </script>

  2. #2
    2kaud's Avatar
    2kaud is offline Super Moderator Power Poster
    Join Date
    Dec 2012
    Location
    England
    Posts
    7,824

    Re: Html & css

    and........... Is there a question here somewhere?

    Also when posting code, please use the proper tags. Go Advanced, select the code and click '#' or '<>' or 'php' as appropriate.
    All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!

    C++23 Compiler: Microsoft VS2022 (17.6.5)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured