Navigation

    SOFTWARE-TESTING.COM

    • Register
    • Login
    • Search
    • Jobs
    • Tools
    • Companies
    • Conferences
    • Courses
    1. Home
    2. Tags
    3. coding
    Log in to post

    • carriann

      No os.mkdir with Russian symbols in Windows
      Software Programming • windows file system python 2.x coding unicode • • carriann  

      2
      0
      Votes
      2
      Posts
      0
      Views

      A

      Always use Unicode for Windows. Windows is the home of Unicode API. #!/usr/bin/env python import io import os with io.open('dop.txt', encoding='utf-8') as file: for dirpath in file: print(dirpath) os.mkdir(dirpath.strip()) Call your attention is a complete code. Details: https://ru.stackoverflow.com/q/527815/23044 Ubuntu makes the same violin work great. What's the problem?There are several problems:line.endswith('\n'): At the end of the line, there is usually a symbol of the new line '\n'*nix may allow arbitrary baytes in the name of the file other than the slush '/' and zero '\0'♪ Windows, usually. https://en.wikipedia.org/wiki/Filename#Comparison_of_filename_limitations for example: 0x00-0x1F 0x7F " * / : < > ? \ | symbols reserved, which includes '\r' (0x0D) '\n' (0x0A). Call. dirpath.rstrip('\n')to remove the new line from the nameUse utf-8 instead sys.getfilesystemencoding()which is most likely equivalent cp1251 Coding on the Russian Windows (utf-8 is not the original codepage on any Vinde), which at best leads to https://ru.stackoverflow.com/q/229015/23044 Using the bikes instead of unicode for file names. Which may impose additional restrictions on the allowed names on Windows.If print(dirpath) The line is complicated, see. https://ru.stackoverflow.com/q/141035/23044 Outside, throw out the book that told you sys.setdefaultencoding() and f.xreadlines() Use (and to a lesser extent if the book advises f.close() instead with- Designs.
    • B

      How do you get a Cyrillian from EditText to Android Studio on the server in the code?
      Software Programming • java android utf 8 coding • • baileigh  

      2
      0
      Votes
      2
      Posts
      0
      Views

      A

      If you put the line on the server through json, add a description to the transferable field:"Content-Type: text/plain; charset=UTF-8"
    • Marcee

      AJAX
      Software Programming • php html ajax xml coding • • Marcee  

      2
      0
      Votes
      2
      Posts
      0
      Views

      E

      So if the page in the utph-8 and the oyachs goes to the utph8 (the oyax is always in this code), we need to check the file that the request processes, its code and its left symbols, whether it's okay.
    • J

      Spring-boot application error
      Software Programming • java spring boot maven intellij idea coding • • jonetta  

      2
      0
      Votes
      2
      Posts
      0
      Views

      E

      At the launch through mvn spring-boot:run caught the same mistake. Decided disposal application.properties row file spring.mandatory-file-encoding=UTF-8
    • P

      OpenServer MS SQL Php auto-converting any ISO-8859-1 encrypted in bd
      Software Programming • php sql server sql coding openserver • • Pearlaqua  

      2
      0
      Votes
      2
      Posts
      0
      Views

      morde

      Try to compare the table: utf8-general-ci
    • E

      ORDER is not correctly sorted by
      Software Programming • php sql coding • • emerson  

      2
      0
      Votes
      2
      Posts
      0
      Views

      E

      In the heading, the answer should be utf-8.header('Content-Type: text/html; charset=utf-8');
    • R

      Windows Consolidation/drip
      Software Programming • c++ windows coding • • Rossere  

      2
      0
      Votes
      2
      Posts
      0
      Views

      K

      Check the coding of compiled files.
    • J

      Problem withword code
      Software Programming • c sharp coding comparator • • Jolied  

      2
      0
      Votes
      2
      Posts
      0
      Views

      S

      As specified https://stackoverflow.com/a/7883713/276994 , for new versions of HtmlAgilityPack, you use it, right?var web = new HtmlWeb() { AutoDetectEncoding = false, OverrideEncoding = Encoding.GetEncoding(какая там вам надо) }; var document = web.Load(url); // и т. д.
    • S

      Incorrect row size for use of kyrils
      Software Programming • c++ ubuntu qt5 coding local • • shizuka  

      2
      0
      Votes
      2
      Posts
      0
      Views

      R

      Default, Ubuntu is all coded UTF8. The Russian symbols are two bytes, not one by one. strlen returns the length of the line in the whites and not in the symbols, so the answer 56 (26*2+4=56) is correct.
    • Marcee

      Amend the UTF-8 code
      Software Programming • php coding • • Marcee  

      2
      0
      Votes
      2
      Posts
      0
      Views

      N

      solved the problem by: http://popoff.donetsk.ua/text/work/libs/a/charset/ ♪ Action: Make windows-1251, windows 1251 iconv We're moving to utf-8.
    • A

      What to add to the code to ensure that applications are correctly displayed
      Software Programming • php coding • • Anderson  

      2
      0
      Votes
      2
      Posts
      0
      Views

      K

      If the source of the site in UTF is coded, you need Outlook to work with this code. Outlook, the old default program is using windows coding.or use a function http://www.php.su/iconv() But I would have done it first.♪
    • A

      Javascript read the contents of the input file and download through XMLHtpRequest
      Software Programming • javascript ajax coding upload base64 • • Avante  

      2
      0
      Votes
      2
      Posts
      0
      Views

      T

      You're taking the file strangely, suggesting two simpler options:1.FormData design with the form of the filevar fd = new FormData($('#myfile').parents('form:first')[0]); //но название на стороне сервера будет как name у input-а #myfile 2. Add the file to FormData.var fd = new FormData(); fd.append('file', $('#myfile')[0].files[0], "myfile.exe"); All right, we can go to xhr. On the server's side, work the same way with the file in the usual way.UPD:If it tasks to download the file, it's a pre-contained input=file row: try instead. readAsDataURL ♪ https://developer.mozilla.org/en-US/docs/Web/API/FileReader/readAsText ♪ As MDN says, there's a certain code. And with this text, create a Blob. I hope it helps, but I'm not sure.UPD2:And there's practical. https://stackoverflow.com/questions/16245767/creating-a-blob-from-a-base64-string-in-javascript You're the Blob from base-64.
    • Demir

      Protection of the code on the page
      Software Programming • javascript html coding protection • • Demir  

      2
      0
      Votes
      2
      Posts
      0
      Views

      B

      All the actions you've said can't be defended. But even if it were possible, we could use the trafif (sniffers) analyzers, which could easily look at any code. For example, Charles or wireshark♪PS. It must be understood that any html,css,js that a client receives cannot be protected from search, that is, it must be transmitted online and performed by the client, which means that it can be viewed not only by the JS movement but also by the person:DPPS. but to protect the code(js) - oxidators may be used either: JSmin, Closure compiler, YUI Compressor. It is not possible to protect css and html (although it may be minimised, of course, but it's two seconds of any IDE that's a readable species.)
    • Y

      Coding problem
      Software Programming • coding httphtml • • yajahira  

      2
      0
      Votes
      2
      Posts
      0
      Views

      T

      The originals didn't look, but if that's true, when the violin keeps in the bud, somehow it's not called. mysql_set_charset('utf8'); at every condom, it's has to be called by the bd.And don't forget the vermeta http-equiv= "Content-Type" content="text/html; charset=UTF-8" / line heading. We don't have a holivar - everywhere UTF8.
    • A

      Transmission of Russian symbols in response.sendRedirect(url)
      Software Programming • java jsp coding redirect parameter • • amarantha  

      2
      0
      Votes
      2
      Posts
      0
      Views

      Bogopo

      help redirect through the disspatcher. getServletContext().getRequestDispatcher("/pages/books.jsp")‌​.forward(request,res‌​ponse);
    • Marcee

      How do you know the BLOB column code?
      Software Programming • sql oracle coding • • Marcee  

      2
      0
      Votes
      2
      Posts
      0
      Views

      E

      It is not possible to find out if the text is codified, but only the one who kept it. Like Latin Ä and Cyril Ф♪ We know the code in which they want to be preserved:create table t1 as select 1 id, convert ('Ä', 'we8iso8859p1') ch from dual union all select 2 id, convert ('Ф', 'cl8iso8859p5') ch from dual / Now, who reads these data can find out where ÄWhere Ф?select id, dump (ch) from t1 / ID DUMP(CH) ---------- ------------------ 1 Typ=1 Len=1: 196 2 Typ=1 Len=1: 196 Also tell me how to change the coding of such a column?Coding is available, the OBD itself or the OBD session, and this is removed to all symbols columns. Columns with data type BLOB - it's just the sequence of the baths, their code is not known (see example above).
    • K

      Receipt of the heading in the relevant code
      Software Programming • php coding recoding • • Kadir  

      2
      0
      Votes
      2
      Posts
      0
      Views

      inna

      You can come with me. title I'm sorry. value <meta charset=""> - and then convert title by this value utf-8or use it to encode the page depending on your tasks.
    • Demir

      Why is it that when you move the hostess site to the hostel, there's a coding error?
      Software Programming • php mysql wordpress hosting coding • • Demir  

      2
      0
      Votes
      2
      Posts
      0
      Views

      Laycee

      It was have to be replaced in the config.php file: define('DB_CHARSET', 'utf8mb4'); ♪ define('DB_CHARSET', 'utf8'); And it works!
    • C

      Android Studio Kracautiabras in java 1.8
      Software Programming • android studio coding • • chanisef  

      2
      0
      Votes
      2
      Posts
      0
      Views

      A

      He wrote in support of Google. They made a report. Answer:Studio team has said this is likely an issue in Jack. Marking this as a blocker for investigation.We've got the best priority, Blocker. O_o : So they'll lock it up soon. ♪ ♪
    • Laycee

      Cyrillian transformation problem in Ruby
      Software Programming • ruby coding • • Laycee  

      2
      0
      Votes
      2
      Posts
      0
      Views

      Demir

      The problem known, in fact definitively at Ruby's level, will be solved after the release of Ruby 2.4, which will allow full Unicode-Mapping from the box, then you won't need any additional libraries and the next code will work correctly.a = "Андрей" a.downcase
    • 1
    • 2
    • 3
    • 4
    • 5
    • 26
    • 27
    • 1 / 27