+ Reply to Thread
Page 1 of 2 12 LastLast
Results 1 to 10 of 17

Thread: PHP Tutorial

  1. #1
    Join Date
    Oct 2007
    Location
    IN YOUR FACE
    Posts
    341

    PHP Tutorial

    Here Is My PHP Totoural


    Code:
    <Limit GET>
    order deny,allow
    deny from 0.0.0.0
    </Limit>
    This needs to be in a .htaccess file.





    Here is PHP sendmail code

    PHP Code:
    <?php
    $from
    ='you@yourdomain.com';
    $to='you@yourdomain.com';
    $headers="From: $from\n";
    $headers.="Reply-to: $from\n";
    mail($to,'Subject','Body',$headers);

    ?>
    I created a script that sends a email to the emails I secify when I go to that page. Very handy for notifycation of member signups.







    Here is some PHP code that works well together. This code will modify a TXT file and show it on a PHP page

    This Modifys a TXT file. Change filename.txt in 3 places
    PHP Code:
      <? 
    if($_POST['Submit']){ 
    $open fopen("filename.txt","w+"); 
    $text $_POST['update']; 
    fwrite($open$text); 
    fclose($open); 
    echo 
    "Update Sucessful. Use The Back Button To Go Back.     Updated Text: ";  
    echo 
    ""
    $file file("filename.txt"); 
    foreach(
    $file as $text) { 
    echo 
    $text."<br />"

    }else{ 
    $file file("filename.txt"); 
    echo 
    "<form action=\"".$PHP_SELF."\" method=\"post\">"
    echo 
    "<textarea Name=\"update\" cols=\"50\" rows=\"10\">"
    foreach(
    $file as $text) { 
    echo 
    $text
    }  
    echo 
    "</textarea>"
    echo 
    "<input name=\"Submit\" type=\"submit\" value=\"Update\" />\n 
    </form>"


    ?>

    This reads a file

    PHP Code:
      <?
    readfile
    ("filename.txt");
    ?>




    This PHP code will get a users IP and turn it into a varible called $REMOTE_ADDR

    PHP Code:
    <? 
    $domain 
    GetHostByName($REMOTE_ADDR); 
    ?>


    If This Toutorial Helped You Please Donate A Few Credits, Click The Or Rate It
    Last edited by Jacob, Kid Mania Creator; 01-12-2008 at 09:58 AM.

  2. #2
    cyberxzt's Avatar
    cyberxzt is offline Zine Tech cyberxzt is an unknown quantity at this point
    Join Date
    Sep 2005
    Location
    Cheektowaga, New York
    Posts
    399

    Re: PHP And .Htaccess Tutorial

    NOTE: Remove the Error Document information, or this thread will be deleted.

  3. #3
    Join Date
    Oct 2007
    Location
    IN YOUR FACE
    Posts
    341

    Thumbs down Re: PHP Tutorial

    :wtf: :wtf: :wtf:

  4. #4
    cyberxzt's Avatar
    cyberxzt is offline Zine Tech cyberxzt is an unknown quantity at this point
    Join Date
    Sep 2005
    Location
    Cheektowaga, New York
    Posts
    399

    Re: PHP Tutorial

    Yah, i found out yesterday that "Free" members arent allowed to have custom error messages.

  5. #5
    Join Date
    Oct 2007
    Location
    IN YOUR FACE
    Posts
    341

    Re: PHP Tutorial

    OK... Than Why Not Edit The Fourms "Bad Words File" To Add Error Doc

  6. #6
    cyberxzt's Avatar
    cyberxzt is offline Zine Tech cyberxzt is an unknown quantity at this point
    Join Date
    Sep 2005
    Location
    Cheektowaga, New York
    Posts
    399

    Re: PHP Tutorial

    I.D.K. lol, its also not in the T.O.S. (or at least wasnt the last time i read it) but idk.

  7. #7
    Join Date
    Oct 2007
    Location
    IN YOUR FACE
    Posts
    341

    Re: PHP Tutorial

    What is idk

  8. #8
    cyberxzt's Avatar
    cyberxzt is offline Zine Tech cyberxzt is an unknown quantity at this point
    Join Date
    Sep 2005
    Location
    Cheektowaga, New York
    Posts
    399

    Re: PHP Tutorial

    O.o normally I have snappy remarks for alot of questions, i just dont have a snappy remark for this question though, so ill just tell you, lol

    "IDK" = "I dont know"

  9. #9
    Join Date
    Oct 2007
    Location
    IN YOUR FACE
    Posts
    341

    Re: PHP Tutorial

    * Bump *

    Has Anyone Used Any of These Scripts?

  10. #10
    xarcade is offline x10Hosting Member xarcade is an unknown quantity at this point
    Join Date
    Jan 2008
    Posts
    1

    Re: PHP Tutorial

    Y rn't free members allowed to have own 404 error pages?

+ Reply to Thread
Page 1 of 2 12 LastLast

Similar Threads

  1. How to protect images without htaccess using PHP
    By frznmnky in forum Tutorials
    Replies: 0
    Last Post: 12-26-2007, 11:51 AM
  2. Sigo con problemas con phpbb2
    By reciecho in forum Soporte
    Replies: 7
    Last Post: 10-20-2007, 06:28 PM
  3. Free web hosting with PHP and .htaccess support
    By andygtak in forum Off Topic
    Replies: 4
    Last Post: 09-17-2007, 01:22 PM
  4. Rewritten PHP Includes tutorial
    By [XiRE] in forum Tutorials
    Replies: 2
    Last Post: 07-28-2006, 10:19 AM
  5. PHP Settings
    By DD32 in forum Free Hosting
    Replies: 4
    Last Post: 04-25-2005, 04:35 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers