Page 1 of 2

Commenting of guestbook entries + smileybox?

Posted: Thu Jun 29, 2006 9:20 pm
by Harald Weingaertner
Hello,

i've read about the guestbook plugin and someone wished to chance to comment guestbook entries (garvin, not adding a new comment above ;) ).

This is a new try to find someone who can extend the guestbook script :)

Is someone able to add an option to comment and edit entries?

A box, where users can click on a smiley to show in their comment would also be fine. ;)

Regards, Harald

Re: Commenting of guestbook entries + smileybox?

Posted: Fri Jun 30, 2006 7:54 am
by garvinhicking
Hi!

Why not use a simple blog entry then, where "comments" are just usual guestbook entries? This seems like the perfect solution for you.

Best regards,
Garvin

Posted: Fri Jun 30, 2006 4:31 pm
by Harald Weingaertner
Well, this sounds not bad.... Really not bad. I will think about it and try it out. Thanks!

Posted: Sun Jul 02, 2006 12:13 am
by Harald Weingaertner
I thought about it and it isn't that good...

Entries should be sorted "Newest at the top" in the "Guestbook Entry" and "Comment" (or german "Kommentar schreiben") should be called "In das Gästebuch eintragen" ;)

So it will not work this way. :(

Posted: Sun Jul 02, 2006 8:59 pm
by garvinhicking
Hi!

That's a good suggestion; I just added two new parameters to the "serendipity_printComments" smarty function.

Via the "order" parameter you can put "DESC" in it to order reversed.

So in your entries.tpl template you could make this check:

Code: Select all

{if $entry.title == 'Guestbook'}
  {serendipity_printComments entry=$entry.id mode=$entry.viewmode order="DESC"}
{else}
  {serendipity_printComments entry=$entry.id mode=$entry.viewmode}
{/if}
With the same IF-statement you can emit "Submit to guestbook" instead of $CONST.SUBMIT_COMMENT or something like that. :)

Best regards,
Garvin

Posted: Sun Jul 02, 2006 9:33 pm
by Harald Weingaertner
Great, i will try it!

Posted: Wed Jul 05, 2006 6:26 pm
by Harald Weingaertner
Well, i tried it and nothing changed. Do i have to update something first?

I have replaced

{serendipity_printComments entry=$entry.id mode=$entry.viewmode}

with

{if $entry.title == 'Guestbook'}
{serendipity_printComments entry=$entry.id mode=$entry.viewmode order="DESC"}
{else}
{serendipity_printComments entry=$entry.id mode=$entry.viewmode}
{/if}

in my entries.tpl and created a new entry named Guestbook. I guess i missed one step?

Regards, Harald

Posted: Wed Jul 05, 2006 9:45 pm
by garvinhicking
Hi!

You did download the latest snapshot? The patch to that function should be contained in yesterday's nightly...?

Which nightly are you using?

Best regards,
Garvin

Posted: Wed Jul 05, 2006 9:50 pm
by Harald Weingaertner
garvinhicking wrote:Hi!

You did download the latest snapshot? The patch to that function should be contained in yesterday's nightly...?

Which nightly are you using?
Ah, ok :( I use 1.0final, not one of the nightlys. Is it recommended to use the nightly builds on a live site? My understanding is, that all those nightlys are betas of 1.1...

Maybe i don't understand "nightly" correct.

Posted: Wed Jul 05, 2006 9:54 pm
by garvinhicking
Hi!
Ah, ok :( I use 1.0final, not one of the nightlys. Is it recommended to use the nightly builds on a live site? My understanding is, that all those nightlys are betas of 1.1...
Oh, okay. Then you overread my statement that your wish was a feature request that I needed to add to the code. :)

Since the 1.1 release isn't that far away, I try not to backport too much code to 1.0 and instead focus on getting 1.1 nicer. :)

I myself am running nightlies on my live-site, and there are no open bugs in 1.1 that I am aware of, so actually 1.1 might be worth a try.

Best regards,
Garvin

Posted: Fri Aug 04, 2006 7:00 pm
by Harald Weingaertner
Garvin, i managed it finally to check this out. Of course, it works fine.

Is it possible to name the article "Gästebuch"? The statement

{if $entry.title == 'Gästebuch'}

does not seem to work (because of the ä maybe?)

Also can you assist me again, where i have to change this?

With the same IF-statement you can emit "Submit to guestbook" instead of $CONST.SUBMIT_COMMENT or something like that.

I use the yesterdays nightly right now.

Thanks again!

Posted: Sat Aug 05, 2006 10:32 pm
by garvinhicking
Hi!

If your blog is running in UTF-8 charset, you need to save your .tpl file in UTF-8 as well if you make such a special character comparement!

Best regards,
Garvin

Posted: Sat Aug 05, 2006 11:11 pm
by Harald Weingaertner
Thanks Garvin,

and could you kindly explain where i have to change

With the same IF-statement you can emit "Submit to guestbook" instead of $CONST.SUBMIT_COMMENT or something like that.
Regards, Harald

Posted: Sat Aug 05, 2006 11:13 pm
by garvinhicking
Hi!

Yes, instaead of $CONST.SUBMIT_COMMENT you simply place "Submit to guestbook". :-)

Best regards,
Garvin

Posted: Tue Aug 08, 2006 12:17 am
by Harald Weingaertner
Garvin, sorry again. I cannot find the string $CONST.SUBMIT_COMMENT in entries.tpl.

I guess, entries.tpl is not the right place to search, right?