Pixelpost

Authentic Photoblog Flavour


Go Back   Pixelpost Forum > SUPPORT / INFORMATION > Pixelpost Help

Post Reply
 
Thread Tools
  #1  
Old 01-27-2005, 03:13 PM
biggest_apple Offline
pp regular
 
Join Date: Oct 2004
Posts: 32
save info cookie for the comments

I've found this brought up somwhere in the forum but I can't find if there was a solution offered. Anyone know how to include a save info cookie for the comments?
Reply With Quote
  #2  
Old 01-28-2005, 07:18 PM
biggest_apple Offline
pp regular
 
Join Date: Oct 2004
Posts: 32
Just realized that this feature may have been part of my pixelpost download but quite a bit of alteration was done to achieve what I was after so I can't remember. If it was there can someone tell me how I can get that feature back ?
__________________
http://www.smallestphoto.com/
Reply With Quote
  #3  
Old 01-28-2005, 07:39 PM
andy Offline
pp regular
 
Join Date: Dec 2004
Location: Minnesota, USA
Posts: 29
I also have modified mine quite a bit, but look for this bit of code:

// visitor information in comments
$vinfo_name = "";
$vinfo_url = "";
if(isset($_COOKIE['visitorinfo'])) {
// do stuff
list($vinfo_name,$vinfo_url) = split("%",$_COOKIE['visitorinfo']);
}
$tpl = ereg_replace("<VINFO_NAME>",$vinfo_name,$tpl);
$tpl = ereg_replace("<VINFO_URL>",$vinfo_url,$tpl);
Reply With Quote
  #4  
Old 01-28-2005, 08:45 PM
biggest_apple Offline
pp regular
 
Join Date: Oct 2004
Posts: 32
thanks for the help. Ok - I've found that bit of code in the index.php file. Now what do I need to do?
__________________
http://www.smallestphoto.com/
Reply With Quote
  #5  
Old 01-31-2005, 01:00 PM
andy Offline
pp regular
 
Join Date: Dec 2004
Location: Minnesota, USA
Posts: 29
If I'm not mistaken, as long as you have the save cookie code at the top (below), it should be working.

// Set cookie for visitor counter, re-count a person after 60 mins
setcookie("lastvisit","expires in 60 minutes",time() +60*60);

// save user info if requested
if($_POST['vcookie'] == "set") {
$name = clean($_POST['name']);
$url = clean($_POST['url']);
setcookie("visitorinfo","$name%$url%l",time() +60*60*24*30); // save cookie 30 days
}
Reply With Quote
  #6  
Old 01-31-2005, 01:06 PM
Anonymous Offline
pixelpost guru
 
Join Date: Oct 2004
Posts: 810
That code is certainly there but it's not working. What about the code you mention you below your post - where should that be?
Reply With Quote
  #7  
Old 02-01-2005, 12:33 PM
andy Offline
pp regular
 
Join Date: Dec 2004
Location: Minnesota, USA
Posts: 29
It's very close to the top of your main index.php file.

Perhaps you don't have cookies turned on in your browser?
Reply With Quote
  #8  
Old 02-01-2005, 08:08 PM
biggest_apple Offline
pp regular
 
Join Date: Oct 2004
Posts: 32
Found the code. Still doesn't work though. It's not my browser. No ones details are being saved. You can take a peek:
www.smallestphoto.com
__________________
http://www.smallestphoto.com/
Reply With Quote
  #9  
Old 02-01-2005, 08:52 PM
andy Offline
pp regular
 
Join Date: Dec 2004
Location: Minnesota, USA
Posts: 29
You don't have the checkbox on your page to save info. If you want to bypass the checkbox, I think if you just remove the IF statement around the cookie save, it will save everybody whether they want it or not.

if($_POST['vcookie'] == "set") { //remove this line

...keep code inside the brackets

} //remove this end bracket

Let me know if it works. Nice site by the way!
Reply With Quote
  #10  
Old 02-01-2005, 08:54 PM
Anonymous Offline
pixelpost guru
 
Join Date: Oct 2004
Posts: 810
Well that just makes entirely too much sense!
Reply With Quote
Post Reply


Thread Tools




All times are GMT. The time now is 04:43 AM.

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd. | Style Design: d3 designs