Hiding the source CSS code

前端 未结 3 1249
后悔当初
后悔当初 2020-12-19 18:31

Hello recently i have seen sites ,that hides their source css when viewed their source! How is this exactly possible.. I assume some javascript may do the trick. this is a

3条回答
  •  悲哀的现实
    2020-12-19 19:16

      Here is Code To Hide Css .
    

    First On javaScript

    $(window).load(function(){//Function call On Load windows
    
        $.post("Ajax.php?action=getCss",{},function(data){//Ajax Request To Css 
            $("#Corecss").html(data);// Paste css in Corecss Div without Shoing             
        });
     });//Thanks Hashaam zahid From Pakistan
    

    2)On Html

    3)on PHP Create Ajax.php File

    if($_GET['action']=='getCss')
    {
    $sDbServerName="localhost";$sDbUserName="***";$sDbPassword="*****";$sDbName="Data";// Connection with database server $dbConnect=mysql_connect($sDbServerName,$sDbUserName,$sDbPassword);if($dbConnect)
    {
    
          echo   '';
    
    
    }
    else
    {
        die("You Cannot Do it With Css");
    }
    
    
    }//Thanks From Hahshaam zahid     ( ittuc.com )  and facebook/HashaamKhan321
    

提交回复
热议问题