DONAŢIE RECURENTĂ
Donează lunar pentru susţinerea proiectului NeculaiFantanaru.com
एक ही डोमेन में बाजार पर अन्य की तुलना में इस पुस्तक की आवश्यक विशेषता यह है कि यह उदाहरणों के माध्यम से एक नेता की आदर्श क्षमता का वर्णन करती है। मैंने कभी यह दावा नहीं किया कि एक अच्छा नेता बनना आसान है, लेकिन अगर लोग करेंगे तो...
मैंने यह पुस्तक लिखी है जो एक सरल तरीके से व्यक्तिगत विकास को नेतृत्व के साथ जोड़ती है, बिल्कुल एक पहेली की तरह, जहाँ आपको सामान्य छवि को फिर से बनाने के लिए दिए गए सभी टुकड़ों का मिलान करना होता है।
इस पुस्तक का उद्देश्य आपको ठोस उदाहरणों के माध्यम से जानकारी प्रदान करना है और आपको यह दिखाना है कि दूसरों को चीजों को आपके समान कोण से देखने की क्षमता कैसे प्राप्त करें।
आप यहां पूरा कोड देख सकते हैं:Https: // passatin.com / 03 मैं ve px में हूं इंस्टॉलपायथन। पायथन कोड स्ट्रिंग को बदल देगा ( ) एक स्थान के साथ और दो सीमाओं के बीच वाले HTML टैग में किसी भी डुप्लिकेट रिक्त स्थान को हटा देंतथा। यह एचटीएमएल टैग में निहित प्रत्येक पंक्ति की शुरुआत और अंत में किसी भी खाली स्थान को भी हटा देगा। मैंने केवल टैग को ध्यान में रखा .. p> .. em> p> <p class="obisnuit"><em> Honor your moral and spiritual obligations .em>p> <p class="nint"> Bishop knew how to say the most meaningful of things speech. p> हो जाएगा: <p class="obisnuit"><em>Honor your moral and spiritual obligations.em>p> <p class="nint">Bishop knew how to say the most meaningful of things speech.p> कोड: किसी भी दुभाषिया कार्यक्रम में नीचे दिए गए कोड को कॉपी और चलाएं(मैं उपयोग करता हूंPyscrcs।"Directory_name =" लाइन पर पथ को बदलने के लिए मत भूलना। import re import os def read_text_from_file(file_path): """ Aceasta functie returneaza continutul unui fisier. file_path: calea catre fisierul din care vrei sa citesti """ with open(file_path, encoding='utf8') as f: text = f.read() return text def write_to_file(text, file_path): """ Aceasta functie scrie un text intr-un fisier. text: textul pe care vrei sa il scrii file_path: calea catre fisierul in care vrei sa scrii """ with open(file_path, 'wb') as f: f.write(text.encode('utf8', 'ignore')) def replace_white_spaces(tag_name, file_path): """ Aceasta functie modifica textul dintre un tag dat ca argument. """ text = read_text_from_file(file_path) text = str(text) articol_pattern = re.compile('[\s\S]*?[\s\S]*?') text_articol = re.findall(articol_pattern, text) if len(text_articol) != 0: text_articol = str(text_articol[0]) pattern = re.compile('<{} class=\".*?\">(.*?){}>'.format(tag_name, tag_name)) tag_texts = re.findall(pattern, text_articol) new_text_articol = text_articol for tag_text in tag_texts: new_text = tag_text.strip() m = re.findall('(.*?)', new_text) if len(m) >= 1: text_em = str(m[0]) text_em_new = text_em text_em_new = text_em_new.replace(r' ', r' ') text_em_new = text_em_new.strip() new_text = new_text.replace(text_em, text_em_new) new_text = new_text.replace(r' ', r' ') new_text = " ".join(new_text.split()) new_text_articol = new_text_articol.replace(tag_text, new_text) text = text.replace(text_articol, new_text_articol) write_to_file(text, file_path) print("Fisierul modificat cu succes este: ", file_path) else: print("Fisierul nu are structura corecta: ", file_path) def gaseste_nbsp(file_path): text_Reg = f.read() def replace_white_spaces_only_html_php(tag_name, directory_name): for root, dirs, files in os.walk(directory_name): for f in files: if f.endswith('html'): file_path = os.path.join(root, f) replace_white_spaces(tag_name, file_path) else: continue if __name__ == '__main__': directory_name = 'c:\\Folder1' tag_name = 'p' replace_white_spaces_only_html_php(tag_name, directory_name) That's all folks. If you like my code, then make me a favor: translate your website into Romanian, "ro". इसके अलावा, एक हैसंस्करण 2इस कोड यासंस्करण 3यासंस्करण 4यासंस्करण 5यासंस्करण 6
|
||||||||||||
![]() |
||||||||||||