Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added an event to viewtopic.php to modify template vars. #3288

Closed
wants to merge 1 commit into from

Conversation

DerDave
Copy link

@DerDave DerDave commented Jan 12, 2015

[feature/event](This is my first pull requst, I hope I don't screw this up)
I added an event to viewtopic.php tomodify the template vars as described in the ticket.

PHPBB3-13480

* @var int forum_id Forum ID
* @var array topic_data Array with topic data
* @var int topic_id Topic ID
* @var int total_posts Topic total posts count
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$total_posts doesn't exist in the vars array below.

@marc1706
Copy link
Member

Please modify your commit message to fit into this format: https://wiki.phpbb.com/Git#Commit_Messages

@nickvergessen nickvergessen modified the milestone: 3.1.4 Jan 12, 2015
@DerDave
Copy link
Author

DerDave commented Jan 12, 2015

How do I do this? Should I simpl make this pull request again?

regards, Dave

@nickvergessen
Copy link
Contributor

If you use the console, try git commit --amend

@DerDave
Copy link
Author

DerDave commented Jan 12, 2015

No, I use Tortoise... So ist it okay, to just start another pull request.

What exactly is wrong with the commit message? I tried to use the mentioned format?

What are "consecutive new lines"? Two blank lines?

@rxu
Copy link
Contributor

rxu commented Jan 12, 2015

With TortoiseGit it's even simplier - just choose Git Commit -> "develop", then check the "Amend last commit" checkbox, edit the commit message and then perform commit, then make "Git Sync..." having the "Force" checkbox checked.

@nickvergessen
Copy link
Contributor

What exactly is wrong with the commit message? I tried to use the mentioned format?

it should be

[ticket/13480] Added an event to viewtopic.php to modify template vars.

PHPBB3-13480

What are "consecutive new lines"? Two blank lines?

yes

@DerDave
Copy link
Author

DerDave commented Jan 13, 2015

So... I tried again...

'topic_data',
'topic_id',
);
extract($phpbb_dispatcher->trigger_event('core.viewtopic_assign_template_vars', compact($vars)));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should have the same event name as in the docblock above.

@nickvergessen
Copy link
Contributor

@DerDave want to try fixing this, or shall we take it over?

@DerDave
Copy link
Author

DerDave commented Feb 3, 2015

Sorry, I've just accepted a new job... I don't have much time right now....

@marc1706
Copy link
Member

marc1706 commented Feb 4, 2015

Replaced by #3368

@marc1706 marc1706 closed this Feb 4, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants