|
| ← Entry 1559 | Entry 1561 → |

anonymous wrote:
Keith (http://www.keithdevens.com) wrote:
This is a test comment
testing (http://www.yahoo.com) wrote:
this is a test comment
blah (blah) wrote:
oeauoa
anonymous wrote:
testing
Matt (http://www.yaysoft.com) wrote:
Hey Keith, looks good so far.
Oh yeah, and thanks for the remark about my comments system... I've been busy setting up my new personal site and just got back around to checking your blog.
The only problem with my little system is that it only works in newer versions of IE. I know how to make it work in Mozilla, but I'm too lazy to fix it.
But I do like this discussion-thread style comments method you have going.
'Matt' ('http://www.yaysoft.com') wrote:
<center><b>testing HTML<i>!!!</i></b></center><br>
<br>
Test<br>
Again.
Matt (http://www.yaysoft.com/) wrote:
Aside from the crazy quote escaping errors, which I'm pretty sure you're well aware of, you might also want to throw in an nl2br()...
The Other Keith™ (http://hereticmessiah.weblogs.com/) wrote:
I've got a better function (you can rip it out of the common.php file in Slant-PHP if you want) called paragraphise() that I use in preference to nl2br(). Any chance of putting some whitespace between the comments or something?
Matt (http://www.yaysoft.com/) wrote:
<?php
echo "hopefully this won't work";
Keith (http://www.keithdevens.com/) wrote:
Yeah, in the hour or so I wrote the feature I forgot a lot of the nicities like making sure people don't break my HTML by adding their own, and using nl2br. I'll add those and a few other features later, like remembering your name, email, etc, in a cookie so you don't have to fill it out every time. I definitely would like to see your paragraphise function, Keith. Though I do have my own markup thing (http://www.keithdevens.com/weblog/?id1349), (http://www.keithdevens.com/weblog/?id1341) that would be perfect to use for the comments here, since it won't slow down my main weblog page. I've been meaning to check out Slant-PHP but haven't had a chance yet. Finally, in case any of you are worried about spam-bots getting your e-mail addresses from posting on my site, I encode them so it makes it a little less likely that they'll be harvested. Do a view source and you'll see what I mean.
Keith wrote:
testing
Keith wrote:
testing's with quotes '' " and stuff
The Other Keith™ (http://hereticmessiah.weblogs.com/) wrote:
Here's the code. I'm sure it'll get mangled, but hopefully not too badly. I've included setDefault 'cause it's just so small and incredibly useful. I must post my calendar code up on my website for you. I'll do that by the end of the week, I hope.
/**
* Converts any double newlines to <p> tags.
*
* $string String to paragraphise.
*
* @returns Paragraphised version of the string passed in.
*
* @author Keith Gaughan <kmgaughan@eircom.net>
* @version 0.1 (2001-01-22)
*/
function paragraphise($string)
{
// We need to be able to cope with dumb Windows browsers too.
if (strstr($string, "\r\n") != "")
return str_replace("\r\n\r\n", "\n<p>\n", $string);
return str_replace("\n\n", "\n<p>\n", $string);
}
/**
* Checks if $var is already defined and if not, sets it to $default.
*
* $var Variable to check.
* $default Value to give the checked variable if found to be null; "" by default.
* $catchNulls TRUE: treat empty strings as null; FALSE by default.
*
* @note It's a lot like ColdFusion's <CFPARAM> tag.
* @author Keith Gaughan <kmgaughan@eircom.net>
* @version 0.1 (2001-01-23)
*/
function setDefault(&$var, $default="", $catchNulls=false)
{
if (!isset($var) || ($catchNulls && $var == ""))
$var = $default;
}
Keith (http://www.keithdevens.com/) wrote:
Testing cookie. It should remember my name, e-mail, and website from now on.
a (a) wrote:
a
a (a) wrote:
a
a (a) wrote:
a
a (a) wrote:
a
a (a) wrote:
a
Keith (http://www.keithdevens.com/) wrote:
I tried to do the cookie and I broke it
Gotta fix it when I get back from school.
The Other Keith™ (http://hereticmessiah.weblogs.com/) wrote:
As far as the counter goes, you could cheat for now and add an extra field to the posts table to count how many comments are associated with it. I'm refitting Slant-PHP into a personal weblog right now and I'll be faced with the same problem when I have time to refit the comments section.
anonymous wrote:
testing
Keith (http://www.keithdevens.com/) wrote:
testing
Keith Devens (http://www.keithdevens.com/) wrote:
testing again
Keith (http://www.keithdevens.com/) wrote:
Cool, now it remembers your username and stuff that you put in last time.
Keith (http://www.keithdevens.com/) wrote:
This is a test... I'm trying to get it to send a cookie that won't expire when you close your browser.
Keith (http://www.keithdevens.com/) wrote:
Testing again. It won't remember my cookie stuff 
Keith - Testing (blah website) wrote:
Testing again
Keith (http://www.keithdevens.com/) wrote:
Testing again
Some Dude (http://dcortesi.com) wrote:
Testing cookies
Mishka (http://www.mishka.com/) wrote:
Mishka rules !
Feel free to post a comment below. Please see my comment policy.
Formatting Rules (No HTML):
Generated in about 0.189s.
(Used 8 db queries)

aoueaoeu