Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="">
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>separador mail</title>
- <style>
- *{
- margin:0;
- padding: 0;
- box-sizing: border-box;
- }
- body{
- display: grid;
- justify-content: center;
- background: #cecece;
- }
- h1{
- color: #FF0000;
- text-align: center;
- text-shadow: 2px 2px 5px #ffff00;
- font-weight: 1em;
- }
- #result{
- max-width: 980px;
- width: 100%;
- display: flex;
- justify-content: center;
- }
- .ocorencia{
- width: 300px;
- margin: 0 auto;
- display: flex;
- justify-content: center;
- }
- .btn{
- display: flex;
- justify-content: center;
- margin-top: 10px;
- margin-bottom: 5px;
- }
- input[type="text"]::placeholder{
- color: red;
- text-align: center;
- }
- input[type="submit"]{
- background: #00FF00;
- max-width: 200px;
- width: 100%;
- height: 40px;
- font-weight: 900;
- color: #fff;
- background: green;
- border: none;
- cursor: pointer;
- }
- input[type="submit"]:hover{
- background: #00FF00;
- background: #00FF00;
- max-width: 210px;
- height: 43px;
- }
- .footer{
- max-width: 550px;
- width: 100%;
- position: absolute;
- bottom: 0px;
- text-align: center;
- }
- @media screen and (max-width: 550px){
- .text{
- max-width: 550px;
- width: 100%;
- }
- textarea{
- width: 90%;
- margin-left: 5%;
- margin-right: 5%;
- }
- }
- </style>
- </head>
- <body>
- <div>
- <h1>Separador por ocorrências</h1>
- </div>
- <div>
- <form action="" method="post">
- <div class="text">
- <textarea name="list" id="" cols="60" rows="10"></textarea>
- </div>
- <div class="ocorencia">
- <input type="text" name="ocorencia" placeholder="Ocorrência">
- </div>
- <div class="btn">
- <input type="submit" name="btn">
- </div>
- </form>
- </div>
- <div id="result">
- <?php
- error_reporting(0);
- set_time_limit(0);
- if(isset($_POST['btn'])){
- $sec = $_POST['list'];
- if($sec !=""){
- extract($_POST);
- $lines = explode(PHP_EOL, $list);
- $oc=$_POST['ocorencia'];
- $c=count($lines);
- for($x=0;$x<$c;$x++){
- $_line=$lines[$x];
- $str = strstr($_line,$oc);
- if($str==true){
- echo $_line."<br>";
- flush();
- ob_flush();
- }
- }
- }else{
- echo "LISTA VASIA!";
- }
- }
- ?>
- </div>
- <footer>
- <div class="footer">
- Para utilizar basta colocar a string na caixa de ocorencia e sua lista(email, log etc..)
- <p>Coder:Paulo Tk ph4x35 - irc.silverlords.org</a></p>
- </div>
- </footer>
- </body>
- </html>
Add Comment
Please, Sign In to add comment