How can we show all our TPL pages in the widgets in ACP dashboards?

NodeBB Development

Suggested Topics


  • 0 Votes
    5 Posts
    335 Views

    Cracked it! I had all this nonsense in my nginx from googling around. here is what worked.

    location /forum { if ($request_method = 'OPTIONS') { add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Credentials' 'true'; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,X-AUTHENTICATION, X-IP, Accept'; add_header 'Access-Control-Max-Age' 1728000; add_header 'Content-Type' 'text/plain charset=UTF-8'; add_header 'Content-Length' 0; return 204; } if ($request_method = 'POST') { add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Credentials' 'true'; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,X-AUTHENTICATION, X-IP, Accept'; } if ($request_method = 'GET') { add_header 'Access-Control-Allow-Origin' '*'; add_header 'Access-Control-Allow-Credentials' 'true'; add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS'; add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,X-AUTHENTICATION, X-IP, Accept'; } add_header 'Access-Control-Allow-Credentials' 'true'; add_header X-Frame-Options "SAMEORIGIN"; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header Host $http_host; proxy_set_header X-NginX-Proxy true; # proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto; proxy_pass http://127.0.0.1:4567; # no subfolder defined here proxy_set_header Host $host; # MAGIC proxy_redirect off; # Socket.IO Support proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; }
  • 404.tpl

    Moved NodeBB Development
    3
    0 Votes
    3 Posts
    1k Views

    ok, I found out how. you simply create a template with the error name inside your theme. example 404.tpl
    hopefully, this might help someone.

  • 5 Votes
    13 Posts
    2k Views

    But lemmie tell you writing Javascript inside an HTML widget is a Pain In The Neck.

  • 0 Votes
    6 Posts
    2k Views

    I think you're right... in the case of an anonymous function, the function itself would be in memory too.

    Then in that case, it's probably just easier to set up cron in general 😝

  • 0 Votes
    2 Posts
    1k Views

    @Hao-Lee do you mean filtering the posts by poster?