Jump to content

trq

Staff Alumni
  • Posts

    30,999
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by trq

  1. Plenty of jQuery color pickers around.
  2. Lets step back a bit. Why are you creating new pages for each user in the first place? PHP is generally used to make dynamic websites which keep there data within a database, you could use this 'dynamic' technique to serv all your user profiles from a single profile page. Do you think that every time you post a new topic on this board a new page is created?
  3. This topic has been moved to Third Party PHP Scripts. http://www.phpfreaks.com/forums/index.php?topic=315539.0
  4. Just for fun, I've translated your asp (which isn't particularly well written) to (decent) php. this should make things very simple for you. <?php if ($_SERVER['REQUEST_METHOD'] == 'POST') { include 'include/myConn.asp'; if (mysql_connect('hostname','username','password') { mysql_select_db('databasename'); } else { trigger_error(mysql_error()); } $id = mysql_real_escape_string($_POST['id']); $myTitle = mysql_real_escape_string($_POST['myTitle']); $myDesc = mysql_real_escape_string($_POST['myDesc']); $myHeader = mysql_real_escape_string($_POST['myHeader']); $mySubHeader = mysql_real_escape_string($_POST['mySubHeader']); $myPageData = mysql_real_escape_string($_POST['myPageData']); $sql = " UPDATE myAbout SET myTitle = '$myTitle', myDesc = '$myDesc', myHeader = '$myHeader', mySubHeader = '$mySubHeader', myPageData = '$myPageData' WHERE id = $id "; if (mysql_query($sql) && mysql_affected_rows()) { header('Location: update-success.php'); } else { header('Location: update-failed.php'); } }
  5. As with asp, php can connect to many different databases. The most popular is MySql though.
  6. There's a good free book in my signature (Hudzilla), take a look at that. It has chapters on handling forms and using databases. I originally came from classic asp (about 6 years ago) and really, the switch should be pretty straight forward.
  7. Title needs quotes around it... echo "<td><a href='Javascript:checkDelete(" . $row['mID'] . ",'" . $row['Title'] . "')'>";
  8. See http://www.phpfreaks.com/forums/faqcode-snippet-repository/multi-column-results/
  9. It's pretty difficult to tell exactly how you want this array formatted, but heres my best guess. while ($hunches = mysql_fetch_array($gethunches)) { $days1[] = array( $hunches['day'] => array( NULL,NULL,'<span class="red">' . $hunches['firstname'] . " " . $hunches['lastname'] . "-" . $hunches['dob'] . "--" . $hunches['sex'] . '</span>' ) ); }
  10. Set error reporting as shown and post any error you get.
  11. I would agree. Sqlite is an awesome little database.
  12. That code is after the code I was talking about. Doesn't look like it would effect the process anyway. To the OP... have you got error reporting enabled? I'm starting to think you may actually be getting a header error, hence its not working. Make sure to always have.... <?php error_reporting(E_ALL) ; ini_set('display_errors', 1) ; ?> while developing.
  13. My code will do the same thing.
  14. Your post still makes little sense. You do not pass session values through the url. To the op. This part.... if($messages){ doIndex(); // note we have to explicity 'exit' from the script, otherwise // the lines below will be processed: exit; } $messages is not defined anywhere in the script.
  15. That is indeed the only way to create a link. Where exactly do you want the link to go? Your question isn't at all clear.
  16. This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=315463.0
  17. You will need to setup a cron job via your server's OS or a scheduled event through MySql. Nothing at all to do with PHP.
  18. You keep saving data to the same array index over and over.
  19. This topic has been moved to HTML Help. http://www.phpfreaks.com/forums/index.php?topic=315457.0
  20. That would be as simple as..... $album = $_GET['album'];
  21. This topic has been moved to Installation in Windows. http://www.phpfreaks.com/forums/index.php?topic=315445.0
×
×
  • 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.