Bitcoin Forum
November 05, 2024, 06:42:32 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: RegEx to match transaction id?  (Read 1454 times)
Tonako (OP)
Newbie
*
Offline Offline

Activity: 26
Merit: 0


View Profile
April 08, 2014, 05:10:50 AM
 #1

Hello all

Please help me make a regular expression for PHP

[a-zA-Z0-9] and 65 characters?

'/^[a-zA-Z0-9]{65}$/' - true ?)))
jeffg
Newbie
*
Offline Offline

Activity: 30
Merit: 0


View Profile WWW
April 08, 2014, 12:47:06 PM
 #2

Hello all

Please help me make a regular expression for PHP

[a-zA-Z0-9] and 65 characters?

'/^[a-zA-Z0-9]{65}$/' - true ?)))

Should be a-f and only 64 chars (32bytes):

Code:
[a-fA-F0-9]{64}
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!