Jump to content

priti

Members
  • Posts

    461
  • Joined

  • Last visited

Posts posted by priti

  1. Referring

     

    $list = $match[0];

     

    mysql_query("INSERT INTO links

    (url) VALUES('$match') ")

    or die(mysql_error());

     

    modify it as

     

    mysql_query("INSERT INTO links

    (url) VALUES('$list') ")

    or die(mysql_error());

     

    as $list  contains the value.

  2. Thorpe please let me know if you have any idea of below error

     

    "Argument #1 of PHPUnit_Util_Fileloader:checkAndLoad() is no existing file"

     

    This error comes when i run : phpunit testclass.php command on CLI.

     

     

  3. I received good response on those slides - content wise and many beginners find it easy to run the examples and understand the concept behind it. which mainly serves the purpose of it.

     

    But you guy have different view and I think I must consider the look and feel as well as media option also while creating presentation for beginners.

     

    Thanks buddies.

  4. Hey this work fine at my end

     

    testme.php

    <form enctype="multipart/form-data" action="upload.php" method="POST">

    <input type="hidden" name="MAX_FILE_SIZE" value="100000" />

    Choose a file to upload: <input name="uploadedfile" type="file" /><br />

    <input type="submit" value="Upload File" />

    </form>

     

     

    upload.php

    <?php

    $target_path = "uploads/";

    $target_path = $target_path . basename( $_FILES['uploadedfile']['name']);

    if(move_uploaded_file($_FILES['uploadedfile']['tmp_name'], $target_path))

      {echo "File has been uploaded";}

    else

      {echo "The upload did not work.";}

    ?>

     

    /uploads exists in the same dir where these scripts are placed and it's 777.

     

    It works smoothly @ my end I received no error.

  5. do username "stuff, stuffradio, stuf" shares same password ?????  if so then it is the reason you might be getting all users . Secondly you must be fetching only first row and it might be of stuffradio you need to print and see query results.

  6. robert|true|true|false|arun|true|false|true|anu|true|true|false|

     

    I will suggest a small change first you change the delimiter to identify which is new record i.e

     

    $str="robert|true|true|false#arun|true|false|true#anu|true|true|false|";

     

    now

    $dataArr=explode("#",$str);

     

    $tokenitemArr=explode("|",$dataArr[0]);  //you can loop over $dataArr

    print_r($tokenitemArr)

     

    for you query and insert it.

     

     

  7. <script type="text/javascript">

    min=2;

    max=7;

    var roll1=Math.floor(Math.random()*(max-min))+min;

    var roll2=Math.floor(Math.random()*(max-min))+min;

    var roll3 = roll1+roll2;

     

    var roll1 = roll1+<?php print $acv1 ?>;

    var roll2 = roll1+<?php print $acv1 ?>; //this will be enemy's acv

     

    if(document.getElementById('roll3').value <= document.getElementById('acv1').value)

    alert("Miss");

    else

    alert("hit");

    </script>

     

    remember

     

    ACV: <?php print $acv1; ?>

     

    put a hidden textbox

     

    <input type="hidden" value="<?php print $acv1; ?>" id="acv1"/>

     

     

    hope this help.

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