AARoads Forum

Meta => Suggestions and Questions => Topic started by: freebrickproductions on February 16, 2016, 03:04:12 PM

Title: Forum Glitch when viewing profile?
Post by: freebrickproductions on February 16, 2016, 03:04:12 PM
I've noticed today that when viewing someone's profile (such as mine (https://www.aaroads.com/forum/index.php?action=profile;u=12695), for example), there's this string at the very top of the page:
Quote// Begin SMF Gallery $txt['whoall_gallery'] = 'In the Gallery'; // END SMF Gallery Strings

Any reason as to why that's showing up?
Title: Re: Forum Glitch when viewing profile?
Post by: hotdogPi on February 16, 2016, 03:11:22 PM
In some programming languages, two slashes in a row mean a comment, which means the program is not supposed to execute that code, and it is meant for the user to read while viewing code (usually to make it clearer). However, we still should not be able to see it.
Title: Re: Forum Glitch when viewing profile?
Post by: freebrickproductions on February 16, 2016, 03:15:10 PM
Quote from: 1 on February 16, 2016, 03:11:22 PM
In some programming languages, two slashes in a row mean a comment, which means the program is not supposed to execute that code, and it is meant for the user to read while viewing code (usually to make it clearer). However, we still should not be able to see it.
I noticed that they looked like comments, as C++ uses that to comment lines out. I'm not sure how php code works though.
Title: Re: Forum Glitch when viewing profile?
Post by: Thing 342 on February 16, 2016, 03:21:26 PM
That looks like some code that was accidentally left out of the <?php ?> brackets. I believe it was meant to set sort of page header variable, but I'm not familiar with SMF. 
Title: Re: Forum Glitch when viewing profile?
Post by: rickmastfan67 on February 16, 2016, 05:07:32 PM
I'll look into this.
Title: Re: Forum Glitch when viewing profile?
Post by: rickmastfan67 on February 16, 2016, 05:19:02 PM
Has been fixed.  A new mod Alex installed this morning didn't properly put it's info in the right place (it put it after a '?>' instead of before it).  I've manually fixed it in the PHP files.

So, this problem should no longer happen. :)