Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

PHP 

unicode int values

Hello, I was wondering if anyone could tell me an easy way to get the int value of a unicode char?

I really would like to be able to do this to allow my DARTIS library to be able to transmit data between java/php/autoit.

Thanks in advance!
Call the mb_ord() function on a character but you have to be using PHP7.2 or above.

PHP Code

<?php 
echo mb_ord('a'); 
any solutions for php 5.6?


Try this out, I found this from the PHP manual
(Mar 28, 2018 12:25 AM)m0noxide Wrote:  

Try this out, I found this from the PHP manual
Thanks man, however,
how would I convert it back into it's char from the unicode value? Need to be able to reverse this in order to know if it works properly.


I got it working after a couple of edits, the code you posted seems a little broken, but I got it working, though I'm not 100% sure if I'm using it right.


After some testing, any non ascii chr always gets returned as an @ sign, not 100% how to use this, or how to revert it.


You can see my code here: https://github.com/pdglobal/DARTIS-PHP/b.../crypt.php


Found a solution https://stackoverflow.com/questions/4953...at0-in-php


Possibly Related Threads...
Thread / Author Replies Views Last Post
by newQueryJul 15, 2023 09:43 AM 8 199 Jul 15, 2023 09:43 AM
Last Post: newQuery
[PHP] by faxxgridApr 30, 2020 11:45 AM 15 362 Apr 30, 2020 11:45 AM
Last Post: faxxgrid
[PHP] by EffexionJan 25, 2019 06:16 AM 2 166 Jan 25, 2019 06:16 AM
Last Post: Effexion