Jump to content

MadTechie

Staff Alumni
  • Posts

    9,409
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by MadTechie

  1. remove one of the functions <?php class Mailer { function sendNewPass($user, $email, $pass){ $from = "From: ".EMAIL_FROM_NAME." <".EMAIL_FROM_ADDR.">"; $subject = "Jpmaster77's Site - Your new password"; $body = $user.",\n\n" ."We've generated a new password for you at your " ."request, you can use this new password with your " ."username to log in to Jpmaster77's Site.\n\n" ."Username: ".$user."\n" ."New Password: ".$pass."\n\n" ."It is recommended that you change your password " ."to something that is easier to remember, which " ."can be done by going to the My Account page " ."after signing in.\n\n" ."- Jpmaster77's Site"; return mail($email,$subject,$body,$from); } } /* Initialize mailer object */ $mailer = new Mailer; ?>
  2. well spotted updated <?php $english_format_number = number_format($number); $number1 = $row_rsProd['P_Retail_Price']; if (isset($_SESSION['MM_Username'])) { $number2 = $row_rsUser['Percent']; }else{ $number2 = 1; } echo number_format ($number1 / $number2 * 100); ?>
  3. outputting to the page.. ie <head> <body> or even <?php echo "Hello"; ?> please read the headers pinned post
  4. you can try.. it "Should" work but i have has limited success with it.. not many options i can think of.. if anyone has idea's i would like to hear them as well
  5. becuase when i remove }; i get unexpected $end so i thought i need to add ; to solve this NO, add the last } <?php /* Initialize mailer object */ $mailer = new Mailer; } //<---HERE ?> also by closeing the sendNewPass function with a } Cannot redeclare sendnewpass() because you have that function twice...
  6. So this <?php $english_format_number = number_format($number); $number1 = $row_rsProd['P_Retail_Price']; if (isset($_SESSION['MM_Username'])) { $number2 = $row_rsUser['Percent']; }else{ $number2 = 0; } echo number_format ($number1 / $number2 * 100); ?>
  7. also close the sendNewPass function with a }
  8. if you have access to the php.ini file then yes session.gc_maxlifetime = 3600 you can try <?php ini_set ( string "session.gc_maxlifetime", 3600) ?> EDIT: as a note it maybe an idea to set the session everyt time its check thus resetting the timeout
  9. I think i said the same thing in the last thread
  10. How are you trying to return back (go back a directory) ? code always helps us
  11. Chat room,
  12. Kinda hit solved to soon got another responce How are they "a thing of the past" ? anyone i understand the abuse part..
  13. create a language file simple array $thewords = array( "UK" => array("colour" => "colour"), "USA" => array("colour" => "color"), ) then use a preg_replace on the output thats only one option
  14. not 100% correct you need to have session_start(); before any output to allow you to read or write to $_SESSION's so if your page as $_SESSION in it then you need to have session_start(); before any output
  15. the code supplied doesn't help.. can't you refer to the manual!
  16. Yeah i know.... my main plan is to move servers but i am a little upset that i'm now being ignore'd. if he allowed me to transfered the domains i'll be happy but i am getting nothing!!
  17. no Add to the top of all pages you DO NOT what a user to go directly to..
  18. please search before you post see post here
  19. your welcome Please click solved
  20. At the top of movie_add_sql.php add <?php echo "POST:<br>"; print_r($_POST); echo "FILE:<br>"; print_r($_FILE); die; ?> whats displayed please post in code tags
  21. try <?php $ip = trim($ip); if ($thisIP == $ip) ?> as your IP's have spaces at the end
  22. Movie Upload: Check your if tangle Movie Image To be Uploaded: CHECK $_FILE Movie Image location: and screenshot OK Movie to be uploaded: CHECK $_FILE Movie Alt: and a description OK Movie Title: Its a title OK Movie ID: = FAILED due to the name in the form being movid_id Try print_r($_FILE) whats return'd
  23. erm mysql_fetch_array if you want all records then your need to use a loop <?php mysql_connect("localhost", "mysql_user", "mysql_password") or die("Could not connect: " . mysql_error()); mysql_select_db("mydb"); $result = mysql_query("SELECT id, name FROM mytable"); while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) { printf("ID: %s Name: %s", $row["id"], $row["name"]); } mysql_free_result($result); ?>
  24. OK i am basically looking for the USA version of Trading Standards.. i had a google and found a site but it didn't seam to match what i needed. Basically i an getting ignored on my last response... for the store you can read the post here CronTabs
×
×
  • 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.