Kaula Posted January 21, 2006 Posted January 21, 2006 (edited) Hi, I'm trying to install a link script where I can add a link and submit it and it will automatically update the page for me. Here is the error I get after I thought I had it setup properly, http://www.kaulaiscool.com/cgiexample.gif the submit html file is listed here http://www.kaulaiscool.com/links/links.html and the cgi file is located in http://www.kaulaiscool.com/scgi-bin/ and the contents can be read http://www.kaulaiscool.com/links.txt and a readme if anyone needs it http://www.kaulaiscool.com/readme.txt If someone could take a look maybe and see what I am doing wrong? I tried it in /cgi-bin with the same effect. And all the files added were set to the correct chmod listed in the readme I dont know anything about this sorta stuff... Edited January 21, 2006 by Kaula Quote
stevevan Posted January 21, 2006 Posted January 21, 2006 While I'm not a cgi expert, stand by...I'm sure one of our resident scripting guru's will be along shortly to look at your issue. In the meantime, where did you get this script? Does the author have any instructions/comments on the site you got the script from? I'd start looking there. Quote
TCH-Bruce Posted January 21, 2006 Posted January 21, 2006 The first entry "links/links.html" is incorrect. According to the instructions: >$filename = "/server/path/to/links.html"; Path Location of your links.html file. It should be "/home/yourcPanelname/public_html/links/links.html" Also, your database variable is wrong: It should be: "/home/yourcPanelname/public_html/database.txt" Make sure you upload all these files in ASCII mode and not Binary and set the permissions accordingly. HTH Quote
Deverill Posted January 21, 2006 Posted January 21, 2006 Your submit file tries to run the script at www.kaulaiscool.com/scgi-bin/links.cgi It seems that file does not exist. Do you really have an scgi-bin directory - most use just cgi-bin and it may be a typo. Quote
Kaula Posted January 22, 2006 Author Posted January 22, 2006 Hi! Thanks for your replies. TCH-Steve- I found it here http://www.scriptarchive.com/links.html TCH-Bruce- I'll try again to get the paths right TCH-Jim- Well I had orginally tried it in http://www.kaulaiscool.com/cgi-bin, but couldnt get it to work. While I was pouting around in cpanel I noticed something called SCGI Wrap. I enabled it and it gave me a directory of scgi-bin. Figured I'd give it a try before I posted, but it had the same effect. I'll try again with your suggestions, wish me luck! Quote
Kaula Posted January 22, 2006 Author Posted January 22, 2006 Ok, I'm pretty sure I've fixed all the path problems. I reuploaded all the files in ascii mode. http://www.kaulaiscool.com/links/links.html I can enter the url and click add, but it doesnt actually add anything to the list. There is no longer any errors though, like before. Ive taken a look at the code, but I don't know enough about it. Any ideas? variables in the cgi file ># Define Variables $filename = "home/kaulais/public_html/links/links.html"; $linksurl = "http://kaulaiscool.com/links/links.html"; $linkscgi = "http://kaulaiscool.com/scgi-bin/links.cgi"; $linkstitle = "Kaulas Links"; $database = "home/kaulais/public_html/database.txt"; # Done all the links are the same the submit html file is listed herehttp://www.kaulaiscool.com/links/links.html and the cgi file is located in http://www.kaulaiscool.com/scgi-bin/ and the contents can be read http://www.kaulaiscool.com/links.txt and a readme if anyone needs it http://www.kaulaiscool.com/readme.txt Quote
TCH-Bruce Posted January 22, 2006 Posted January 22, 2006 Are you seeing any errors when you view errors in cPanel? Did you create the database.txt file and make the permissions 666? Quote
Kaula Posted January 22, 2006 Author Posted January 22, 2006 (edited) I had the database.txt set to 777, like the readme said, but I tried it with 666 also with no effect. No, there hasnt been any errors in the cpanel log since I fixed the paths a cgi file can run from any folder right? Edited January 22, 2006 by Kaula Quote
Kaula Posted January 22, 2006 Author Posted January 22, 2006 Wait the readme says the database.txt needs to be in /path/to/database.txt and i have it set as home/kaulais/public_html/database.txt is that right? Quote
TCH-Bruce Posted January 22, 2006 Posted January 22, 2006 No it should be like this: # Define Variables $filename = "/home/kaulais/public_html/links/links.html"; $linksurl = "http://kaulaiscool.com/links/links.html"; $linkscgi = "http://kaulaiscool.com/scgi-bin/links.cgi"; $linkstitle = "Kaulas Links"; $database = "/home/kaulais/public_html/database.txt"; # Done Note the leading "/" Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.