changing ucp.php breaks anti-spam question on registration

Get help with installation and running phpBB 3.2.x here. Please do not post bug reports, feature requests, or extension related questions here.
Post Reply
Rand0mer
Registered User
Posts: 14
Joined: Fri Nov 13, 2015 2:30 pm

changing ucp.php breaks anti-spam question on registration

Post by Rand0mer » Wed May 15, 2019 12:27 am

As title says, i was careful to only change information within the ToS section of ucp.php yet when I do this the anti-spam image doesnt show, this is the same for all plugins. the text & submit section show but the anti-spam image does not.

any work around?

thanks

User avatar
Lumpy Burgertushie
Registered User
Posts: 66724
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: changing ucp.php breaks anti-spam question on registration

Post by Lumpy Burgertushie » Wed May 15, 2019 12:40 am

need a little more info. what exactly did you change and why?

please show us the exact code you changed in that file.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

If a tree falls in the forest and nobody is there, does it make a sound?

User avatar
EA117
Registered User
Posts: 899
Joined: Wed Aug 15, 2018 3:23 am
Contact:

Re: changing ucp.php breaks anti-spam question on registration

Post by EA117 » Wed May 15, 2019 12:50 am

I am assuming, but you need to confirm, that you made changes to /language/<iso639-1>/ucp.php in order to make changes to the TOS content. And not that you're making logic changes to the TOS process through /ucp.php at the root of the board.

It would be easy to introduce a syntax error into the language module such that the parsing of that file fails or is joining together strings which shouldn't be joined together. I think you're going to have to post what your complete TERMS_OF_USE_CONTENT and PRIVACY_POLICY definitions look like now, including the surrounding invocation of array_merge() that adds these values to the main $lang array.

Also make sure you're using a capable editor such as Notepad++ or similar, which will maintain the UTF-8 encoding and the fact that no byte order mark is placed on the file.

Code: Select all

// Privacy policy and T&C
$lang = array_merge($lang, array(
	'TERMS_OF_USE_CONTENT'	=> 'By accessing “%1$s” (hereinafter “we”, “us”, “our”, “%1$s”, “%2$s”), you agree to be legally bound by the following terms. If you do not agree to be legally bound by all of the following terms then please do not access and/or use “%1$s”. We may change these at any time and we’ll do our utmost in informing you, though it would be prudent to review this regularly yourself as your continued usage of “%1$s” after changes mean you agree to be legally bound by these terms as they are updated and/or amended.<br />
	<br />
	Our forums are powered by phpBB (hereinafter “they”, “them”, “their”, “phpBB software”, “www.phpbb.com”, “phpBB Limited”, “phpBB Teams”) which is a bulletin board solution released under the “<a href="http://opensource.org/licenses/gpl-2.0.php">GNU General Public License v2</a>” (hereinafter “GPL”) and can be downloaded from <a href="https://www.phpbb.com/">www.phpbb.com</a>. The phpBB software only facilitates internet based discussions; phpBB Limited is not responsible for what we allow and/or disallow as permissible content and/or conduct. For further information about phpBB, please see: <a href="https://www.phpbb.com/">https://www.phpbb.com/</a>.<br />
	<br />
	You agree not to post any abusive, obscene, vulgar, slanderous, hateful, threatening, sexually-orientated or any other material that may violate any laws be it of your country, the country where “%1$s” is hosted or International Law. Doing so may lead to you being immediately and permanently banned, with notification of your Internet Service Provider if deemed required by us. The IP address of all posts are recorded to aid in enforcing these conditions. You agree that “%1$s” have the right to remove, edit, move or close any topic at any time should we see fit. As a user you agree to any information you have entered to being stored in a database. While this information will not be disclosed to any third party without your consent, neither “%1$s” nor phpBB shall be held responsible for any hacking attempt that may lead to the data being compromised.
	',

	'PRIVACY_POLICY'		=> 'This policy explains in detail how “%1$s” along with its affiliated companies (hereinafter “we”, “us”, “our”, “%1$s”, “%2$s”) and phpBB (hereinafter “they”, “them”, “their”, “phpBB software”, “www.phpbb.com”, “phpBB Limited”, “phpBB Teams”) use any information collected during any session of usage by you (hereinafter “your information”).<br />
	<br />
	Your information is collected via two ways. Firstly, by browsing “%1$s” will cause the phpBB software to create a number of cookies, which are small text files that are downloaded on to your computer’s web browser temporary files. The first two cookies just contain a user identifier (hereinafter “user-id”) and an anonymous session identifier (hereinafter “session-id”), automatically assigned to you by the phpBB software. A third cookie will be created once you have browsed topics within “%1$s” and is used to store which topics have been read, thereby improving your user experience.<br />
	<br />
	We may also create cookies external to the phpBB software whilst browsing “%1$s”, though these are outside the scope of this document which is intended to only cover the pages created by the phpBB software. The second way in which we collect your information is by what you submit to us. This can be, and is not limited to: posting as an anonymous user (hereinafter “anonymous posts”), registering on “%1$s” (hereinafter “your account”) and posts submitted by you after registration and whilst logged in (hereinafter “your posts”).<br />
	<br />
	Your account will at a bare minimum contain a uniquely identifiable name (hereinafter “your user name”), a personal password used for logging into your account (hereinafter “your password”) and a personal, valid email address (hereinafter “your email”). Your information for your account at “%1$s” is protected by data-protection laws applicable in the country that hosts us. Any information beyond your user name, your password, and your email address required by “%1$s” during the registration process is either mandatory or optional, at the discretion of “%1$s”. In all cases, you have the option of what information in your account is publicly displayed. Furthermore, within your account, you have the option to opt-in or opt-out of automatically generated emails from the phpBB software.<br />
	<br />
	Your password is ciphered (a one-way hash) so that it is secure. However, it is recommended that you do not reuse the same password across a number of different websites. Your password is the means of accessing your account at “%1$s”, so please guard it carefully and under no circumstance will anyone affiliated with “%1$s”, phpBB or another 3rd party, legitimately ask you for your password. Should you forget your password for your account, you can use the “I forgot my password” feature provided by the phpBB software. This process will ask you to submit your user name and your email, then the phpBB software will generate a new password to reclaim your account.<br />
	',
));
Last edited by EA117 on Wed May 15, 2019 12:53 am, edited 1 time in total.

