Jump to content

Hiro

Members
  • Posts

    12
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Hiro's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Thanks for the reply, but sorry I'm still new to PHP. Could you elaborate on what a cron is? Also, do you have any advice on how to set up the update script in the first place? Automatically updating it isn't the problem, it's the process of setting up the user pages and making them ready to update.
  2. I've set up the actions in a table too, but still don't know where to go from here. Any advice/words of wisdom?
  3. This is a bit long so bear with me please. I've been trying to figure this out on my own but it's pretty much a big mess. I need to code an online text based game, which requires a daily update to the database of users. I've already set up the database and stats, but now I need an update system. I'll need 2 things: A user CP where users can select "actions" for their character, and an admin CP where I can run an "update" script with a push of a button. The control panels are both ready, but now I need the scripts. For this game, each player can select "actions" for their character that will edit their stats daily according to the actions. For example, player 1's stats in the database are as follows: HP: 500/1000 Strength: 100 Speed: 100 Defense: 100 For his 3 actions, he selects "Training", "Learning how to swim (5)" and "Resting". Training will increase each stat by 5% per day, Learning a skill will take 5 days, and he will automatically have the skill added to his profile once it's complete, and Resting will restore his HP by 20% of the maximum value each day. I'm not quite sure how to get started with this. Should I make a table in the database with all possible actions first? If anyone can guide in the right direction, I will appreciate it greatly.
  4. Thanks PFMaBiSmAd, I replaced the parts in the url that were \ with /, but left everything else the same. echo "[<a href=\"php/process.php\">Logout</a>]"; works.
  5. I've been messing around with MySQL and PHP, and installed a login system (http://www.evolt.org/article/PHP_Login_System_with_Admin_Features/17/60384/) for my site. I will need to tweak this code later for my own uses, but for now I'm having problems. I use iframes on my site, and need the login system links to display in my frames. However once I log in, the logout buttons give a 404, and the PHP script won't work with iframes. <? /** * User has already logged in, so display relavent links, including * a link to the admin center if the user is an administrator. */ if($session->logged_in){ echo "<h1>Logged In</h1>"; echo "Welcome <b>$session->username</b>, you are logged in. <br><br>" ."[<a href=\"php\userinfo.php?user=$session->username\">My Account</a>] " ."[<a href=\"php\useredit.php\">Edit Account</a>] "; if($session->isAdmin()){ echo "[<a href=\"php\admin/admin.php\">Admin Center</a>] "; } echo "[<a href=\"php\process.php\">Logout</a>]"; } else{ ?> That's the code for the user CP once you're logged in. I need the links to points to the frame "content", so I tried to add target="content in the logout link like this: echo "[<a href=\"php\process.php\" target="content">Logout</a>]"; but it gave me this error "Parse error: parse error, unexpected T_STRING, expecting ',' or ';' in /home/www/site/index.html on line 96" How can I use iframes with PHP? Also - I logged in with Google Chrome (I usually use firefox), and hovered over the logout link, and the link was "http://musevox.awardspace.biz/php/process.php". In firefox, it reads "http://musevox.awardspace.biz/php\process.php". It will function correctly in Chrome, but will 404 on Firefox.
  6. You're right, I'll head over to PHP help.
  7. Also, I found out another weird thing... I logged in with Google Chrome (I usually use firefox), and hovered over the logout link, and the link was "http://musevox.awardspace.biz/php/process.php". In firefox, it reads "http://musevox.awardspace.biz/php\process.php". It will function correctly in Chrome, but will 404 on Firefox.
  8. Ok thanks haku. I've been messing around with MySQL and PHP, and installed a login system (http://www.evolt.org/article/PHP_Login_System_with_Admin_Features/17/60384/) for my site. I will need to tweak this code later for my own uses, but for now I'm having problems. I use iframes on my site, and need the login system links to display in my frames. However once I log in, the logout buttons give a 404, and the PHP script won't work with iframes. <? /** * User has already logged in, so display relavent links, including * a link to the admin center if the user is an administrator. */ if($session->logged_in){ echo "<h1>Logged In</h1>"; echo "Welcome <b>$session->username</b>, you are logged in. <br><br>" ."[<a href=\"php\userinfo.php?user=$session->username\">My Account</a>] " ."[<a href=\"php\useredit.php\">Edit Account</a>] "; if($session->isAdmin()){ echo "[<a href=\"php\admin/admin.php\">Admin Center</a>] "; } echo "[<a href=\"php\process.php\">Logout</a>]"; } else{ ?> That's the code for the user CP once you're logged in. I need the links to points to the frame "content", so I tried to add target="content in the logout link like this: echo "[<a href=\"php\process.php\" target="content">Logout</a>]"; but it gave me this error "Parse error: parse error, unexpected T_STRING, expecting ',' or ';' in /home/www/site/index.html on line 96" How can I use iframes with PHP?
  9. I'd like to become familiar with using command lines, but like I mentioned my host only allows me to use phpMyAdmin. I also looked up tutorials and learned how to make tables for my db, but where can I learn how to extract information from my databases? I'd like to show my tables on my website, but don't know how.
  10. Actually yeah, I meant phpMyAdmin. MySQL Manager is just a quick link to an overview of your databases, but it actually makes you log into phpMyAdmin to edit. I guess I should just look up phpMyAdmin tutorials. I would like to know, however, if free hosting sites offer remote mySQL management. And if so, would it be easier for a beginner to use a program like HeidiSQL over phpMyAdmin?
  11. First off, I'd like to apologize if this is in the wrong section. I'm trying to get into MySQL and have recently registered with Awardspace, and began looking for tutorials as soon as I got my account. I was confused to find that all of the tutorials I've found on the net use a different format than the one provided with my host. Awardspace uses MySQL Manager with phpMyAdmin, and apparently does not support remote MySQL management. I was wondering if this is a feature solely offered to paid web hosts, or if there are tutorials on using MySQL Manager. I've tried to figure it out on my own but can't seem to find the material. Thank you in advance.
×
×
  • 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.