Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-9162

BBCode in poll options is broken, when posting without question.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 3.0.7-PL1
    • Fix Version/s: 3.0.8-RC1
    • Component/s: Posting
    • Labels:
      None
    • Environment:
      PHP Environment: 5.3.1
      Database: 5.1.41

      Description

      This is an issue where the bbcode is broken in the poll options section when using preview.

      I had a hard time recreating the issue but finally I realized it ONLY happens when you have everything filled out except for the 'Poll Question". I filled out the post subjest, the post itself, and the poll options but not the poll question and this error happens. It seems to only happen in this situation.

      The input is:

      [url=http://www.test.com]test[/url]
      [b]Bold[/b]
      [i]Italic[/i]

      When you hit preview, it turns into:

      [url=http://www.test.com:3uzt04m0]test[/url:3uzt04m0]
      [b:3uzt04m0]Bold[/b:3uzt04m0]
      [i:3uzt04m0]Italic[/i:3uzt04m0]

      Again, this only happens when everything is filled out except the poll question.

      Typo

        Activity

        Hide
        nickvergessen Joas Schilling added a comment -

        should be quite easy to fix.
        posting.php about line 1274:
        find:

        if (sizeof($post_data['poll_options']) && $post_data['poll_title'])

        replace with

        if (sizeof($post_data['poll_options']) || $post_data['poll_title'])

        Show
        nickvergessen Joas Schilling added a comment - should be quite easy to fix. posting.php about line 1274: find: if (sizeof($post_data['poll_options']) && $post_data['poll_title']) replace with if (sizeof($post_data['poll_options']) || $post_data['poll_title'])
        Hide
        bantu Andreas Fischer added a comment - - edited

        Fix is incomplete, I get the following when creating a new topic (http://localhost/projects/phpbb3/phpBB/posting.php?mode=post&f=2)

        [phpBB Debug] PHP Notice: in file /posting.php on line 1303: Undefined index: poll_title

        Show
        bantu Andreas Fischer added a comment - - edited Fix is incomplete, I get the following when creating a new topic ( http://localhost/projects/phpbb3/phpBB/posting.php?mode=post&f=2 ) [phpBB Debug] PHP Notice: in file /posting.php on line 1303: Undefined index: poll_title
        Hide
        bantu Andreas Fischer added a comment -

        Ticket got unassigned by accident (possibly a JIRA bug).

        Show
        bantu Andreas Fischer added a comment - Ticket got unassigned by accident (possibly a JIRA bug).
        Hide
        bantu Andreas Fischer added a comment -

        Needs regression fix.

        Show
        bantu Andreas Fischer added a comment - Needs regression fix.
        Hide
        igorw Igor Wiedler [X] (Inactive) added a comment -

        Fixed the regression.

        Show
        igorw Igor Wiedler [X] (Inactive) added a comment - Fixed the regression.

          People

          • Assignee:
            igorw Igor Wiedler [X] (Inactive)
            Reporter:
            typos typos
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development