-
Notifications
You must be signed in to change notification settings - Fork 63
Convert login, logout and statistics pages to templates #83
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
Conversation
| <a href="/stats.php">statistics</a> | | ||
| <a href="/random">random bug</a> | | ||
| <?php if ($authIsLoggedIn): ?> | ||
| <?php if (isset($authIsLoggedIn) && $authIsLoggedIn): ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor nit; We can use PHP7 syntax on bugs.php.net, so how about:
if ($authIsLoggedIn ?? false):
More concise and avoids repeating the varname.
|
Overall, I'm not a fan of the template file approach of assuming vars in the global scope. It makes tracing the lifetime of a variable much more difficult. -1 |
Vars are not in the global scope though. They are specifically passed into the template. Are you perhaps confusing it with the old way where everything was indeed in the global scope? Or am I missing what you are trying to say? |
|
ping @sgolemon |
|
IMO, this is much cleaner than the old code (and yes, there are no global variables). |
| <?php $this->start('content') ?> | ||
|
|
||
| <?php if ($invalidLogin): ?> | ||
| <div style="background: #AB1616; padding: 3px; width: 300px; color: #FFF; margin: 3px;"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There should be a CSS class used for displaying error messages.
|
What's the status here? Maybe we should seriously consider to retire bugsnet in favor of something else? |
|
Well, PHP's web-bugs requires a lot of fixes and improvements. Switching to something else may solve a good portion of current 'not fun' things, but may also add new problems like:
I saw several tries in the open source world where migrations got stuck and still runs the old ugly but at least somehow working solution. disclosure 1: I am not part of PHP Group, just a dude who uses PHP. |
|
bugs.php.net is no longer really used, and hence, we're sunsetting it. Due to that, I don't think it makes sense to merge this patch, which also has conflicts. |
|
Oh, right, further improvements to the bug tracker (especially refactorings) won't make sense anymore. |
I converted 3 pages to use templates:
Next up would be the report-a-bug page, but that needs some more thought as there is a lot going on on that page.