Jump to content


Photo

Comment code help


  • Please log in to reply
3 replies to this topic

#1 Elusid

Elusid
  • Members
  • PipPipPip
  • Advanced Member
  • 38 posts

Posted 02 October 2006 - 11:22 PM

Ok so i recently found some code on this site http://tjw.org/discust/ that lets you have a comment system. I downloaded it, installed it on the server, and ran it... ok great then they said that you can change the defalt location to something out side your temp folder. Here is the code to inc it all together...
<?php
	session_start();
	$_SESSION["DISCUST_USER"] = "testing";
	require("discust.php");
	$discust = new discust("/tmp/discust_test");
	$discust->display();
	?>

I did the same thing but replaced /tmp/discust_test with /comments/ and comments/ and /comments... none of them worked. I have the folder on the server. If I did the comments/ one it would let me get through all the form stuff but when I hit post I got this. "Warning: fopen(comments/): failed to open stream: Is a directory in /home/www/flamelicker.com/test/discust.php on line 106
ERROR: could not write comments/" any ways here's what the whole code is...

http://tjw.org/discust/discust.phps

#2 realjumper

realjumper
  • Members
  • PipPipPip
  • Advanced Member
  • 399 posts

Posted 03 October 2006 - 12:21 AM

Perhaps you need to check the folder permissions....I would think that write permissions for the comments folder are required

#3 Caesar

Caesar
  • Members
  • PipPipPip
  • Advanced Member
  • 1,025 posts

Posted 03 October 2006 - 12:37 AM

comments = Folder is in the same level
../comments = Folder is one level up

And so on...and so forth. Make sure you're defining the correct path...relative to where you are calling it from.
PHP Ninja

#4 Elusid

Elusid
  • Members
  • PipPipPip
  • Advanced Member
  • 38 posts

Posted 03 October 2006 - 12:41 AM

I changed the permissions to 777 and also then the comments/ should have worked because it was in the same folder as the file I was reading...





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users