Jump to content

Adrianphp

New Members
  • Posts

    6
  • Joined

  • Last visited

    Never

Posts posted by Adrianphp

  1. Hi, I have a file that is read, then modified, then the stream is opened to be written to and written to. When multiple users are accessing this file, sometimes it disregards the others edit and messes up the file. How can this be fixed?

     

    Maybe you should consider a small database like SQLite to work with. This should be okey and it could solve all your problems.

  2. try

     

    $total_pages = $post_count/10;
    for($i = 1; $i <= $total_pages; $i++){ 
        if($_GET['page'] == $i){ 
            echo $i.' '; 
            } else { 
                echo '<a href="' . $_SERVER['PHP_SELF'] . '?page='.$i.'">'.$i.'</a> '; 
        } 
    } 
    

     

    not sure if it works... i wrote it in a hurry but it should be okey

  3. Probably a ridiculous question...but I've got a php script running on a web email form which checks the captcha entry entered by the user is correct. The form handling script i've been using is actually an ASP file, therefore the form action directs to the ASP file. Is there any way I can call the PHP script to validate the captcha entry before directing to the ASP file? I'm doubtful this is possible, but would be grateful for any feedback before I go off looking for an ASP captcha script. Many thanks.

     

    the captcha PHP script that generates the picture should store the value of the validation code in a cookie, then the ASP script should check for the cookie and compare it with the value of the verification field.

     

    hope this helps???

     

  4. When I run the upload function, says that I am using an invalid argument for the foreach command.

    " Invalid argument supplied for foreach() "

     

    yes, because $_POST['news_id'] is not an array... you only select ONE item from the select list.

     

    if you want to select multiple items from the select list you should try:

     

    <select multiple="multiple" name="news_id[]" class="FormStandard">

     

    hope this helps

×
×
  • 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.