Jump to content

bayparkm

Members
  • Posts

    18
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by bayparkm

  1. Hello,

     

    I currently administer a hosting account for my church under the Stevie user baypark.

    I would like permission to register a second account for personal use under another username since I intend to

    eventually turn over all website management-related tasks to someone else within my church and don't want someone else able to control my personal website.

     

    Thank you for your time.

     

    - Adam K

    • Like 1
  2. According to this page:

    http://www.heliohost.org/home/features/languages/perl

    You should have the permissions set as 755

     

    Did you save it as a .cgi file or as a .pl file? (Not sure if it matters as long as it's in cgi-bin)

     

    500 error codes mean 'Internal Server Error', it may not be anything wrong with your script.

    Have you tried running it on a different server or computer?

  3. As far as creating the SQLite database on HelioHost, you'll have to write a PHP (or other web-language) script to create the SQLite Database, if cPanel supports creation of SQLite databases I haven't seen it yet. For connecting the the HelioHost MySQL database, you'd need to know your external IP address (not your LAN's internal one for your computer), you'd then have to add it to the list of allowed remote IP's for Remote MySQL in cPanel. I have no idea how you would use Excel to connect to either of these database types, or if it even can for that matter

  4. What I meant when I asked "where are they coming from?" was is there a place in your PHP code that you're defining the variables so that they have values? From looking at the code you posted, they don't seem to be defined anywhere in the code you posted, if they're defined elsewhere I apologize.

    If you want to insert these values from the login table, you need to store them somewhere before you delete them from the table. What to do is run the SELECT query, store the results and then pull the values you need to insert into the banned users table from the stored results.

     

    EDIT:

    I made a gist of the source code you posted with some edits: https://gist.github.com/awkerney/9f6e686978618bdacb8d

    this way you can see what I mean (I hope)

  5. $query = \"DELETE user_name FROM login WHERE custID={$_POST['custid']} LIMIT 1\";
    

     

    Should be

    $query = \"DELETE FROM login WHERE custID={$_POST['custid']} LIMIT 1\";
    

     

    You don't need to specify columns when you're deleting rows from a table

     

    Also in this query

    $query = \"INSERT INTO banned_users (custid, user_name, user_password,  user_type, question, ans, suspend_date)
    VALUES ('$custid', '$user_name', '$pass', '$authtype', '$qns', 'ans',  'suspend_date')\";
    

     

     

    Where are $custid, $user_name, $pass, $authtype, and $qns coming from? It also looks like you missed the '$'s on a few of the variables so the query should look like

    INSERT INTO banned_users(userid, user_name, user_password, user_type, question, ans, suspend_date)
    VALUES( '$custid', '$user_name', '$pass', '$authtype', '$qns', '$ans', '$suspend_date')
    

     

    You should really be using prepared statements though. Even if the data is coming from a "trusted source" they're much safer and prevent SQL-Injection attacks

    • Like 1
  6. Try using the python 2to3 tool to convert it to a Python 3 script

    Or write it natively for Python 3. Could you provide more

    information about what's going wrong? Or possible some example code

    to show what works and what doesn't seem to be working?

×
×
  • Create New...