You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 rivejä
1.3 KiB

3 vuotta sitten
  1. using System;
  2. using System.Data;
  3. using System.Configuration;
  4. using System.Web;
  5. using System.Web.Security;
  6. using System.Web.UI;
  7. using System.Web.UI.WebControls;
  8. using System.Web.UI.WebControls.WebParts;
  9. using System.Web.UI.HtmlControls;
  10. namespace basic
  11. {
  12. /// <summary>
  13. /// QZCheck 的摘要说明
  14. /// </summary>
  15. public class QZCheck
  16. {
  17. /// <summary>
  18. /// 检测附件地址
  19. /// </summary>
  20. /// <param name="Fujian"></param>
  21. public static string CheckFujian(string Fujian)
  22. {
  23. string strResult = "";
  24. if (Fujian.ToLower().Contains("http://"))
  25. {
  26. strResult = Fujian;
  27. }
  28. else
  29. {
  30. strResult = "../" + Fujian;
  31. }
  32. return strResult;
  33. }
  34. /// <summary>
  35. /// 检测图片是否为空
  36. /// </summary>
  37. /// <param name="Fujian"></param>
  38. public static string CheckPathNull(string Path)
  39. {
  40. string strResult = "";
  41. if (Path == null || Path == "")
  42. {
  43. strResult = "upload/default.jpg";
  44. }
  45. else
  46. {
  47. strResult = Path;
  48. }
  49. return strResult;
  50. }
  51. }
  52. }