Rand0mer
Registered User
Posts: 14
Joined: Fri Nov 13, 2015 2:30 pm

Re: changing ucp.php breaks anti-spam question on registration

Post by Rand0mer » Wed May 15, 2019 12:53 am

I removed the standard ToS you see upon registration and replaced it with my own few rules.

I specificcally remove what goes between..

'TERMS_OF_USE_CONTENT' => ' TOS GOES HERE ',));

it did updated my ToS correctly however the anti spambot image wasnt happy.

Rand0mer
Registered User
Posts: 14
Joined: Fri Nov 13, 2015 2:30 pm

Re: changing ucp.php breaks anti-spam question on registration

Post by Rand0mer » Wed May 15, 2019 12:55 am

yes i made changes to language/en/ucp.php

User avatar
EA117
Registered User
Posts: 899
Joined: Wed Aug 15, 2018 3:23 am
Contact:

Re: changing ucp.php breaks anti-spam question on registration

Post by EA117 » Wed May 15, 2019 12:59 am

Rand0mer wrote:
Wed May 15, 2019 12:53 am
'TERMS_OF_USE_CONTENT' => ' TOS GOES HERE ',));
Any chance of showing what the actual edit looks like now? The syntax above doesn't look right, but it's not a complete snippet of code, either. The entire array_merge() appending to the $lang array would be easiest to show (like I did in my post), if you want to solve the issue more quickly without playing a game of twenty questions.

Note the TERMS_OF_USE_CONTENT cannot be made blank (i.e. simply removed completely), but it sounds like that's not what you did.

Rand0mer
Registered User
Posts: 14
Joined: Fri Nov 13, 2015 2:30 pm

Re: changing ucp.php breaks anti-spam question on registration

Post by Rand0mer » Wed May 15, 2019 1:03 am

Using Sublime editor instead of notepad seems to have solved the issue, but thanks for your quick response.

User avatar
EA117
Registered User
Posts: 899
Joined: Wed Aug 15, 2018 3:23 am
Contact:

Re: changing ucp.php breaks anti-spam question on registration

Post by EA117 » Wed May 15, 2019 1:08 am

Rand0mer wrote:
Wed May 15, 2019 1:03 am
Using Sublime editor instead of notepad seems to have solved the issue, but thanks for your quick response.
Perfect. Standard Microsoft Notepad does know how to maintain UTF-8 encoding, but I believe it also puts a byte order mark at the start of the file when doing so. The entire language module was probably being ignored after editing with Notepad. Glad you found the solution.

Post Reply

Return to “[3.2.x] Support Forum”