Jump to content

westman

Members
  • Posts

    600
  • Joined

  • Last visited

Everything posted by westman

  1. hi all, I am trying to get a file to run from one of my sites and send the info to my other site. this is my code... mysite1.com <?phpinclude "../connect_to_mysql.php";$sql = mysql_query("SELECT * FROM pics WHERE size= 4 AND pictime != '0' ORDER BY RAND() LIMIT 1" );while($row = mysql_fetch_array($sql)){$picname = $row["id"];}$new_pic = "../images/$picname.gif";?><?phpecho "$new_pic" ?> mysite2.com <?php$show_pic = file_get_contents('http://mysite1.com/all/rand.php');?><?phpecho "$show_pic" ?> at you can see it is not working and I don't know why. any help?
  2. I have, please see earlier posts.
  3. I have no errors. the page just loads like I have no internet connection.
  4. .htaccess is empty phpinfo(); i posted PHP5.ini looks like this... register_globals = off allow_url_fopen = off expose_php = Off max_input_time = 60 variables_order = "EGPCS" extension_dir = ./ upload_tmp_dir = /tmp precision = 12 SMTP = relay-hosting.secureserver.net url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=,fieldset=" memory_limit = 221M post_max_size = 220M file_uploads = On upload_max_filesize = 220M max_execution_time = 7200 max_input_time = 7200 session.gc_maxlifetime = 10800
  5. Hello everyone, I hate to reopen this but in the last few days I have noticed that my upload is not working and it's also very slow before failing after 2-3 minutes. I have not change my code but i have changed phpinfo.php In my phpinfo.php I now have... max_execution_time 7200 max_file_uploads 20 max_input_nesting_level 64 max_input_time 7200 memory_limit 221M post_max_size 220M upload_max_filesize 220M any help?
  6. westman

    session

    in my /phpinfo.php file i now have... session.gc_maxlifetime 10800 10800 does this mean everything is ok and working?
  7. westman

    session

    ok, in my php5.ini i have... session.gc_maxlifetime = 10800 # 3 hours but in my /phpinfo.php file i have... session.gc_maxlifetime 1440 1440 it's not working
  8. westman

    session

    i have... <?php phpinfo(); in my phpinfo file and all i see in the browser is... <?php phpinfo(); I looked up, what to input in my php5.ini fill and got now where. any help?
  9. westman

    session

    ok ppl i put... ini_set('session.gc_maxlifetime', 10800); # 3 hours in my php5.ini file how do i check if everything is working?
  10. westman

    session

    i have been googleing "gc-maxlifetime", "session time" and "php.ini" and i can't seem to get any where. my aim is to set my sessions to timeout after 4 hours of not been active. i have php5.ini on my server and can't seem to open it on my browser. what do i need to do 1st?
  11. westman

    session

    thank you so much, i am now using... $_SESSION['id'] = $id; and I am not using... session_register("id");$_SESSION['id'] = $id; how long till me session times out?
  12. westman

    session

    My server is running PHP 5.2 if session_register("id"); has been removed from PHP what can i use in its place?
  13. westman

    session

    Hi all, I think I have a session problem. When my site is not busy, I can stay logged in for days.But when my site is busy I get logged out within an hour. My server is running PHP 5.2 Here is my start session code... session_register("id");$_SESSION['id'] = $id;session_register('idt');$_SESSION['idt'] = base64_encode("j4p3q9w8s5rq5g3hs34$id");session_register('username');$_SESSION['username'] = $username;session_register('userpass');$_SESSION['userpass'] = $userpass;session_register('useremail');$_SESSION['useremail'] = $useremail; Here is my check session code... session_start();if (!isset($_SESSION['id'])) { header("location:../index.php");exit(); }if (!isset($_SESSION['username'])) { header("location:../index.php");exit(); }if (!isset($_SESSION['userpass'])) { header("location:../index.php");exit(); }if (!isset($_SESSION['useremail'])) { header("location:../index.php");exit(); }if (!isset($_SESSION['idt'])) { header("location:../index.php");exit(); }if (isset($_SESSION['idt'])) {$id = $_SESSION['id'];$idt = $_SESSION['idt'];$username = $_SESSION['username'];$userpass = $_SESSION['userpass'];$useremail = $_SESSION['useremail'];$decryptedID = base64_decode($_SESSION['idt']);$id_array = explode("j4p3q9w8s5rq5g3hs34", $decryptedID);$trueid = $id_array[1];if ($trueid != $id){header("location:../index.php");exit(); }else{$logincheck = "1";}$trueid = mysql_real_escape_string($trueid);$iduserpass = mysql_real_escape_string($iduserpass);$id = mysql_real_escape_string($id);$sql2 = mysql_query("SELECT * FROM mem WHERE id='$trueid' AND password='$userpass' LIMIT 1");$numRows = mysql_num_rows($sql2);if ($numRows = 1) {$logincheck = "1";}else{header("location:../index.php"); exit(); }while($row = mysql_fetch_array($sql2)){ $usernameck = $row["username"];$useremailck = $row["email"];if ($usernameck != $username){header("location:../index.php");exit(); } if ($useremailck != $useremail){header("location:../index.php");exit(); } }} any help?
  14. westman

    time

    thank you again
  15. westman

    time

    Ingolme, thank you so much for explaining each line, it's so helpful and has saved a lot of time. one last question... if $time1 = time() - (60*60*$time_to_subtract); works for 1 hour can i use $time1 = time() - (60*60*24*$time_to_subtract); to last for 1 or 2 days?
  16. westman

    time

    i have to wait over an hour to get the result and sometimes longer
  17. westman

    time

    ok my new code is... $time_in_DB = strtotime($row['date']);$time_to_subtract = '1';$time1 = date("Y-m-d",time() - (60*60*$time_to_subtract));if ($time1 > $time_in_DB){$update = 'Hello world';} will this work?
  18. westman

    time

    thank you for the linkbut it was not that helpfulcould you give a code example of my problem?
  19. westman

    time

    hi all, I am trying to subtract one time from another. here is what i have.... In my DB i have datetime (2013-07-19 16:36:18) $time_to_subtract = '1';$time1 = date("Y-m-d",time() - (60*60*$time_to_subtract));if ($time1 > $time_in_DB){$update = 'Hello world';} here i am trying to take 1 hour away from the time in my DB.I have tried testing my script but i have to wait over 24 hours to see the outcome. any help?
  20. westman

    innerHTML

    it was line break. thank you.
  21. westman

    innerHTML

    i can not fine the problem. i am outputting from php while loop... $list_body .= '<div class="boxHeader" align="left"> <a href="#" title="News" onclick="return false" onmousedown="javascript:toggleNewsContainers('view_news'); javascript:itemname('' . $news_title_3 . ''); javascript:iteminfo('' . $news_info_3 . '');">' . $news_title_3 . '</a></div><br />';} it can output sentences fine but paragraphs is a problem.
  22. westman

    innerHTML

    hi all, I am using ... function iteminfo(theinfo) {var infoitem1 = theinfo;outinfoitem = document.getElementById("info_of_news");outinfoitem.innerHTML = infoitem1;} to pass a string (readable text for users) but the string i am passing has a character limit. how do i up the limit so i can send a paragraph of text instead of a sentence?
  23. westman

    mass email

    could i get some more info on PEAR or an example? I have PEAR installed.
×
×
  • Create New...