|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
I was wondering if it would be possible to install PERL on your computer. The reason I want to install PERL on my computer is so that I can test it out on my comp first before I upload the scripts onto a server? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Aug 2000
Posts: 3,590
Moderator
|
Moderator
Joined: Aug 2000
Posts: 3,590 |
Of course it is. www.activestate.com You may want to have Mark let ya know which file it needs to be. YOu will also need to get a webserver up and running if ya want to test CGI. www.apache.com is one that I recomend. Again, someone else will have to point you to the correct file... ------------------ Da Wannabe Cannuck
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
Yep, you need to install Acivestate perl from here . You may also need the windows installer, which there is a link for right on that page also. I recommed you just install in the default c:perl directory. and apache (other web servers work, but PWS is a pain in the ass). Apache is simple. Get the windows binary . Your shebang will read #!c:/perl/bin/perl.exe and you call scripts up with http://localhost/cgi-bin/scriptname.cgi --mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: Jul 2000
Posts: 25
Member
|
Member
Joined: Jul 2000
Posts: 25 |
Checkin' out the topic, and I was wondering, how would you upload everything, via FTP or what?
~The Man is Back!~
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Thank you so much guys, I'll try to install PERL...I'll notify you guys if it's a success or not... ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Aug 2000
Posts: 3,590
Moderator
|
Moderator
Joined: Aug 2000
Posts: 3,590 |
Why would you need to upload stuff if it is already on yor computer, hehe...
------------------ Da Wannabe Cannuck
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Yeah but Atom would you have to put your scripts in a certain directory for this? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Aug 2000
Posts: 3,590
Moderator
|
Moderator
Joined: Aug 2000
Posts: 3,590 |
Yeah, they have to be in the directory you specify for Apache to use. I specified my personal folder on my computer. It holds all my scripts..
------------------ Da Wannabe Cannuck
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
atom911, I'm not too clear on what you just said. DO you mean I have to put the scripts in the directory I installed Apache? If not, how do I specify the folder? I've already installed and download: 1. Apache 2. ActiveState PERL 3. Windows Installer I'm running Windows 98, will there be anything else that i need? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Ok now I'm really confused, I just installed Apache (I think)..I downloaded the program Mark linked me too and I ran it. Is that all I have to do to install Apache Web Server on my computer? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Aug 2000
Posts: 3,590
Moderator
|
Moderator
Joined: Aug 2000
Posts: 3,590 |
YOu need to find a tutorial. You need to config apache via the httpd.conf file in the conf directory in the apache directory. YOu also need to add a few lines to it to use CGI...
------------------ Da Wannabe Cannuck
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Um ok, can you refer anything? I just need to configure this so that I'll be able to run PERL scripts on my computer. Nothing else, just that..Will it be complicated to set up? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Jul 2000
Posts: 25
Member
|
Member
Joined: Jul 2000
Posts: 25 |
hmm ive been trying to do the same thing for a while i got apache runnin on my comp with php and all this other **** but what i cant figure out is how to chmod your files to 755 and 777 on your own comp anyone know how to do this ------------------ Webmaster @ EminemBoard.com Marshall-Mathers.Net Email= Evan@EminemBoard.com Aim=EminemBoard ICQ=71361151 "We don't do drivebys, we park in front of houses and shoot, and when the police come we fu*kin shoot it out with them too!"~Eminem Free Voice Mail=1-877-541-6655 ext.278
<FONT COLOR="red">(`* . </FONT c><FONT COLOR="black">(`* . </FONT c><FONT COLOR="red"> *</FONT c><FONT COLOR="black"> . * )</FONT c><FONT COLOR="red"> . * )</FONT c> <FONT COLOR="black"> ` .</FONT c><FONT COLOR="red">E</FONT c>minem <FONT COLOR="red">B</FONT c>oard<FONT COLOR="black">. ` </FONT c> <FONT COLOR="red">(. ' </FONT c><FONT COLOR="black">( . '</FONT c><FONT COLOR="red">*</FONT c><FONT COLOR="black">' . )</FONT c><FONT COLOR="red">`' .)</FONT c> <FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_
<FONT COLOR="black"><FONT size="7">(</FONT s><FONT size="6">(</FONT s><FONT size="5">(</FONT s><FONT size="4">(</FONT s><FONT size="3">(</FONT s></FONT c><FONT COLOR="red">EminemBoard</FONT c><FONT COLOR="black"><FONT size="3">)</FONT s><FONT size="4">)</FONT s><FONT size="5">)</FONT s><FONT size="6">)</FONT s><FONT size="7">)</FONT s></FONT c>
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Eminem, you got Apache running on your comp? How, and what did you have to do? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
You don't chmod on a windows machine. There aren't file permissions like in Unix (there are permissions, but not the same way). When you install apache, there will be a cgi-bin created in your apache directory. just put your scripts in there. Have a look at the httpd.cong file, and all the comments will guide you on your settins. default should be set to run cgi scripts, but if not, just uncomment the lines dealing with that (they're marked...just search for cgi) Move your scripts to the cgi-bin,and call http://localhost/cgi-bin/scriptname.cgi --mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: Jul 2000
Posts: 25
Member
|
Member
Joined: Jul 2000
Posts: 25 |
ok i know i got my httpd right but i tried runnin ubb and i still got this message Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, [email protected] and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. -------------------------------------------------------------------------------- Apache/1.3.11 Server at localhost Port 80 ------------------ Webmaster @ EminemBoard.com Marshall-Mathers.Net Email= Evan@EminemBoard.com Aim=EminemBoard ICQ=71361151 "We don't do drivebys, we park in front of houses and shoot, and when the police come we fu*kin shoot it out with them too!"~Eminem Free Voice Mail=1-877-541-6655 ext.278
<FONT COLOR="red">(`* . </FONT c><FONT COLOR="black">(`* . </FONT c><FONT COLOR="red"> *</FONT c><FONT COLOR="black"> . * )</FONT c><FONT COLOR="red"> . * )</FONT c> <FONT COLOR="black"> ` .</FONT c><FONT COLOR="red">E</FONT c>minem <FONT COLOR="red">B</FONT c>oard<FONT COLOR="black">. ` </FONT c> <FONT COLOR="red">(. ' </FONT c><FONT COLOR="black">( . '</FONT c><FONT COLOR="red">*</FONT c><FONT COLOR="black">' . )</FONT c><FONT COLOR="red">`' .)</FONT c> <FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_<FONT COLOR="red">_</FONT c>_
<FONT COLOR="black"><FONT size="7">(</FONT s><FONT size="6">(</FONT s><FONT size="5">(</FONT s><FONT size="4">(</FONT s><FONT size="3">(</FONT s></FONT c><FONT COLOR="red">EminemBoard</FONT c><FONT COLOR="black"><FONT size="3">)</FONT s><FONT size="4">)</FONT s><FONT size="5">)</FONT s><FONT size="6">)</FONT s><FONT size="7">)</FONT s></FONT c>
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
$10 says you didn't use the right shebang
--mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: May 2000
Posts: 243
Member
|
Member
Joined: May 2000
Posts: 243 |
Mark - You don't have to run them from your cgi-bin. I have all mine run from htdocs/my_directory/scriptname.cgi ![[Linked Image]](https://ubbdev.com/ubb/smilies//tongue.gif) ------------------ My Freeware Board
|
|
|
|
Joined: Aug 2000
Posts: 338
Member
|
Member
Joined: Aug 2000
Posts: 338 |
i am so confused...if someone could give me a step by step guide telling me what files to download were to downloaded them what file to change, what to change in that file, and how to run it. that would be great...
|
|
|
|
Joined: Aug 2000
Posts: 3,590
Moderator
|
Moderator
Joined: Aug 2000
Posts: 3,590 |
Scripts can be run in any directory I believe(you may have to set something in the httpd.conf file) I run it straight from my documents folder.
Try searching for tutorials. I think Apache may even point to a setup tutorial...
------------------ Da Wannabe Cannuck
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
I'm not 100% sure about this but I think here's where you can http.conf to change your CGI-Bin directory to a personal one: # # ScriptAlias: This controls which directories contain server scripts. # ScriptAliases are essentially the same as Aliases, except that # documents in the realname directory are treated as applications and # run by the server when requested rather than as documents sent to the client. # The same rules about trailing "/" apply to ScriptAlias directives as to # Alias. # ScriptAlias /cgi-bin/ " C:/Program Files/Apache Group/Apache/cgi-bin/" # # "C:/Program Files/Apache Group/Apache/cgi-bin" should be changed to whatever your ScriptAliased # CGI directory exists, if you have that configured. # C:/Program Files/Apache Group/Apache/cgi-bin"> AllowOverride None Options None
I think that's all you have to change in the http.conf file. ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Ok now I've got a minor problem here. I changed the httpd.conf file to my settings (C:My Docuementscgi-bin) But now whenever I try accessing through http://localhost/cgi-bin/scriptname.cgi I get a cannot find server error. Am I supposed to type in localhost or replace that with the folder I've installed the CGI-Bin in? ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
don't change the httpd.conf file. use the default. when you install apache it should set up most things you want.
you use localhost/cgi-bin in your url. if you want other pages, put them in the htdocs directory (your root) and then localhost/page.html
[edit..ddidnt see your post immediatly above. If you did the regular apache install and used default install directories, leave the above section as it is above where you pasted it....] --mark
This message has been edited by Mark Badolato on September 24, 2000 at 03:51 PM
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
OK I'm trying to install the freeware UBB on my comp, I've made sure the shebang is right, but I still get that problem about: Cannot Find ServerAny ideas? [edit=I've also changed the conf file back to its original settings, but I'm still getting the error] ------------------ Quality Pages designing the world professional web pages for affordable prices. This message has been edited by Pyros on September 24, 2000 at 03:57 PM
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
Do you have apache running? If on 98, when you start it, you'll have a dos window that needs to be minimized. if you start it and it opens then closes real quick, Apache failed to start
--mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: Aug 2000
Posts: 3,590
Moderator
|
Moderator
Joined: Aug 2000
Posts: 3,590 |
You need to uncomment localhost in the file. And then start apache...
------------------ Da Wannabe Cannuck
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Yes thank you very much guys it works now, but one simple question now. When I start Apache, this is what it says: Unclean Shutdown of Apache Run?Exactly like that, and I don't have the ability to quit Apache other than clicking on the X... Not really a big deal though..... ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
In your start menu under Apache, you should have been given a shutdown option. if not, issue apache -k shutdown
--mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: Mar 2000
Posts: 445
Member
|
Member
Joined: Mar 2000
Posts: 445 |
Ahh yes I see it, you mean the Start and Stop functions in the folder... Yep I've got that, Thanks alot to both Atom and Mark! ------------------ Quality Pages designing the world professional web pages for affordable prices.
|
|
|
|
Joined: Sep 2000
Posts: 14
Junior Member
|
Junior Member
Joined: Sep 2000
Posts: 14 |
I knew setting your comp up as a web server was possible I just didn't know how to do it. After reading this post I thought I would give it a try. Sure enough I have it up and running, everything working fine. Though I would like to know how to run scripts outside of my cgi-bin. Can anyone help me there?
Also I have a static ip *shudders* mostly because dsl is not available in my area yet. either cable or anything. But to the point I would like to know if there is a way to put my current ip address on the ServerName command. I don't plan on using my comp as a full fledged web server, but editing that line every time is annoying. Is there a way I could do this with a batch file or somthing?
Thanks for all your help.
------------------ -Twenty7
|
|
|
|
Joined: Sep 2000
Posts: 14
Junior Member
|
Junior Member
Joined: Sep 2000
Posts: 14 |
As for processing scripts outside of the cgi-bin I fixed that problem. I simply set my ScriptAlias to the same as my DocumentRoot. Everything works fine except dirrectory tree listings don't show up. Is there a way to get them to show up? or am I stuck without them? Thanks again. ------------------ -Twenty7 http://www.englishhouse.com/twenty7/ That game called Infantry http://infantry.nmebase.com/
|
|
|
|
Joined: Sep 2000
Posts: 14
Junior Member
|
Junior Member
Joined: Sep 2000
Posts: 14 |
after hours of reading i fixed that too. I just have this ip address problem. If anyone knows a variable for a dos command to show the ip of your comp I could set it up to edit the conf file and put my current ip everytime I connect, and before I started the server. if anyone knows that or where I might find such help on this I will give you a cookie ![[Linked Image]](https://ubbdev.com/ubb/smilies/wink.gif) thanks ------------------ -Twenty7 http://www.englishhouse.com/twenty7/ That game called Infantry http://infantry.nmebase.com/
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
Your IP address can be obtained a few ways... in your TCP/IP properties, or jumping to DOS and typing ipconfig.
--mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: Sep 2000
Posts: 14
Junior Member
|
Junior Member
Joined: Sep 2000
Posts: 14 |
I know several ways to get my ip address. But I don't know how I would do it this way. Basically what I did was used all 3 of the config files for simplicity. Here is what I have. open(LOG, ">srm.conf"); print LOG "ServerName $ipn"; close (LOG); I want to be able to replace $ip with my current ip address. I do know accessing this file via my browser I would use $ip = $ENV{'REMOTE_ADDR'}; BUT. I want to activate the script at the dos prompt. perl ip.pl when I do this the $ENV{'REMOTE_ADDR'}; variable does not work. I want to know what variable would work in its place. If there is any. Thanks again ------------------ -Twenty7 http://www.englishhouse.com/twenty7/ That game called Infantry http://infantry.nmebase.com/ This message has been edited by Twenty7 on September 27, 2000 at 12:19 AM
|
|
|
|
Joined: Mar 2000
Posts: 3
Junior Member
|
Junior Member
Joined: Mar 2000
Posts: 3 |
Ok ppl for everyone who needs help with Apaches httpd.conf
here is what you may need to do
httpd.conf Find this line in the file: #ServerName new.host.name (232) Change the line to: ServerName localhost Uncomment the following lines by removing the # if present:
#ScriptAlias /cgi-bin/ "C:/Apache/cgi-bin/" (458) #AddHandler cgi-script .cgi (633) #AddType text/html .shtml (638) #AddHandler server-parsed .shtml (639)
Save the changes. You should actually read the comments for the lines you changed to understand why you did what you did. Your server should now be readly to run your Perl CGI scripts.
I hope this helps
Wheelie
|
|
|
|
Joined: May 2000
Posts: 15
Junior Member
|
Junior Member
Joined: May 2000
Posts: 15 |
i would just like to chime in here and say: buy a mac. i got perl running (MacPerl) on my machine without a hitch, the first time. it also does syntax checks, taint checks, compiler warnings, and a PERL DEBUGGER. macs rule. ------------------ AIM: NtEon ICQ: 70520947 email: eon@bestweb.net ** i keep forgeting to change my sig ** This message has been edited by eon on October 12, 2000 at 04:42 PM
assistant administrator- UBB Code Hackers Hideout moderator- Perl and CGI Scripts and Programming AIM: NtEon ICQ: 70520947 email: eon@ubbcodehacking.com
|
|
|
|
Joined: Oct 2000
Posts: 966
Member
|
Member
Joined: Oct 2000
Posts: 966 |
Yeah, but aside from that, what is a mac but a really large paperweight? ![[Linked Image]](https://ubbdev.com/ubb/smilies/smile.gif)
|
|
|
|
Joined: Aug 2000
Posts: 469
Member
|
Member
Joined: Aug 2000
Posts: 469 |
dig, dig... wheelie, I did exactly what you said with no luck. I've read through this entire thread, it's rather confusing. Doesn anyone have a surefire way of making this work? edit: right after I posted that, I remebered that I didn't run apache.exe. BUT, theres still a problem. Now I just get an ISE 500, and the actual program gives this error: I omitted the date at the beginning of that quote. But yeah, I don't know what is wrong. ------------------ -david Choose your future. www.antipopculture.org This message has been edited by evil-empire on October 28, 2000 at 05:15 PM
|
|
|
|
Joined: Sep 2000
Posts: 755
P.I.T.A. / Programmer
|
P.I.T.A. / Programmer
Joined: Sep 2000
Posts: 755 |
That error means you closed the apache window without executing a proper shutdown. If the program is giving and ISE500, make sure the shebang is #!c:/perl/bin/perl.exe Apache for win has always been SO easy for me to get running on my machines. ![[Linked Image]](https://ubbdev.com/ubb/smilies/smile.gif) --mark
"Annnnnnnndd now, opening for Iron Maiden...... WYLD STALLYNS!!!" --Bill S. Preston, Esquire and Ted "Theodore " Logan
|
|
|
|
Joined: May 2000
Posts: 243
Member
|
Member
Joined: May 2000
Posts: 243 |
EE, if your still haveing problems stop me when I'm online and say ![[Linked Image]](https://ubbdev.com/ubb/smilies/smile.gif)
|
|
|
Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.
Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
|
|
Posts: 1,157
Joined: July 2001
|
|
Forums63
Topics37,575
Posts293,931
Members13,823
|
Most Online6,139 Sep 21st, 2024
|
|
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
|
|
|
|