ASP Classic blog framework - BrainOrdure
Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

112 wiersze
3.6KB

  1. <%
  2. ' Auto-generated Controller: Posts
  3. ' Generated on 5/2/2026 9:47:38 PM
  4. ' Generator: generateController.vbs v1.0
  5. '
  6. ' Remember to:
  7. ' 1. Add to app/controllers/autoload_controllers.asp
  8. ' 2. Register in core/lib.ControllerRegistry.asp
  9. ' 3. Add routes in public/Default.asp
  10. Class PostsController_Class
  11. Private m_useLayout
  12. Private m_title
  13. Private Sub Class_Initialize()
  14. m_useLayout = True
  15. m_title = "Posts"
  16. End Sub
  17. Public Property Get useLayout
  18. useLayout = m_useLayout
  19. End Property
  20. Public Property Let useLayout(v)
  21. m_useLayout = v
  22. End Property
  23. Public Property Get Title
  24. Title = m_title
  25. End Property
  26. Public Property Let Title(v)
  27. m_title = v
  28. End Property
  29. '---------------------------------------------------------------
  30. ' Action: Index
  31. '---------------------------------------------------------------
  32. Public Sub Index()
  33. ' TODO: Implement Index action
  34. Response.Write "Index action called"
  35. End Sub
  36. '---------------------------------------------------------------
  37. ' Action: Show
  38. '---------------------------------------------------------------
  39. Public Sub Show(slug)
  40. ' TODO: Implement Show action
  41. Response.Write "<strong>Show called</strong><br>"
  42. Response.Write "Parameters:<br>"
  43. Response.Write "slug = " & Server.HTMLEncode(CStr(slug)) & "<br>"
  44. End Sub
  45. '---------------------------------------------------------------
  46. ' Action: New
  47. '---------------------------------------------------------------
  48. Public Sub NewForm()
  49. ' TODO: Implement NewForm action
  50. Response.Write "NewForm action called"
  51. End Sub
  52. '---------------------------------------------------------------
  53. ' Action: Create
  54. '---------------------------------------------------------------
  55. Public Sub Create()
  56. ' TODO: Implement Create action
  57. Response.Write "Create action called"
  58. End Sub
  59. '---------------------------------------------------------------
  60. ' Action: Edit
  61. '---------------------------------------------------------------
  62. Public Sub Edit(id)
  63. ' TODO: Implement Edit action
  64. Response.Write "<strong>Edit called</strong><br>"
  65. Response.Write "Parameters:<br>"
  66. Response.Write "id = " & Server.HTMLEncode(CStr(id)) & "<br>"
  67. End Sub
  68. '---------------------------------------------------------------
  69. ' Action: Update
  70. '---------------------------------------------------------------
  71. Public Sub Update(id)
  72. ' TODO: Implement Update action
  73. Response.Write "<strong>Update called</strong><br>"
  74. Response.Write "Parameters:<br>"
  75. Response.Write "id = " & Server.HTMLEncode(CStr(id)) & "<br>"
  76. End Sub
  77. '---------------------------------------------------------------
  78. ' Action: Delete
  79. '---------------------------------------------------------------
  80. Public Sub Delete(id)
  81. ' TODO: Implement Delete action
  82. Response.Write "<strong>Delete called</strong><br>"
  83. Response.Write "Parameters:<br>"
  84. Response.Write "id = " & Server.HTMLEncode(CStr(id)) & "<br>"
  85. End Sub
  86. End Class
  87. ' Singleton instance
  88. Dim PostsController_Class__Singleton
  89. Function PostsController()
  90. If IsEmpty(PostsController_Class__Singleton) Then
  91. Set PostsController_Class__Singleton = New PostsController_Class
  92. End If
  93. Set PostsController = PostsController_Class__Singleton
  94. End Function
  95. %>

Powered by TurnKey Linux.