Welcome to Geeklog, Anonymous Tuesday, October 04 2022 @ 06:20 am EDT

Geeklog Forums

Bug in polls (bug tracker down...)


darkpaw

Anonymous
artistic
The "Report a Bug" link on the left is broken - can't find /tracker/.

When you view a poll's results, any poll option comment (the text below the result bar) has a backslash in front of apostrophes. Perhaps a stripslashes() would help here?
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
I couldn't reproduce this. Anyone else?

Is this after an upgrade from an older version or does it happen with newly submitted comments? If so, what about comments in other places (stories, some other plugin)? Do they show the extra backslashes there, too?

bye, Dirk
 Quote

darkpaw

Anonymous
This is a fresh install, both Geeklog and my database. (My webhost had a catastrophic disk failure and the backups were fried, too.) If it helps, this is a Linux box, with PHP 5.1.4 and MySQL 4.1.21-standard.

Every time I save the poll, a fresh set of backslashes is added. Here's some poll results you can look at: http://www.darkpaw.co.uk/polls/index.php?qid=20070419091616350&aid=-1

It does not happen when comments are added or displayed.

Thanks!
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by: darkpaw

It does not happen when comments are added or displayed.


Ah, I was looking the wrong place then. Still can't reproduce it when I edit the poll, though.

Does it only happen with the "remark" field? What about the actual answers?

bye, Dirk
 Quote

tokyoahead

Anonymous
I can reproduce it on my running 1.4.1. It happens only in the remarks, not in the actual poll questions.

This is fixed in CVS already however, no need for action.
 Quote

darkpaw

Anonymous
cheerful
Quote by: tokyoahead

This is fixed in CVS already however, no need for action.


If you could give me the fix, I can update my site. Thanks!
 Quote

tokyoahead

Anonymous
give me some time for that one, the current CVS code has been changed completely, and there is no "fix" I can copy out for you.
I have to go to the current files and see where the issue is there. Maybe I can get you something in 24hrs or so.
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by: tokyoahead

I have to go to the current files and see where the issue is there. Maybe I can get you something in 24hrs or so.


I'd also like to see a fix for the 1.4.1-1 branch, please Mr. Green

bye, Dirk
 Quote

tokyoahead

Anonymous
In /public_html/admin/plugin/polls/index.php around line 143 after

Text Formatted Code

    for ($i = 0; $i < sizeof ($A); $i++) {
        $A[$i] = COM_stripslashes ($A[$i]);
    }
 

add
Text Formatted Code

    for ($i = 0; $i < sizeof ($R); $i++) {
        $R[$i] = COM_stripslashes ($R[$i]);
    }
 


HTH.
 Quote

Nice one!

Anonymous
excited
Thanks for that!
 Quote

All times are EDT. The time is now 06:20 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content