是否有可能改变WP中的分页永久链接?

时间:2018-04-16 09:03:28

标签: wordpress

分页的默认链接看起来像" site.com/articles/page/2",但我需要将页码作为参数(例如:" site.com/articles?页= 2&#34)。我尝试过使用add_filter函数:

Access.ExecQuery("SELECT * FROM Exam;")
        Dim user As String = TxtStudent.Text
        Dim board As String = CmbBoard.Text
        Dim instrument As String = CmbInstrument.Text
        Dim grade As String = CmbGrade.Text
        Dim result As String = CmbResult.Text


        Access.ExecQuery("INSERT INTO Grade (Username, Instrument, Exam Board, Grade, Result) VALUES ('" & user & "', '" & board & "', '" & instrument & ", " & grade & ", " & result & "');")
        If Not String.IsNullOrEmpty(Access.Exception) Then MsgBox(Access.Exception) : Exit Sub

但它没有用。它会返回网址:" site.com/articles0/page/2 /" (此过滤器仅在url的分页部分之前添加零符号。)

1 个答案:

答案 0 :(得分:0)

按照以下网址,您必须根据自己的要求设置baseformathttps://codex.wordpress.org/Function_Reference/paginate_links