Jump to content

phpretard

Members
  • Posts

    821
  • Joined

  • Last visited

    Never

Posts posted by phpretard

  1. I plan on importing 3-5 thousand entries at once (all is text).

     

    Each entry has 20 pieces of information. (ie. name, address, phone, and so on...)

     

    I will input these once per week.

     

    How much information is too much for one DB.

  2. My DB holds the date like this - 20080115.

     

    How can I turn that into - January 15, 2008 - ?

     

    $U is the date.

     

    My Query Code:

    
    $result = mysql_query("SELECT * FROM list");
    
    while($row = mysql_fetch_array($result))
      {
    include 'vars.php';
    
    echo $U ."<br>";
    
      }
    
    

     

    Any Help?

     

    -Anthony

  3. Is it possable to select 2 tables with the same query?

     

    I would like to combine the two statements.

     

    mysql_query("SELECT * FROM members WHERE CNumber='$CNumber' ");
    
    mysql_query("SELECT * FROM readings WHERE CNumber='$CNumber' AND RType='$RType'");
    

     

     

    Thank you.

  4. Thank you for clearing that up.

     

    With that info in place...

     

    What do you suggest I use to replace this statement below and how should I echo the var?

     

    I would ultimatly like to echo the var on evry page...but it isn't happening unless I set it on every page.

     

    If this question is deeper then I think can you point me towards a good tutorial in these regards?

     

    
    if(session_is_registered(FirstName)){
    
    echo "?????";
    
    }
    

     

    Thank you fir you help with this.

  5. I have been trying all day to display a PDF file inline with the rest of the page.

     

    I could use frames I guess but not all browsers support frames.

     

    
    <?
    
    if (!session_is_registered(sesion_var)){
    
    die ("PLEASE LOG IN");
    
    }
    
    else {
    
    include ("pages/ins_pgs/pdfs/diagrams/$CNumber.pdf");
    
    }
    ?>
    

  6. So here is what I did.

     

    When the page opens it makes the directory.

     

    When I submit the form it trys to make another directory and insert the pdf.

     

    Notice the 2 errors fighting?

     

    <?php
    
    mkdir("/home/content/d/a/r/daruano/html/pages/test ",0777);
    
    
    if (isset($_POST['submit'])){
    
    
    $uploaddir = "../../pages/test";
    
    if(is_uploaded_file($_FILES['file']['tmp_name']))
    {
    move_uploaded_file($_FILES['file']['tmp_name'],$uploaddir.'/'.$_FILES['file']['name']);
    }
    print "done";
    
    }
    ?>
    
    <form action="test_form.php" method="post" ENCTYPE="multipart/form-data">
    
    File: <input type="file" name="file" size="30"> <input type="submit" name=submit value="Upload!">
    
    </form> 
    

     

     

     

    Warning: mkdir() [function.mkdir]: File exists in /home/content/d/a/r/daruano/html/secure/upload/test_form.php on line 2

     

    Warning: move_uploaded_file(../../pages/test/checklist.pdf) [function.move-uploaded-file]: failed to open stream: No such file or directory in /home/content/d/a/r/daruano/html/secure/upload/test_form.php on line 11

  7. Each one these numbers still produce the same error.

     

    Currently, the page with this code (and this code only) is located @ www.mywebsite.com/thiscode.php

     

    Is it relavant where (in the web directory) the code is executed from?

     

    I believe I am just missing something simple.

     

    
    mkdir("/home/content/d/a/r/daruano/html/pages/folder1 ", 0777);
    
    

  8. It still gives an error about not in the web...

     

    How would you go about acomplishing what I am tryin to acomplish.

     

    I want to upload a pfd to a directory instead of storing it in the DB.

     

    I would like to be able to create a new directory for that pdf during upload.

  9. I am actually trying to take the last advise from BlueSkyIS.

     

    I want to upload a pfd to a directory instead of storing it in the DB.

     

    I would like to be able to create a new directory for that pdf during upload.

     

    Any thoughts on that?

     

    Here is the full code MadTechie...

     

    It does visualy make the folder I just can't access it.

     

    mkdir("/home/content/d/a/r/daruano/html/pages/folder1 ", 0700);

     

    What should the permissions be. I am logged in as administrator with full rights.

  10. When I use this to make a directory it makes a directory, but...

     

    When I try to open that directory I am promted that The Folder refers to a nonexistant file or folder Or it isn't valid or in the current web.

     

    Is there something wrong with this code?

     

    mkdir("/html/pages/folder1 ", 0700);

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