Force Flag on Register

Support for mods released by phpbbmodders.net found at either https://github.com/phpbbmodders/ or the MODDB at http://www.phpbb.com
Forum rules
Please only request support for mods released by phpbbmodders.net found at either https://github.com/phpbbmodders/ or the MODDB at http://www.phpbb.com
doktornotor
Member
Member
Posts: 98
Joined: 08 Nov 2011, 22:22
Contact:

Re: Force Flag on Register

Post by doktornotor »

Cool, works nicely. :cheers:
Support requests via PM go straight to /dev/null!
LynxTalk
New member
New member
Posts: 3
Joined: 22 Nov 2011, 16:21

Re: Force Flag on Register

Post by LynxTalk »

Is it possible to force the members too choose flag when they have logged in? (Have many members that don't change there profile so often)

Great MOD, Thanks! :rock:
User avatar
RMcGirr83
Supporter
Supporter
Posts: 6242
Joined: 30 Nov 2006, 14:23
Real name: Rich McGirr

Re: Force Flag on Register

Post by RMcGirr83 »

You can do like what is done on here and have a message displayed.

OPEN

includes/functions.php

Find This may be a partial find and not the whole line

Code: Select all

'S_NEW_PM'            => ($s_privmsg_new) ? 1 : 0,


Add after Add these lines on a new blank line after the preceding line(s) to find

Code: Select all

'S_FLAG'            => (empty($user->data['user_flag']) && $user->data['is_registered'] && !$user->data['is_bot']) ? false : true,
'U_PROFILE_PROFILE'      => append_sid("{$phpbb_root_path}ucp.$phpEx", 'i=profile'),


OPEN

styles/prosilver/template/overall_header.html

Find This may be a partial find and not the whole line

Code: Select all

                 <span class="corners-bottom"><span></span></span></div>
              </div>
              <!-- ENDIF -->


Add after Add these lines on a new blank line after the preceding line(s) to find

Code: Select all

            <!-- IF not S_FLAG and SCRIPT_NAME neq 'ucp'-->
            <div id="information_flags" class="rules">
                 <div class="inner"><span class="corners-top"><span></span></span>
                    <strong>{L_INFORMATION}:</strong> Please take a moment to visit <a href="{U_PROFILE_PROFILE}">your profile</a> and choose a country flag.  Thanks.
                 <span class="corners-bottom"><span></span></span></div>
              </div>
              <!-- ENDIF -->


Refresh the style in the ACP after making that change and then a message will appear on every page asking them to choose a country flag and will place a link to their profile to do so.
LynxTalk
New member
New member
Posts: 3
Joined: 22 Nov 2011, 16:21

Re: Force Flag on Register

Post by LynxTalk »

My style is built on Subsilver2, and i can´t find:

Code: Select all

   <span class="corners-bottom"><span></span></span></div>
              </div>
              <!-- ENDIF -->

in overall_header.

How do I do?


Thanks! :rock:
User avatar
RMcGirr83
Supporter
Supporter
Posts: 6242
Joined: 30 Nov 2006, 14:23
Real name: Rich McGirr

Re: Force Flag on Register

Post by RMcGirr83 »

Find This may be a partial find and not the whole line

Code: Select all

<div id="wrapcentre">


Add after Add these lines on a new blank line after the preceding line(s) to find

Code: Select all

<!-- IF not S_FLAG and SCRIPT_NAME neq 'ucp'-->
<p class="searchbar">
   <span style="float: {S_CONTENT_FLOW_BEGIN};"><strong>{L_INFORMATION}:</strong> Please take a moment to visit <a href="{U_PROFILE_PROFILE}">your profile</a> and choose a country flag.  Thanks.</span>
</p>
<!-- ENDIF -->   
LynxTalk
New member
New member
Posts: 3
Joined: 22 Nov 2011, 16:21

Re: Force Flag on Register

Post by LynxTalk »

Thanks works great! :rock:
User avatar
RMcGirr83
Supporter
Supporter
Posts: 6242
Joined: 30 Nov 2006, 14:23
Real name: Rich McGirr

Re: Force Flag on Register

Post by RMcGirr83 »

I edited the code above as this

Code: Select all

'U_PROFILE_PROFILE'      => append_sid("{$phpbb_root_path}ucp.$phpEx", 'mode=profile'),


should be this

Code: Select all

'U_PROFILE_PROFILE'      => append_sid("{$phpbb_root_path}ucp.$phpEx", 'i=profile'),
Sysz
New member
New member
Posts: 11
Joined: 02 Mar 2012, 02:48

Re: Force Flag on Register

Post by Sysz »

I have a problem with changing the language on the register page.
The text i want to change is "National Flag" and "choose your country flag"

[img]http://i.imgur.com/aZ9VG.png[/img]

I use 1game (subsilver2 based theme) and i use the phpbb 3.0.10
User avatar
RMcGirr83
Supporter
Supporter
Posts: 6242
Joined: 30 Nov 2006, 14:23
Real name: Rich McGirr

Re: Force Flag on Register

Post by RMcGirr83 »

That can be changed within the language/xxx/common.php file edits changing xxx to whatever the language is that you use. Use a strict text editor like Notepad++ to make the edits and ensure you save the file as UTF-8 without BOM.
Sysz
New member
New member
Posts: 11
Joined: 02 Mar 2012, 02:48

Re: Force Flag on Register

Post by Sysz »

Hehe so it was in the common.php file and i was going crazy looking over the info_acp_flags.php :P
Big thanks RMcGirr83 for helping me so fast.
Luke
Member
Member
Posts: 57
Joined: 20 Apr 2012, 17:04
Location: Northern Ireland

Re: Force Flag on Register

Post by Luke »

Great mod, and addon to the mod.

http://www.rmcgirr83.org/viewtopic.php?p=13326#p13326
The first line of this post: "Open includes/ucp_profile.php" should say "Open includes/ucp/ucp_profile.php"
User avatar
RMcGirr83
Supporter
Supporter
Posts: 6242
Joined: 30 Nov 2006, 14:23
Real name: Rich McGirr

Re: Force Flag on Register

Post by RMcGirr83 »

Quite right...fixed
UPSIDE
New member
New member
Posts: 19
Joined: 19 Apr 2012, 16:55

Re: Force Flag on Register

Post by UPSIDE »

Thanks, RMcGirr83!
guardianwill
New member
New member
Posts: 10
Joined: 14 Nov 2012, 02:36

Re: Force Flag on Register

Post by guardianwill »

Ooopsie wrote:Thanks Rich. I will be changing....I'll uninstall the other flag mod and use yours.

Gras....


Hey Ooopsie, did you find it hard to remove the other flag mod. Everytime I tried to it seems to leave a lot behind. Even if it acts as if it was successful.

William
Togbish
New member
New member
Posts: 14
Joined: 05 Jan 2013, 18:01

Re: Force Flag on Register

Post by Togbish »

Works for me and I really love it. :D
Post Reply