Warnings

More
14 years 1 week ago #1491 by Pete
Replied by Pete on topic Warnings
Can you email me your config.php and list.php files (with the guestbook admin password in it) to webmaster@digioz.com ?

It looks like the guestbook entries ARE getting written to file. They just don't display correctly. Try clearing the file list.txt (reset permission to 777), then try posting again.

Pete

DigiOz Webmaster
www.digioz.com

Please Log in or Create an account to join the conversation.

More
14 years 1 week ago #1492 by lienetrien
Replied by lienetrien on topic Warnings
Hi Pete,

thank you.

I have cleared and reset the list.txt file, but no solution.

I have sent the requested files by mail.

Thank you for the effort

Please Log in or Create an account to join the conversation.

More
14 years 1 week ago #1493 by Pete
Replied by Pete on topic Warnings
I see some HTML tags in your config.php file! There should not be any! In addition it looks like your word editor has taken away all the new line characters. Here is what should be in config.php file:
Code:
<?php // Variables for making a field optional in form ------------------------------------- $email_optional = 1; // Set "1" for optional email, "0" to make it required $name_optional = 0; // Set "1" for optional name, "0" to make it required $message_optional = 0; // Set "1" for optional message, "0" for required // Variables for notifying administrator when a new message is posted ---------------- $notify_admin = 0; // Set "1" to notify administrator through email // when a new guestbook entry is written. // Warning: To use this feature you will have to have // your "SMTP" and "smtp_port" setting in php.ini set. // Enter the admin notification email subject bellow $notify_subject = "You have a new entry in your DigiOz Guestbook"; // Enter administrative email to receive notification $notify_admin_email = "webmaster@yourdomain.com"; // Body of the notification message $notify_message = "A new entry has been submitted to your DigiOz Guestbook."; // Variable for choosing language file name ----------------------------------------- $default_language = "language.php"; // Image Verification Feature ------------------------------------------------------- $image_verify = 0; // Do Image Verification to prevent spam post // This option requires your PHP to have been // compiled with GD 2.0.x or higher library so // it may not work with all server environments. // However, image verification is the MOST effective // way of getting rid of spam, so we highly recommend it. // Admin Interface Username --------------------------------------------------------- $_Username = "admin"; $_Password = "admin"; // Flood protection setting --------------------------------------------------------- $gbflood = 0; // Set "1" to prevent flooding, "0" to disable it $referersKey = 0; // Set "1" to check to see where submitted guestbook // messages are coming from or "0" to disable it $referers = array ( 'yourdomain.com', // Your domain name without WWW 'www.yourdomain.com', // Your domain name with WWW '111.222.333.444'); // IP Address of your site $gbIPLogKey = 1; // Set "1" to log IP of Visitor for each post "0" to disable $banIPKey = 0; // Set "1" to block posting of banned IP or "0" to disable // --------------------------------------------------------------------------------- // Bellow you can list known IP addresses you would like to block. ----------------- // We have given you a list of known spammers bellow. Feel free -------------------- // to either use our list or delete our list and create your own ------------------- // based on the IP logs of the guestbook. For updates to our list ------------------ // of known spammers please visit www.digioz.com or email our ---------------------- // tech support team. -------------------------------------------------------------- // --------------------------------------------------------------------------------- $banned_ip = array(); $banned_ip[] = '195.225.176.57'; $banned_ip[] = '212.62.19.185'; $banned_ip[] = '202.3.130.20'; $banned_ip[] = '222.104.7.196'; $banned_ip[] = '61.33.229.80'; $banned_ip[] = '63.138.25.195'; $banned_ip[] = '205.208.226.61'; $banned_ip[] = '213.46.224.101'; $banned_ip[] = '167.193.194.101'; $banned_ip[] = '207.63.100.162'; $banned_ip[] = '210.177.248.130'; $banned_ip[] = '195.225.176.57'; $banned_ip[] = '80.58.50.107'; $banned_ip[] = '80.58.33.170'; $banned_ip[] = '80.58.11.42'; $banned_ip[] = '207.63.100.163'; $banned_ip[] = '211.233.9.201'; $banned_ip[] = '82.236.86.223'; $banned_ip[] = '63.98.230.188'; $banned_ip[] = '195.228.156.106'; $banned_ip[] = '200.9.37.220'; $banned_ip[] = '200.57.91.108'; $banned_ip[] = '69.212.48.169'; $banned_ip[] = '61.0.62.4'; $banned_ip[] = '12.160.225.230'; $banned_ip[] = '219.93.174.101'; $banned_ip[] = '203.162.27.199'; $banned_ip[] = '66.94.81.202'; $banned_ip[] = '210.113.222.227'; $banned_ip[] = '59.23.9.141'; $banned_ip[] = '58.227.196.150'; $banned_ip[] = '59.23.9.141'; $banned_ip[] = '218.26.207.66'; $banned_ip[] = '84.254.189.37'; $banned_ip[] = '203.162.27.195'; $banned_ip[] = '202.101.173.69'; $banned_ip[] = '203.145.159.45'; $banned_ip[] = '63.138.25.195'; $banned_ip[] = '207.63.100.162'; $banned_ip[] = '80.56.174.130'; $banned_ip[] = '211.53.64.127'; $banned_ip[] = '200.2.128.2'; $banned_ip[] = '204.113.91.19'; // Bad word filter for guestbook ----------------------------------------------------- $gbBadWordsKey = 0; // Set "1" to filter bad words, "0" to not filter $gbBadWords = array( "ass", "bitch", "clit", "cock", "c0ck", "cum", "cunt", "fucking", "fuck", "fuking", "fuk"); // Spam Detection ------------------------------------------------------------------- $gbSpamKey = 1; // Set "1" to Block Spam based on Keyword entered $gbSpam = array ( "cheap", "phentermine", "splinder", "hydrocodone", "vicodin", "vicodin", "pharmacy", "prescription", "buy", "drug", "pills", "soma"); // End of Configuration File -------------------------------------------------------- ?>

