Questions tagged [chars]

a datatype that can hold a character of the implementation’s character set.

210 questions
3
votes
0 answers

Sending an email from Delphi using Indy changes Danish chars

I have made a form that I use to send a mail using Indy. The form can be used to attach files as well. All this is working very fine when I use the sample in the link below and when I use it in a utility I have made for sending invoices made as PDF…
OZ8HP
  • 1,337
  • 4
  • 28
  • 56
3
votes
2 answers

HTML → / ← not displayed on some systems

I'm making heavy use of → / ← arrow symbols in HTML so that i spare myself the pain of having to go with images. This is for an enclosed system, not for a public website. Now i noticed that my client does not have those symbols in their charsets…
SquareCat
  • 5,318
  • 5
  • 33
  • 74
3
votes
3 answers

php true multi-byte string shuffle function?

I have a unique problem with multibyte character strings and need to be able to shuffle, with some fair degree of randomness, a long UTF-8 encoded multibyte string in PHP without dropping or losing or repeating any of the characters. In the PHP…
Dave
  • 117
  • 5
3
votes
3 answers

Convert array of int to array of chars - Python

I am trying to convert a set literal of integers into that of chars. For example, if the array {0,1} is given as an input, I would like to firstly check if the individual elements are chars and if not convert them into chars so that I get {'0',…
Seb
  • 481
  • 1
  • 6
  • 18
3
votes
1 answer

Incrementing chars in for loop works, decrementing does not?

So I was doing some exercises and ran across this code (which produces "1. Item A", "2. Item B", etc ): echo "\n
    "; for ($x='A'; $x<'G'; $x++){ echo "
  1. Item $x
  2. \n"; } echo "\n
"; Curious, I attempted to do the reverse (which…
Tim Spencer
  • 131
  • 7
3
votes
2 answers

C++: Chr() and unichr() equivalent?

I could have sworn I used a chr() function 40 minutes ago but can't find the file. I know it can go up to 256 so I use this: std::string chars = ""; chars += (char) 42; //etc So that's alright, but I really want to access unicode characters. Can I…
alex
  • 31
  • 2
3
votes
1 answer

Lua Removing first couple characters without add a space

I'm new to Lua and I'm sure this is a silly problem. I was trying to remove first 3 characters from a string with string.gsub Here is the code: string.gsub(m, "/jk", "", 1) Now "/jk" are the first 3 chars the string, now, string.gsub adds a space…
nuberelo
  • 47
  • 1
  • 5
3
votes
4 answers

PHP urlencode converting HTML special characters

Ive done a good deal of searching and so far can't find this already answered (though I might not be asking properly). I have a simple title string on a page thats stored into a php variable $title When I print_r it I get back a happy, normal,…
Tey
  • 51
  • 1
  • 1
  • 8
2
votes
7 answers

C langugage - "Weird" characters in char[] output

I had to build a C program which convert's infix notation into postfix notation using STACK. That went well and it's working in some way. It was long ago when I used last time C language so I'm probably dont use char[] variables very well. So…
rjovic
  • 1,167
  • 2
  • 15
  • 34
2
votes
1 answer

phpQuery making  of   and others

When I have a file that I run through phpQuery that has stuff like   or © in it somehow a  is added. so when I have this file (hello.html): hello, this is a test © and I run this code: $f = phpQuery::newDocumentFile( 'hello.html'…
patrick
  • 10,664
  • 7
  • 58
  • 75
2
votes
3 answers

Problem with string - lenght is not correct - some chars included not displayed

I wanted to upgrade the Magento Ogone module to match the new SHASign calculation. It's working fine now but there is a problem ... I have an issue with some strings returned by a Magento method : Mage::getUrl('ogone/api/accept'); It returns me a…
antoineg
  • 98
  • 6
2
votes
2 answers

Test if two first chars typed in are alphanumeric - no regex

I have following code that needs something smart to deal with typed in chars and detection: private final MultiWordSuggestOracle mySuggestions = new MultiWordSuggestOracle(); private final Set mySuggestionsData = new…
MatBanik
  • 24,206
  • 38
  • 107
  • 172
2
votes
1 answer

Send chars with UDP

I'm trying to send text with UDP, by sending every character separately, but something seems to be wrong. This is the client: while(strcmp(sir,"0")!=0) { printf("Text number %d:", i); i++; scanf("%s",sir); printf("\n"); …
Vidi
  • 183
  • 1
  • 1
  • 9
2
votes
2 answers

Two dimensional char array from string using Stream

I am about to create the two dimensional array from string: char[][] chars; String alphabet = "abcdefghijklmnopqrstuvwxyz"; So the array will ilustrate this matrix: But how can I do that using Java 8 Streams, cause I do not want to do this by…
masterofdisaster
  • 785
  • 1
  • 8
  • 21
2
votes
2 answers

How can I get the equivalent non-utf8 chars from a utf8 string?

ruby 1.8.6, rails 2.3.8 Im doing some evals to write some methods to a class, and its working out nice(first time playing w/ metaprogramming :p), except that some strings that need to go into the methods(as code, and not strings) have accented…
Breno Salgado
  • 1,832
  • 1
  • 20
  • 26
1
2
3
13 14