The following warnings occurred:
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.2.25 (Linux)
File Line Function
/global.php(961) : eval()'d code 26 errorHandler->error
/global.php 961 eval
/showthread.php 28 require_once





× This forum is read only. As of July 23, 2019, the UserSpice forums have been closed. To receive support, please join our Discord by clicking here. Thank you!

  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Best practice/ moving files to usersc
#2
I'm actually in the process of writing the best practices for usersc right now. Feel free to create a bug report in userspice.com/bugs to remind me that not all pages work with usersc "out of the box" and I'll go back and fix that. (I'm out of town right now and on public wifi or I would do it myself).

In the mean time, here's what you need to know.

The only two lines of code a userspice public facing file needs to have are the require init.ph and the line about securePage. Other than that, it's all optional. You can completely write your own login.php file.

Ok, so re: init.php if you're in the usersc folder, then init.php is in users, so when you require in init, you need to do '../users/init.php'

This is basically back one folder to root and up one folder to users.

If the page fails to load it's almost always because we didn't follow our own rules and use the us_url_root thing when we were doing an include/require_once somewhere else on that same page. So if we didn't, then you just need to change those requires/includes to go to the right path. I can fix that all in the next update, but if you want it to work now, you'll just have to do the includes.

Regarding error 500. That most likely means that your server has error reporting turned off for PHP which is great when you're in production, but makes knowing what's wrong when you're developing a pain in the butt. I really think most people would be better served by using something like XAMPP to develop on their local machine or at least turning both error reporting to 1 and e_all (there is an example of how to do this in at the top of login.php
  Reply


Messages In This Thread
Best practice/ moving files to usersc - by rjs5327 - 02-23-2018, 01:48 AM
Best practice/ moving files to usersc - by dan - 02-23-2018, 01:59 AM
Best practice/ moving files to usersc - by rjs5327 - 02-23-2018, 02:09 AM

Forum Jump:


Users browsing this thread: 2 Guest(s)