Same goes for list.php. Here is what should be in it:
Code:
<?php include("header.php"); $page = $_GET['page']; $order= $_GET['order']; // Validate browser input ------------------------------------------------------------ if (is_numeric($page) == false) { echo "<font color=\"red\">Non Numeric Page Number</font>"; include("footer.php"); exit; } if (!($order == "asc" || $order == "desc")) { echo "<font color=\"red\">Entry order can only be 'asc' or 'desc'</font>"; include("footer.php"); exit; } // ----------------------------------------------------------------------------------- if ($page == "") { $page = 1; } $fwd = $page - 1; $rwd = $page +1; // Setting the default values for number of records per page ------------------------- $perpage = 10; //$filename = "list.php"; // Reading in all the records, putting each guestbook entry in one Array Element ----- $filename = "data/list.txt"; $handle = fopen($filename, "r"); if (filesize($filename) == 0){ // mpg are there any entries to display print "There are currently no entries to display"; // mpg no inform user } else { $datain = fread($handle, filesize($filename)); fclose($handle); $out = explode("<!-- E -->", $datain); $outCount = count($out) - 1; $j = $outCount-1; if ($order == "desc") { for ($i=0; $i<=$outCount; $i++) { $lines[$j] = unserialize($out[$i]); $j = $j - 1; } } else { for ($i=0; $i<=$outCount; $i++) { $lines[$i] = unserialize($out[$i]); } } // Counting the total number of entries (lines) in the data text file ---------------- $result = count($lines); $count = $result-1; //echo $count."<br>"; // Caclulate how many pages there are ---------------------------------------- if ($count == 0) { $totalpages = 0; } else { $totalpages = intval(($count - 1) / $perpage) + 1; } $page = $totalpages - ($page - 1); $end = $count - (($totalpages - $page) * $perpage); $start = $end - ($perpage - 1); if ($start < 1) { $start = 1; } //$end = ($perpage * $page) - 1; //$start = $end - $perpage; if ($start < 0) { $start = 0; } //for ($i = $end; $i>=($start-1); $i--) //for ($i = 0; $i<$outCount; $i++) //for ($i=$start-1; $i<$end; $i++) for ($i=$end-1; $i>$start-2; $i--) { //echo $i."<br>end-".$end."-start-".$start; echo "<table bgcolor=#EFEFEF bordercolor=#C0C0C0 border=1 width=500 cellspacing=0 cellpadding=10><tr><td background=\"images/toolbar.jpg\" height=\"20\"></td></tr><tr><td>"; echo "<b>$listDatetxt: </b>"; $lines[$i]->showDate(); echo "<br><b>$listnametxt: </b>"; $lines[$i]->showFrom(); echo "<br><b>$listemailtxt: </b><a href=\"mailto:"; $lines[$i]->showEmail(); echo "\">"; $lines[$i]->showEmail(); echo "<br><br><b>$listMessagetxt: </b>"; $lines[$i]->showMessage(); echo "</td></tr></table><br>"; } echo "<center>"; // Creating the Forward and Backward links ------------------------------------- if ($fwd > 0 && $rwd > 0 && $rwd<$totalpages+1) { echo "<br><a href=\"list.php?page=$fwd&order=$order\">&lt&lt"; echo "<a href=\"list.php?page=$rwd&order=$order\">&gt&gt<br>"; } else if ($fwd == 0) { echo "<a href=\"list.php?page=$rwd&order=$order\">&gt&gt<br>"; } else if ($rwd == 0) { echo "<br><a href=\"list.php?page=$fwd&order=$order\">&lt&lt"; } else if ($rwd == $totalpages+1) { echo "<a href=\"list.php?page=$fwd&order=$order\">&lt&lt<br>"; } for ($i = 1; $i<=$totalpages; $i++) { echo " <b>[ <a href=\"list.php?page=$i&order=$order\"><b>$i</b> ]</b> "; } echo "</center>"; } // mpg end if include("footer.php"); ?>

Please make these changes, upload them to your server and try again.

Pete

DigiOz Webmaster
www.digioz.com

Please Log in or Create an account to join the conversation.

More
14 years 1 week ago #1494 by lienetrien
Replied by lienetrien on topic Warnings
Hi Pete,

thank you very much. It is working fine now.

I'm using NVU to adopt the files and I was not aware the program was adding additional code.

Only thing not working yet is the admin page, but that's not so urgent.

I am very happy I can put the guestbook now on the web page of my little niece.
Thank you very much!

Please Log in or Create an account to join the conversation.

More
14 years 1 week ago #1495 by lienetrien
Replied by lienetrien on topic Warnings
Hi Pete,

also the Admin page works fine now.
I forgot to change the login when I copied the code back from the site to the file.

Thank you very much for all the effort!

Please Log in or Create an account to join the conversation.

More
14 years 1 week ago #1496 by Pete
Replied by Pete on topic Warnings
Glad I could be of help. Thank you for using the DigiOz Guestbook. :)

Pete

DigiOz Webmaster
www.digioz.com

Please Log in or Create an account to join the conversation.

Time to create page: 0.126 seconds
Powered by Kunena Forum