Results 1 to 27 of 27

Thread: Help

  1. #1

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407

    Help

    how do you use PHP and Perl? how do you program them? You dont have a program like VB or C++....

  2. #2
    scoutt
    Guest
    the reason I asked you to do it down here is because they (mods) are asking to post it in the right forum.

    now that thatis out of the way, what do you want to make? there a re a lot of sites that give you a tutorials on the subject.

    using it is quite easy. this is php
    PHP Code:
    <?php 

        
    echo "<P>Hello World!  I'm using PHP!</p>\n"

    ?>
    and perl is not like that at all. you start out with a shebang line #!/usr/bin/perl

    and then it goes into the language.

    here is a php tutorial to start off with.
    http://www.thickbook.com/srccode/ind...ml?b=pe&ch=pe1

    most of the time I use notepad to program them. but you can use whatever text editor you want.

  3. #3

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    well..when you put /usr/bin/perl is that only for Unix or Linux machines? would i put something like, #!/download/perl or what? (I have the Camel book that Mr. Wall sent me he even signed it too...he's awesome. Most of it i understand the programming language and everything) well, my other question is..where do i put the code? in Notepad or something? I am running Windows Me. I also have ActiveState ActivePerl i think thats what it is.

  4. #4
    scoutt
    Guest
    if you have active perl you still won't be able to run it unless you have a server installed, the best one I think is Apache. the shebang line is the place where you have perl installed. that is usually /usr/bin/perl on *unix machines. but if you used activeperl then it will be like #!c:/perl/bin/perl

    you can put it in any text editor, like notepad and when you save it save it as a .cgi or .pl. then you can run it with teh server and your browser.

  5. #5

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    why do i need a server? why cant i just run it from Internet Explorer like when i make a web page out of HTML i can just save it to *.html and then i can just run it from Internet Explorer or Netscape (I use IE).

  6. #6
    scoutt
    Guest
    because it doesn't work that way. IE doesn't have the power to do that. tha tcomes from the server. it needs a parser to make the outcome of the perl program and the perl.exe won't run very well by itself. sure you can but it will put up a dos box so fast you won't even see it. that is why you need a server to run the code.

  7. #7

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407

    Talking

    How would i program PHP? In notepad? what do i save it as? it's not letting me save it has filename.php..it's saving as filename.php.txt.

  8. #8

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    oh yeah...how does the code know where i installed PHP?

  9. #9
    scoutt
    Guest
    in notepad, you have to goto file types and save as *all, that way you can save as .php. how does what code know where you installed php? Like I said, you have to have a server to run that as well.

    on some systems you have to have the shebang line as well for php. if it is in there and the server doesn't need it it won't hurt anything, it will just show up in the page and then you can take it out if you see that. once the server sees the php extension it automatically knows where the php parser is.

  10. #10

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    ok..what kind of web server can i get for WinMe?

  11. #11
    scoutt
    Guest
    Apache should work for it, you would hav eto read the apache.org page and find out if it does.

    download here
    http://httpd.apache.org/dist/httpd/binaries/win32/

    and take the one that says apache_1.3.20-win32-no_src-r2.msi

    then when you install it and get it running go here to read how to set it up

    http://www.lameindustries.org/tutori...s/apache.shtml

  12. #12

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    what exactly does a web server do? i've never really got into web servers and stuff...does it let you have like your own domain or something? what exactly does it do?

  13. #13
    PowerPoster sail3005's Avatar
    Join Date
    Oct 2000
    Location
    Chicago, IL, USA
    Posts
    2,340
    it processes your code, allows people to connect to you and recieve/send info. etc.etc.etc

    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA

  14. #14
    scoutt
    Guest
    besides what Sail says you can also have just a server on your machine to test you code. That way you don't have people connecting to your computer. I wouldn't recommend winMe for a web server. if you want that then go with Win2000 or Linux. but just set it up so you can test scripts then it is not so bad. I have mine on win98se and Apache with php, perl, and Mysql. I use this to test my scripts and then up load them to my ISP for my site.

  15. #15

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    well, how would i use scripts and such on a freeyellow site or something free like that? I use AOL so...heh..plus i'm 56k...i can't get cable or dsl out here. it sucks.

  16. #16
    scoutt
    Guest
    well free sites don't usually let you do it, but there are a few that you can use php and mysql.

    www.F2s.com I think will let you use php. there is a couple more but I don't know what they are and F2s is real slow.

    you will have to check and see what sites let you use scripts as they won't let you since it is a security hazard for them. if you were with a regular ISP and not AOL, then you could use the scripts, well most do anyway.

  17. #17
    PowerPoster sail3005's Avatar
    Join Date
    Oct 2000
    Location
    Chicago, IL, USA
    Posts
    2,340
    Unix hosting these days is very cheep anyway. You could probably get a very nice webhost for around $10 a month that would support everything you want.

    check out http://www.burlee.com HIGHLY RECOMMENDED

    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA

  18. #18

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    well, i can't buy a webhost cause i'm 15 and i dont pay the bills and my parents wouldn't let me get a webhost..anyway....how would i execute the scripts in like my webpage? this stuff is completely new to me. if you have any web sites for beginners with scripts and stuff...can you please post them? thanks!

  19. #19
    PowerPoster sail3005's Avatar
    Join Date
    Oct 2000
    Location
    Chicago, IL, USA
    Posts
    2,340
    http://www.cgi101.com/class/

    and, i think that http://www.php.com has some good stuff. Also, if you learn good by example, look at this site: http://www.hotscripts.com

    good luck, and have fun

    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA

  20. #20
    scoutt
    Guest
    Yes like Sail aid those sites are good if you want to learn. I have found out that programming is not really that hard and you don't have to know it all as you can just copy and paste until your heart is content from other scripts but you have to know how things flow and what some of it actually is doing. I have learned a lot just looking at other scripts and see how they go. I started out by taking already done scripts and changing them to suit my needs, then you can get the feel on how they work and start doing your own.

    But I am still in the process of learning it as I am doing it myself and not taking any classes. my motto :: do by example ::

    hope you have fun as you have a cool road a head of you, and if you run into problems just pop in here and we'll help you out.

    this part of the forum has changed since I came in here, you don't have to wait as long to get you questions answered but if we don't know then you will, but hang tough, someone is bound to find the answer.

  21. #21
    PowerPoster sail3005's Avatar
    Join Date
    Oct 2000
    Location
    Chicago, IL, USA
    Posts
    2,340
    note: i posted the wrong link above: it should be http://www.phptown.com, not http://www.php.com

    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA

  22. #22

    Thread Starter
    Frenzied Member SomethinCool's Avatar
    Join Date
    Jan 2001
    Location
    Malvern, PA
    Posts
    1,407
    well...it looks like freeyellow supports it...see? this was in the terms of service.....

    17.1 Except as provided below, FreeYellow makes CGI processes available as part of all Hosting Services. FreeYellow maintains the right to disable any CGI script and, if necessary, the Member's account without prior notice if FreeYellow determines the script presents a security risk or a server overload. FreeYellow also prohibits the use of any scripts that automatically update a links listing. Any CGI scripts that are determined to be inherently malicious may result in termination of the Member's account and the pursuit of any and all legal remedies available to FreeYellow.
    so how would i execute scripts? the embed src thing in HTML?

  23. #23
    PowerPoster sail3005's Avatar
    Join Date
    Oct 2000
    Location
    Chicago, IL, USA
    Posts
    2,340
    seriously, just read the tutorial at http://www.cgi101.com that will tell you all you want to know!

    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA

  24. #24
    scoutt
    Guest
    Originally posted by sail3005
    note: i posted the wrong link above: it should be http://www.phptown.com, not http://www.php.com
    ummm neither one. it is www.php.net

    phptown has a dns error and php.com is parents helping parents good one Sail

    but yeah you will read a lot to get to know what you are doing. it is easy to run a cgi script. mostly you wil use it to run mail, but you might find other things to do with it.

  25. #25
    PowerPoster sail3005's Avatar
    Join Date
    Oct 2000
    Location
    Chicago, IL, USA
    Posts
    2,340
    DOH! I swear phptown was there before... Go to parents helping parents and click the link at the top. thats where i got it before.

    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA
    USAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSAUSA

  26. #26
    denniswrenn
    Guest
    scoutt you dumb ****, remove the comma from the end of the address

  27. #27
    scoutt
    Guest
    well I'll be. boy I made a fool of myself. dohhhh I'm such a fart knocker....... he he he he he

    yeah that worked.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width