Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: 1 [2] 3 4   Go Down

Author Topic: integrating Viper Guestbook X1  (Read 223361 times)

0 Members and 1 Guest are viewing this topic.

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #20 on: June 25, 2006, 06:26:59 pm »

I'm having trouble following. Does the guestbook work by itself? Could you post a link to the gallery?
Logged

gangavalli

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: integrating Viper Guestbook X1
« Reply #21 on: June 25, 2006, 06:32:39 pm »

Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #22 on: June 25, 2006, 06:44:31 pm »

The problem occurs when the guestbook is standalone: http://familyalbum.gangavalli.com/photos/guestbook/

Since it's not related to the integration itself, I don't know what's going on. You will need to ask the guestbook author at http://www.vipergb.de.vu/

I did a search for the missing table name and didn't see a post on it.
Logged

gangavalli

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: integrating Viper Guestbook X1
« Reply #23 on: June 26, 2006, 11:00:59 pm »

The guestbook is not standalone. I installed using the viper install php file only.
I have asked the guestbook author about the error.
This is the thread: http://www.danskcinders.com/forum/viewtopic.php?t=369
The table exists but there is another problem now. 

after posting the content, there is an error:
Code: [Select]
The following MySQL query produced an error:
select COMMENTEMAIL, ENTRYSENT from VGB_ADMIN where COMMENTEMAIL != ''

1054: Unknown column 'ENTRYSENT' in 'field list'

how can i sort this?
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #24 on: July 01, 2006, 08:06:36 am »

Hmm, this looked really interesting, but neither the support forums or the Viper site to download it are working. Is it gone?
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #25 on: July 01, 2006, 08:58:13 am »

Sorry, I should have updated the forum location, which is here: http://www.danskcinders.com/forum/viewforum.php?f=1

I just went to http://www.vipergb.de.vu/ and it worked fine.
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #26 on: July 01, 2006, 04:44:48 pm »

It works for me too now, but just timed out the past few days.

Thanks for the updated forum link. I had read elsewhere that development had stopped, but I see from the forum it is still active.
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #27 on: July 04, 2006, 10:30:03 pm »

I had the same troubles as Granis along with other errors. I noticed that you have a mix of short and long php tags, which I dont allow. Also, a few of the files I had to load in wordpad and save as text to remove some extra characters. After that, it seems to be working ok. Thanks for the skin and howto.
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #28 on: July 31, 2006, 05:20:31 am »

Hi TranzNDance,

I thought I had this all working and then put off implementing the guestbook until now. But some final testing has revealed a problem with apostrophes. For example, if I type "it's" in the guestbook it becomes it's or in html code, ' replaces the apostrophe instead of '

I don't believe it's the apostrophe problem mentioned in other topics since they work find in titles, etc. Only in the guestbook do I have the problem.

If I run the guestbook as standalone with the standard skin, it works ok, the ' is encoded as ' so it seems like a problem with the skin, or interaction with coppermine.

I checked out the guestbook on your site and saw the same problem. Any ideas on how I can fix this?

Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #29 on: July 31, 2006, 06:21:16 am »

Yeah, I think it has to do with the guestbook being included in Coppermine. If I use the Standard Skin while included, I have the same issue. Only when using Standard Skin while standalone do I not have the issue. And the issue occurs when the entry gets saved into the database. If I edit the entry in admin panel, the apostrophes are ok.

Looking in include/init.inc.php, I see sanitizing activity:
Code: [Select]
$HTML_SUBST = array('&' => '&amp;', '"' => '&quot;', '<' => '&lt;', '>' => '&gt;', '%26' => '&amp;', '%22' => '&quot;', '%3C' => '&lt;', '%3E' => '&gt;','%27' => '&#39;', "'" => '&#39;');

I couldn't figure a more clever solution than editing the guestbook index.php file.

