This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import flask | |
from decorator import decorator | |
def assert_error(): | |
@decorator | |
def _fn(f: callable, *args, **kwargs): | |
try: | |
return f(*args, **kwargs) | |
except Exception as exception: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function dePara(de,para){var t=0;if(document.documentElement.innerText.indexOf(de)===-1)return t;Array.from(document.getElementsByTagName("*")).forEach(function(e){Array.from(e.attributes).forEach(function(f){if(['title','alt'].indexOf(f.name)>-1&&f.value){f.value=f.value.split(de).join(para);t++}});e.childNodes.forEach(function(f){if(f.nodeType===3&&f.nodeValue){f.nodeValue=f.nodeValue.split(de).join(para);t++}})});return t} | |
dePara('Compartilhe','Cadê DeDe???'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pprint | |
html = ( | |
'<p>O <strong><a href="https://www.instagram.com/drviotto/">Dr. Viotto</a>' | |
'</strong> já se tornou referência na ' | |
'<img src=http://slex.com.br/f1.jpg>' | |
'odontologia em nível nacional e um ' | |
'dos mais <img src=\'http://slex.com.br/f2.jpg\' /> slex renomados ' | |
'dentistas do Brasil. Conhecido não apenas dos ' | |
'profissionais da área médica mas também do público em geral por ser o ' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script src="https://code.jquery.com/jquery-3.3.1.js"></script> | |
<script src="https://cdn.datatables.net/1.10.19/js/jquery.dataTables.min.js"></script> | |
<script src="https://cdn.datatables.net/1.10.19/js/dataTables.bootstrap.min.js"></script> | |
<script src="https://cdn.datatables.net/fixedcolumns/3.2.6/js/dataTables.fixedColumns.min.js"></script> | |
<script src="https://cdn.datatables.net/fixedheader/3.1.5/js/dataTables.fixedHeader.min.js"></script> | |
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" /> | |
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.19/css/dataTables.bootstrap.min.css" /> |
OlderNewer