Search the Community
Showing results for tags 'unicode'.
-
So i'm not still really familiar with regex and how does it work, but i have issue with my code. I have ¤ in my text and it gets replace with unicode ? block. https://en.wikipedia.org/wiki/Specials_(Unicode_block) for me and I don't get why. Here is the code I'm using. <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <style> #kool { width:800px; border:groove; margin:0 auto; padding:25px; } </style> </head> <body> <?php /* Test preg_replace function */ $preg_pattern = "/[^A-Za-z0-9!\"#%£&()=@\s]/"; if (isset($_GET['preg'])) { echo "<div id='kool'>"; echo "<b>Original string: </b> " . $_GET['preg']; echo "<hr>"; echo "<b>Preg pattern: </b> " . $preg_pattern; echo "<hr>"; echo "<b>Result: </b> " . preg_replace($preg_pattern,"",$_GET['preg']); echo "</div>"; } ?> <form method="get" action="preg_test.php"> <input type="text" name="preg" <?php if (isset($_GET['preg'])) { echo " value='" . $_GET['preg'] . "'"; } ?>> <input type="submit"> </form> </body> </html> And here is the string I'm trying to use. Test 0-9, Specialcharacters: !"#¤%&/()=? Result image below Any guides / help appreciated.
- 14 replies
-
- preg_replace
- php
-
(and 2 more)
Tagged with:
-
QUESTION: Is the following an accurate statement? If not, please clarify how a unicode string literal differs from say, an ASCII string literal. Roddy Untitled-1.html
-
why url can only be sent over the internet using the ascii character-set but not use unicode???
-
why url can only be sent over the internet using the ascii character-set but not use unicode???
- 1 reply
-
- charset
- character set
-
(and 2 more)
Tagged with:
-
When I read from my MS Access database(unicode), the Cyrillic characters are not being written correctly in browser(utf-8). How to encode the data by VBScript in real time or how to convert it manually in MS Access? This is what I've found on this topic, but it seems to be quite complicated: http://stackoverflow.com/questions/22054934/capture-and-insert-unicode-text-cyrillic-into-ms-access-database/22072399#22072399
-
Hello, I have a collection of html pages in hindi texts and now I want to convert those into Unicode font as per the demand. So can any one tell me the perfect javascript code that can do this task at the time of page load (without any click event). Thanks
- 1 reply
-
- javascript
- html
-
(and 2 more)
Tagged with:
-
i have read that when i want to store unicode characters then we have to use nvarchar as datatype and if we are storing regular type of characters then we can use varchar as datatype. i heard that collation is related with unicode characters but not knowing what is mean by collation? and how it is related with unicode characters ? when i have done sp_help tablename one of the column displays collation ----------- SQL_Latin1_General_CP1_CI_AS so please tell me this means what ?