Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation since 06/18/2021 in all areas

  1. because you haven't specified a length of 1 (one) - https://www.php.net/manual/en/function.substr.php
    1 point
  2. Don't use the version from FlatPak: it's unofficial and apparently buggy. Install VS Code from an official source.
    1 point
  3. Here's my attempt DATA mysql> select * from ajoo -> order by user, recno; +-------+----------+---------+---------+ | recno | user | v_score | rollavg | +-------+----------+---------+---------+ | 6 | mina1111 | 4 | 3.2500 | | 7 | mina1111 | 3 | 3.2000 | | 8 | mina1111 | 2 | 3.2000 | | 9 | mina1111 | 4 | 3.4000 | | 10 | mina1111 | 5 | 3.6000 | | 11 | mina1111 | 0 | 2.8000 | | 12 | mina1111 | 1 | 2.5000 | | 13 | mina1111 | 1 | 1.7500 | | 14 | mina1111 | 1 | 0.7500 | | 1 | nina1
    1 point
  4. Editor is a bit buggy with multiple toolbar rows, but I think I got it.
    1 point
  5. Over the lifetime of this (or any other) Application, you will spend far more time reading its code than you will writing any of it so go for whichever form expresses your intention most clearly. Personally, I'd go with the former or, perhaps, an even more concise one: if ( ! isset( $_SESSION['user'] ) ) exit ; if ( 'SiteOwner' !== $_SESSION['user'] ) exit ; I'm not sure of the context in which this runs - perhaps a redirect to another page might be more appropriate than the "exit"? YMMV. Regards, Phill W.
    1 point
  6. if(!isset($_SESSION['user']) || $_SESSION['user'] !== 'SiteOwner') { exit; }
    1 point
  7. <a href="\"index.php?id=".<?php echo $data['id']; ?>."\">"
    1 point
  8. Excellent! If anyone asks, you're now applying the Principle of Least Privilege, getting your application work with the minimum level of permissions - just what it needs and nothing more. Also, you are now qualified to laugh openly at anyone that runs their entire Application as root. 😉 Regards, Phill W.
    1 point
  9. Before you can use $_SESSION you must call "session_start()". Put it at the start of the code.
    1 point
This leaderboard is set to New York/GMT-04:00
  • Newsletter

    Want to keep up to date with all our latest news and information?
    Sign Up
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.