Need to create custom static page as home page

AI-generated summary

Rajeev is seeking a way to create a custom static page for their Discourse site, allowing them to use jQuery to call third-party APIs. They have tried two plugins, procourse-static-pages and discpage with discourse-home-page plugin, but neither fulfilled their requirements.

4ong suggested using the Landing Pages Plugin from https://github.com/paviliondev/discourse-landing-pages.git, which allows adding jQuery. However, Rajeev encountered challenges with this plugin, sharing screenshots of the issues.

4ong offered to help, but initially didn’t have time to investigate the problem, which seemed related to running the plugin on localhost. Later, 4ong and 4ong were able to test the plugin on localhost, finding it worked correctly.

Rajeev asked about 4ong’s localhost setup, wondering if it was run as a Docker image or standalone application. 4ong replied that they use a standalone setup in Ubuntu (WSL2) and suggested trying the Docker way as an alternative.

yhh9xdq7dc later suggested merging the database as a potential solution.

Hi,
I need a way by which I can create a custom static page, use jquery over it for calling third-party API and use it as a home page for my site. I have already used two plugins which are as follows:

  1. procourse-static-pages
  2. discpage with discourse-home-page plugin

But none of above fulfill my requirement. If I use the first one then, I am not able to use any js code or jquery on the page. If I go for the second one then, It creates a category for the static page and further use topic under this created category as static page which is not so reliable. Is there any other way to do this?

Feedback appreciated
Thanks

Hi @Rajeev
You can try Landing Pages Plugin 🛩 - link to code
GitHub - paviliondev/discourse-landing-pages: Adds landing pages to Discourse · GitHub

There is a way to add jquery there

Thanks for feedback @4ong .

I have tried this plugin but getting challenges with it. Please have a look at the screenshots.

Hi @Rajeev
I may be not the best one to help with localhost as I’ve never used this combination.
And don’t have time to check just now. It works well with my production domain on server.

@angus Maybe you know a quick solution in this case? Thank you!

Hi @Rajeev I will be able to check it tomorrow - I’m back to my additional localhost development :slight_smile:

Hi @Rajeev
I’ve tested on localhost and the plugin works correctly

So can you describe more about the problem that you have - maybe we will find a solution together.

@4ong I appreciate that you are concerning about my issue. I want to know how you setup your local host. Are you running it as docker image or standalone application by ruby server ?. Because I am running it as standalone by ember and ruby server.

Thanks

Standalone in Ubuntu (WSL2). You can also try Docker way like described here:

I know it’s late to reply, but did you merge the database? Perhaps this can serve as a solution for others