Custom permalinks

AI-generated summary

The discussion is about custom permalinks in Discourse. hnaseri is seeking an explanation of the permalink tab in the admin panel, which techAPJ clarifies by linking to relevant meta threads.

hnaseri wants to create permalinks programmatically using PHP to support a custom URL structure (course/chapter/lesson/topic-1) for a Q&A platform integrated with an educational app. fefrei suggests using the Discourse API, and neil provides an example of creating a permalink using Permalink.create(url: '/discussion/12345', topic_id: 987).

riking recommends developing FAQ material on this topic as part of a feature interest survey on “go” permalinks.

There is a permalink tab under customize section in admin panel. I don’t know what does it exactly do. Can someone please explain it to me with a picture from that area? Because I have my discourse in Persian, and Persian translation of different fields in this section doesn’t make sense to me.

See:

and

thanks.
How can I programmatically create these permalinks? php code is preferred for me. is it possible?

I want to use discourse as a q&a platform in my educational app. My app has a structure like this:
course/chapter/lesson
So I want the users to be able to create new topics like this:
course/chapter/lesson/topic-1
course/chapter/lesson/topic-2
etc…
since this structure isn’t supported by discourse, I want to use this customized permalinks as a redirection tool to created topics. Is it a good idea?

You can use the API to create these. Create a permalink while the Network tab of your browser’s development tools is open to see how it works. You can find more details here:

There’s a post in the linked topic with an example:

https://meta.discourse.org/t/redirecting-old-forum-urls-to-new-discourse-urls/20930/16?u=neil

Permalink.create(url: '/discussion/12345', topic_id: 987)

#faq-material 이 부분은 Feature interest survey: "go" permalinks 의 일부로 개발되어야 합니다