Search Results

Search found 5303 results on 213 pages for 'encoding'.

Page 9/213 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • how to know which special character is there in a file?

    - by Pangea
    My app needs to process text files during a batch process. Occassionally I receive a file with some special character at the end of the file. I am not sure what that special character is. Is there anyway I can find what that character is so that I can tell the other team which is producing that file. I have used mozilla's library to guess the file encoding and it says UTF-8.

    Read the article

  • how to convert unicode to printble string in QT stream

    - by user63898
    hi i writing stream in to file and stdout but im getting somekind of encoding like this: "\u05ea\u05e7\u05dc\u05d9\u05d8 \u05e9\u05e1\u05d9\u05de\u05dc \u05e9\u05d9\u05e0\u05d5\u05d9 \u05d1\u05e1\u05d2\u05e0\u05d5\u05df \u05dc\u05d3\u05e2\u05ea\u05d9 \u05d0\u05dd \u05d0\u05e0\u05d9 \u05d6\u05d5\u05db\u05e8 \u05e0\u05db\u05d5\u05df" how can i convert it to printable string

    Read the article

  • Encoding Special Characters For Outlook HTML Email

    - by n0chi
    I have an asp.net / C# page which takes a comment, and then emails that comment. Sometimes when the user enters "&" in the comment, the comment is being truncated. So for example if the comment is "test & test" the email only sends out "test ". I have tried HttpUtility.HtmlEncode - but it looks like the issue is on the outlook side and not on the C# side.

    Read the article

  • Rle Encoding...What's the wrong?

    - by FILIaS
    I'm trying to make a Rle Encoder Programme.I read the way it works on notes on net. And i tried to fix my code! Regardless I think that the structure and logic of code are right,the code doesnt work! It appears some strange 'Z' as it runs. I really cant find what;s wrong! Could u please give me a piece of advice? Thanx in advance... #include <stdio.h> int main() { int count; unsigned char currChar,prevChar=EOF; while(currChar=getchar() != EOF) { if ( ( (currChar='A')&&(currChar='Z') ) || ( (currChar='a')&&(currChar='z') ) ) { printf("%c",currChar); if(prevChar==currChar) { count=0; currChar=getchar(); while(currChar!='EOF') { if (currChar==prevChar) count++; else { if(count<=9) printf("%d%c",count,prevChar); else { printf("%d%c",reverse(count),prevChar); } prevChar=currChar; break; } } } else prevChar=currChar; if(currChar=='EOF') { printf("%d",count); break; } } else { printf("Error Message:Only characters are accepted! Please try again! False input!"); break; } } return 0; } int reverse(int x) { int piliko,ypoloipo,r=0; x=(x<0)?-x:x; while (x>0) { ypoloipo=x%10; piliko=x/10; r=10*r+ypoloipo; x=piliko; } printf("%d",r); return 0; }

    Read the article

  • Encoding a email address that can be used as part of a URL in codeigniter

    - by freedayum
    Is there a way to encode a email address that can be used as a part of a url in codeigniter?. I need to decode back the email address from the url. What I am trying to do is just a -forgotten password recovery- thing. I send a confirmation link to the user's email address, the link needs to be like ../encodedEmail/forgottenPasswordCode (with the forgottenPasswordCode updated in the db for the user with the submitted email). When the user visits that link, I decode the email(if the email - forgottenPasswordCode pair is in the table), i allow them to reset their password (and i reset forgottenPasswordCode back to null). I could just do a loop -checking the table with a select query- (or) -set that forgottenPasswordCode column unique, so i keep generating on a insert failure(would that be a lot faster ?)- until I generate a forgottenPasswordCode that doesn't already exist in the table. But the guy I do this for would not accept it this way:). He wants the checking be done with the user's email, he thinks its much faster. I am working with codeigniter, I used its encode() function, it seems to produce characters like '-slashes-' at times that breaks the encoded-email-string. Any other ideas?

    Read the article

  • MP3 Encoding in Java

    - by Mohit Nanda
    I need an OpenSource API in Java, which can encode *.wav and *.au formats to MP3, and vice-versa. Have evaluated Java Sound API, and LameOnJ, but they dont meet the requirements and aint stable, respectively. Please suggest one that is free, and platform independent.

    Read the article

  • Getting started with character and text processing (encoding, regular expressions)

    - by TK
    I'd like to learn foundations of encodings, characters and text. Understanding these is important for dealing with a large set of text whether that are log files or text source for building algorithms for collective intelligence. My current knowledge is pretty basic: something like "As long as I use UTF-8, I'm okay." I don't say I need to learn about advanced topics right away. But I need to know: Bit and bytes level knowledge of encodings. Characters and alphabets not used in English. Multi-byte encodings. (I understand some Chinese and Japanese. And parsing them is important.) Regular expressions. Algorithm for text processing. Parsing natural languages. I also need an understanding of mathematics and corpus linguistics. The current and future web (semantic, intelligent, real-time web) needs processing, parsing and analyzing large text. I'm looking for some resources (maybe books?) that get me started with some of the bullets. (I find many helpful discussion on regular expressions here on Stack Overflow. So, you don't need to suggest resources on that topic.)

    Read the article

  • Character Encoding problem?

    - by JasonS
    Hi, In my mysql database I have the following information in a page name field. ç,Ç,ö,Ö,ü,Ü,i,I,s,S,g,G If I do a phpmyadmin dump the above is exported. I am using a different php script and instead of the above I am getting this. "\303\247,\303\207,\303\266,\303\226,\303\274,\303\234,\304\261,\304\260,\305\237,\305\236,\304\237,\304\236" This is the snippet which is generating the output. $data_sql = "SELECT * FROM ".$table_name; $data_res = @mysql_query($data_sql); while($data_row = @mysql_fetch_array($data_res,MYSQL_NUM)) { print_r($data_row); } How can I modify this to make sure that the data is correct? Is some sort of php function required? Do I need to do something to the file? Any advice is much appreciated.

    Read the article

  • Text encoding in HTML text fields

    - by joe
    I have a site up that has a form on it. The form POSTs to a php script which then inserts the data into my database. The page has a charset=UTF-8 attribute in the <meta> tag, and the database is setup to use UTF-8. However, when I copy and paste characters from MS Word into the field, the output is messed up. For example, the quotes in I am using "Microsoft Word" '''' become I am using “Microsoft Word†???? in the database. Anyone have any idea why this might occur?

    Read the article

  • Encoding / Error Correction Challenge

    - by emi1faber
    Is it mathematically feasible to encode and initial 4 byte message into 8 bytes and if one of the 8 bytes is completely dropped and another is wrong to reconstruct the initial 4 byte message? There would be no way to retransmit nor would the location of the dropped byte be known. If one uses Reed Solomon error correction with 4 "parity" bytes tacked on to the end of the 4 "data" bytes, such as DDDDPPPP, and you end up with DDDEPPP (where E is an error) and a parity byte has been dropped, I don't believe there's a way to reconstruct the initial message (although correct me if I am wrong)... What about multiplying (or performing another mathematical operation) the initial 4 byte message by a constant, then utilizing properties of an inverse mathematical operation to determine what byte was dropped. Or, impose some constraints on the structure of the message so every other byte needs to be odd and the others need to be even. Alternatively, instead of bytes, it could also be 4 decimal digits encoded in some fashion into 8 decimal digits where errors could be detected & corrected under the same circumstances mentioned above - no retransmission and the location of the dropped byte is not known. I'm looking for any crazy ideas anyone might have... Any ideas out there?

    Read the article

  • URL encoding for latin characters in Java

    - by sammichy
    I'm trying to read in an image URL. As mentioned in the java documentation, I tried converting the URL to URI by String imageURL = "http://www.shefinds.com/files/Christian-Louboutin-Décolleté-100-pumps.jpg"; URL url = new URL(imageURL); url = new URI(url.getProtocol(), url.getHost(), url.getFile(), null).toURL(); URLConnection conn = url.openConnection(); InputStream is = conn.getInputStream(); I get the following error when the code is executed http://www.shefinds.com/files/Christian-Louboutin-Décolleté-100-pumps.jpg What am I doing wrong and what is the right way to encode this URL?

    Read the article

  • Java mail encoding

    - by Argiropoulos Stavros
    Using the code below i can send an email written in non-english and although the subject appears correctly the body appears as gibberish. Any ideas? Thank you public void postMail(String recipient, String subject, String message, String from) throws MessagingException, UnsupportedEncodingException { //Set the host smtp address Properties props = new Properties(); props.put("mail.smtp.host", "mail.infodim.gr"); // create some properties and get the default Session Session session = Session.getDefaultInstance(props, null); // create a message Message msg = new MimeMessage(session); // set the from and to address InternetAddress addressFrom = new InternetAddress(from); msg.setFrom(addressFrom); InternetAddress addressTo=new InternetAddress(recipient); msg.setRecipient(Message.RecipientType.TO, addressTo); // Setting the Subject and Content Type msg.setSubject(subject); msg.setContent(message, "text/plain"); Transport.send(msg); }

    Read the article

  • UriBuilder incorrectly encoding Query Parameters value ?

    - by Fred
    Lets consider the following code sample where a path and single parameter are encoded... Parameter name: "param" Parameter value: "foo/bar?aaa=bbb&ccc=ddd" (happens to be a url with query parameters) String test = UriBuilder.fromPath("https://dummy.com"). queryParam("param", "foo/bar?aaa=bbb&ccc=ddd"). build().toURL().toString(); The encoded URL string returned is: "https://dummy.com?param=foo/bar?aaa%3Dbbb&ccc%3Dddd" Is this correct ? Should not the character "&" (and may be even "?") be encoded in the parameter value string ? Would not the URL produced be interpreted as follow: One first parameter, name="param", value = "ar?aaa%3Dbbb" followed by a second parameter, name="ccc%3Dddd", without value.

    Read the article

  • $_GET encoding problem with cyrillic text

    - by T1000
    I'm trying this code (on my local web server) <?php echo 'the word is / ?????? ? '.$_GET['word']; ?> but I get corrupted result when enter ?word=????? the word is / ?????? ? ???? The document is saved as 'UTF-8 without BOM' and headers are also UTF-8. I have tried urlencode() and urldecode() but the effect was same. When upload it on web server, works fine...

    Read the article

  • [Cocoa] NSTask string encoding problem

    - by ryyst
    Hi, In my program, I'm grep-ing via NSTask. For some reason, sometimes I would get no results (even though the code was apparently the same as the command run from the CLI which worked just fine), so I checked through my code and found, in Apple's documentation, that when adding arguments to an NSTask object, "the NSTask object converts both path and the strings in arguments to appropriate C-style strings (using fileSystemRepresentation) before passing them to the task via argv[]" (snip). The problem is that I might grep terms like "Río Gallegos". Sadly (as I checked with fileSystemRepresentation), that undergoes the conversion and turns out to be "RiÃÅo Gallegos". How can I solve this? -- Ry

    Read the article

  • Encoding MySQL text fields into UTF-8 text files - problems with special characters

    - by Matt Andrews
    I'm writing a php script to export MySQL database rows into a .txt file formatted for Adobe InDesign's internal markup. Exports work, but when I encounter special characters like é or umlauts, I get weird symbols (eg Chloë Hanslip instead of Chloë Hanslip). Rather than run a search and replace for every possible weird character, I need a better method. I've checked that when the text hits the database, it's saved properly - in the database I see the special characters. My export code basically runs some regular expressions to put in the InDesign code tags, and I'm left with the weird symbols. If I just output the text to the browser (rather than prompt for a text file download), it displays properly. When I save the file I use this code: header("Content-disposition: attachment; filename=test.txt"); header("Content-Type: text/plain; charset=utf-8"); I've tried various combinations of utf8_encode() and iconv() to no avail. Can anybody point me in the right direction here?

    Read the article

  • JPA character encoding

    - by wheelie
    Hi there, I have a Java Web application using GlassFish 3, JSF2.0 (facelets) and JPA (EclipseLink) on MySQL (URL: jdbc:mysql://localhost:3306/administer). The problem I'm facing is that if I'm saving entities to the database with the update() method, String data loses integrity; '?' is shown instead of some characters. The server, pages and database is/are configured to use UTF-8. After I post form data, the next page shows the data correctly. Furthermore it "seems" in debug that the String property of the current entity stores the correct value too. Dunno if NetBeans debug can be trusted; might be that it decodes correctly, however it's incorrect. Any help would be appreciated, thanks in advance! Daniel

    Read the article

  • JDBC character encoding

    - by wheelie
    Hi there, I have a Java Web application using GlassFish 3, JSF2.0 (facelets) and JPA (EclipseLink) on MySQL (URL: jdbc:mysql://localhost:3306/administer). The problem I'm facing is that if I'm saving entities to the database with the update() method, String data loses integrity; '?' is shown instead of some characters. The server, pages and database is/are configured to use UTF-8. After I post form data, the next page shows the data correctly. Furthermore it "seems" in debug that the String property of the current entity stores the correct value too. Dunno if NetBeans debug can be trusted; might be that it decodes correctly, however it's incorrect. Any help would be appreciated, thanks in advance! Daniel

    Read the article

  • Python encoding for pipe.communicate

    - by Brian M. Hunt
    I'm calling pipe.communicate from Python's subprocess module from Python 2.6. I get the following error from this code: from subprocess import Popen pipe = Popen(cwd) pipe.communicate( data ) For an arbitrary cwd, and where data that contains unicode (specifically 0xE9): Exec. exception: 'ascii' codec can't encode character u'\xe9' in position 507: ordinal not in range(128) Traceback (most recent call last): ... stdout, stderr = pipe.communicate( data ) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/subprocess.py", line 671, in communicate return self._communicate(input) File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/subprocess.py", line 1177, in _communicate bytes_written = os.write(self.stdin.fileno(), chunk) This is happening, I presume, because pipe.communicate() is expecting ASCII encoded string, but data is unicode. Is this the problem I'm encountering, and i sthere a way to pass unicode to pipe.communicate()? Thank you for reading! Brian

    Read the article

  • ffmpeg libxvid settings for optimal quality and preferably fast encoding

    - by dropson
    What ffmpeg settings should I use to convert a video into xvid with a mixed speed and quality ratio, using 2-passes, and alternativly 1 pass. Currently I use the following for just 1 pass, but I need a better sugestion. -acodec libmp3lame -ab 128 -ar 44100 -ac 2 -vcodec libxvid -qmin 3 -qmax 5 -mbd 2 -bf 2 -flags +4mv -trellis -aic -cmp 2 -subcmp 2 -g 2 -maxrate 1300 -b 1200 -threads 0

    Read the article

  • How can I deal with this encoding?

    - by Dan
    Hi all, I'm now trying to parse chrome bookmarks, but I encounter a problem. the bookmarks snippet is presented as follow: { "date_added": "12915566290018721", "id": "16", "name": "hao123\uFF0D\uFF0D\u6211\u7684\u4E0A\u7F51\u4E3B\u9875", "type": "url", "url": "http://www.hao123.com/" } the string coding corresponding to name field is stored as "hao123\uFF0D\uFF0D\u6211\u7684\u4E0A\u7F51\u4E3B\u9875", but it should be "hao123--??????" to provide to users. How can I transform "hao123\uFF0D\uFF0D\u6211\u7684\u4E0A\u7F51\u4E3B\u9875" to "hao123--??????"? thanks!

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >