Upload to server

uploading
This commit is contained in:
2025-08-02 05:20:17 +07:00
commit a5eccbd452
984 changed files with 3031800 additions and 0 deletions

View File

@@ -0,0 +1,44 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Security.Cryptography;
namespace Omega
{
internal static class common
{
public static DateTime testdate { get; set; }
public static DateTime visitdate { get; set; }
public static DateTime MaxDate(DateTime a, DateTime b)
{
return a > b ? a : b;
}
public static DateTime MinDate(DateTime a, DateTime b)
{
return a > b ? b : a;
}
public static string MD5Hash(string text)
{
MD5 md5 = new MD5CryptoServiceProvider();
//compute hash from the bytes of text
md5.ComputeHash(ASCIIEncoding.ASCII.GetBytes(text));
//get hash result after compute it
byte[] result = md5.Hash;
StringBuilder strBuilder = new StringBuilder();
for (int i = 0; i < result.Length; i++)
{
//change it into 2 hexadecimal digits
//for each byte
strBuilder.Append(result[i].ToString("x2"));
}
return strBuilder.ToString();
}
}
}