FIND:
Code: [Select]
echo vgb_outText($entry['ENTRY']
REPLACE with:
Code: [Select]
echo html_entity_decode(vgb_outText($entry['ENTRY']));
My guestbook looks so much neater now. :D

Thanks for reporting the problem and providing some troubleshooting info. I've heard about this before but didn't know where to begin looking. Plus, I was in code mode today.
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #30 on: July 31, 2006, 05:23:57 pm »

Glad I could help, but I still have problems. I guess you're still using X1.0 since I don't have that code in my index.php. That's from the EntryText function? That's the only place I found similar code. In 1.1 and 1.2RC1 it looks like
Code: [Select]
  function EntryText() {
    // prints the text of the current entry
    global $entry,$vgbcache;

    $t = ($vgbcache) ? vgb_emofix($entry['ENTRY']) : vgb_outText($entry['ENTRY']);
    echo "<span class='vgbtext'>".$t."</span>";
  }

Your change only cleans up the output right, not what goes into the database?
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #31 on: July 31, 2006, 05:37:38 pm »

Try this:
Code: [Select]
  function EntryText() {
    // prints the text of the current entry
    global $entry,$vgbcache;

    $t = ($vgbcache) ? vgb_emofix($entry['ENTRY']) : vgb_outText($entry['ENTRY']);
    $t = html_entity_decode($t);
    echo "<span class='vgbtext'>".$t."</span>";
  }

Yes, it will only clean up the output, since the input is being sanitized for security purposes.
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #32 on: July 31, 2006, 07:49:23 pm »

That works, but not if I preview the comment. I mean the preview part looks ok, but in the comment entry box it again has the &amp;#39 so if I then submit the comment, it is messed up.

 :-\
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #33 on: August 01, 2006, 06:12:07 am »

Sorry, I should have tested with preview.

I don't know if your version has this code, but search for it or similar:
Code: [Select]
    out("<textarea name='".PFIX."TEXT' $inTag>");
    if (isset($_entry['ENTRY']))
      echo vgb_formdata($_entry['ENTRY']);
    echo "</textarea>";

It is in function FormText() in index.php

Change:
Code: [Select]
echo vgb_formdata($_entry['ENTRY']);
to:
Code: [Select]
echo html_entity_decode(vgb_formdata($_entry['ENTRY']));
Logged

wuurp

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 26
Re: integrating Viper Guestbook X1
« Reply #34 on: August 01, 2006, 08:53:27 am »

Thanks, that took care of it.
Logged

piterve

  • Coppermine newbie
  • Offline Offline
  • Posts: 1
Re: integrating Viper Guestbook X1
« Reply #35 on: August 17, 2006, 03:40:22 am »

I'm using cpg1.4 and ViperX1..

Whitout the CoppermineX1 theme, the guestbook works fine.. But with the theme switched on, there is no entrys or anyway to make one.

Have a look.

http://granis.bounceme.net/cpg146/guestbook.php

   Pardon my very bad english. Coppermine Skin  Revision: X1.0 downloaded of http://www.vipergb.de.vu/ is missing 7 archives, compared with the standard skin:
contentFrame.php, displayFrameset.php, mainFrameset.php, menuframe.php, screencss.php, selectFrame.php and skincss.php.

   To recover the error download the Standard Skin Revision: X1.1.0 , extract it and copy all archives in the coppermine skin (important: no overwrite the coppermine skin archives !!, take no overwrite to all). Is all, the problem is solved and the visual integration is Ok and the guestbook in now visible.

Thans
Piter
Logged

claude258

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 150
    • Album photos Brière
Re: integrating Viper Guestbook X1
« Reply #36 on: October 09, 2006, 03:29:55 pm »

Sorry, I should have tested with preview.

I don't know if your version has this code, but search for it or similar:
Code: [Select]
    out("<textarea name='".PFIX."TEXT' $inTag>");
    if (isset($_entry['ENTRY']))
      echo vgb_formdata($_entry['ENTRY']);
    echo "</textarea>";

It is in function FormText() in index.php

Change:
Code: [Select]
echo vgb_formdata($_entry['ENTRY']);
to:
Code: [Select]
echo html_entity_decode(vgb_formdata($_entry['ENTRY']));

I also have the same problem with apostrophe and I tried to change the index.php code as you suggested but it doesnt seems work.

link:
http://claudebriere.net/coppermine/guestbook.php

Is there something I dont understand?

For your info, here is the answer about this problem from Marc from Viper forum:
Quote
That happens if your gb and your MAINSCRIPT are using different encodings. Oviously you fixed it yourself.

Regards,
Marc

Thanks
claude
Logged

singaporemall

  • Coppermine newbie
  • Offline Offline
  • Posts: 4
Re: integrating Viper Guestbook X1
« Reply #37 on: October 09, 2006, 03:36:42 pm »

That's very nice, Now I'll consider installing Viper Guestbook

Singapore Mall
www.singaporemall.in/gallery :)
Logged

Tranz

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Female
  • Posts: 6149
Re: integrating Viper Guestbook X1
« Reply #38 on: October 09, 2006, 04:30:15 pm »

Claude, could you please post the code that you have? Are you sure that when you uploaded the new version overwrote the old?

I don't think you followed all the integration steps. Your guestbook doesn't match the eyeball theme you are using. Here is my guestbook with eyeball: http://takethu.com/guestbook.php?theme=eyeball
Logged

claude258

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 150
    • Album photos Brière
Re: integrating Viper Guestbook X1
« Reply #39 on: October 09, 2006, 11:34:45 pm »

Hi TranzNDance,

I was using the ''standard skin'' in the guestbook setup. It is now switched to "Coppermine X1 skin" but the problem is also there. should it be fixed with your code modification (applied earlier)?

Please note that this problem is only when we write a new message. If we add a comment to a message it is fine.

If you have any comments let me know, I will try to see if I can find the problem.

link:
http://claudebriere.net/coppermine/guestbook.php

Thanks.
Claude   
Logged
Pages: 1 [2] 3 4   Go Up
 

Page created in 0.029 seconds with 19 queries.