Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: K@ on August 10, 2010, 07:19:37 PM

Title: Register Redirect
Post by: K@ on August 10, 2010, 07:19:37 PM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=2666)

This mod will give you the option of redirecting your users, when they register at your forum.

It works with registration set as "Instant" and "Account Activation".

Configuration can be found in Admin>Features and options.

Grateful thanks to Cicka!!


Edited to add config info.
Title: Re: Register Redirect
Post by: franklinrony on August 10, 2010, 08:07:49 PM
can clarify please, where redirect,a especific topic or a last post before the guest register?
Title: Re: Register Redirect
Post by: !RFAN on August 11, 2010, 03:01:20 AM
please clarify this??

i cant see any settings??
Title: Re: Register Redirect
Post by: Masterd on August 11, 2010, 04:14:50 AM
Very useful mod.
Title: Re: Register Redirect
Post by: kat on August 11, 2010, 06:56:22 AM
It redirects to wherever you set it to, in Admin>Features and options.
Title: Re: Register Redirect
Post by: franklinrony on August 11, 2010, 02:36:09 PM
Quote from: K@ on August 11, 2010, 06:56:22 AM
It redirects to wherever you set it to, in Admin>Features and options.
ah thanks,very good for redirect to forum rules
Title: Re: Register Redirect
Post by: Propaganistas on August 14, 2010, 11:17:41 AM
Hi,

I'm using SMF RC3, AeMe 2.0 and SP 2.3.2. This mod seems not to work with these mods.

I also took a look at the code and found this:
Quote<operation>
         <search position="replace"><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;]]></search>
         <add><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;
   
   if (!empty($modSettings['instant_register_enable']) && !empty($modSettings['activate_register_url'])){
   $_SESSION['login_url'] = $modSettings['activate_register_url'];
}]]></add>
      </operation>

this has to be the following as we're talking about Account Activation:
Quote<operation>
         <search position="replace"><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;]]></search>
         <add><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;
   
   if (!empty($modSettings[activate_register_enable']) && !empty($modSettings['activate_register_url'])){
   $_SESSION['login_url'] = $modSettings['activate_register_url'];
}]]></add>
      </operation>

Fixing this doesn't solve the broken redirection.
Title: Re: Register Redirect
Post by: kat on August 14, 2010, 11:25:10 AM
Quote from: Propaganistas on August 14, 2010, 11:17:41 AM
I'm using AeMe 2.0 and SP 2.3.2.

What are those?
Title: Re: Register Redirect
Post by: DoctorMalboro on August 14, 2010, 12:31:25 PM
Pretty cool mod... thanks K@ ;)
Title: Re: Register Redirect
Post by: kat on August 14, 2010, 12:33:29 PM
Pleasure, mate!

Cicka did most of the work, to be honest.  :)
Title: Re: Register Redirect
Post by: Propaganistas on August 14, 2010, 01:32:13 PM
Quote from: K@ on August 14, 2010, 11:25:10 AM
Quote from: Propaganistas on August 14, 2010, 11:17:41 AM
I'm using AeMe 2.0 and SP 2.3.2.

What are those?
Aeva Media 2.0 (gallery mod)  &  SimplePortal 2.3.2 (portal mod)
Title: Re: Register Redirect
Post by: Bugo on August 16, 2010, 05:02:48 AM
What about Redirect on Login and/or Logout mod (http://custom.simplemachines.org/mods/index.php?mod=1443)?
Title: Re: Register Redirect
Post by: kat on August 16, 2010, 06:46:24 AM
What about it?
Title: Re: Register Redirect
Post by: Bugo on August 16, 2010, 07:30:53 AM
It seems that it's the same.
Title: Re: Register Redirect
Post by: kat on August 16, 2010, 07:40:52 AM
It does a similar thing, sure.

It's not been updated for RC3, or v1.1.11, though.

You'll find many mods that do similar things to what other mods do.

They just do things in a different way.
Title: Re: Register Redirect
Post by: DoctorMalboro on August 16, 2010, 08:54:19 PM
Quote from: K@ on August 14, 2010, 12:33:29 PMPleasure, mate!

Cicka did most of the work, to be honest.  :)
Cicke besides being beautiful... also made mods? wow... :-[
Title: Re: Register Redirect
Post by: kat on August 17, 2010, 05:20:08 AM
She's submitted quite a few, I believe.
Title: Re: Register Redirect
Post by: Propaganistas on August 20, 2010, 05:00:59 PM
Please review my issue: http://www.simplemachines.org/community/index.php?topic=395177.msg2745249#msg2745249

Thanks :)
Title: Re: Register Redirect
Post by: cicka on August 20, 2010, 05:02:48 PM
Quote from: K@ on August 14, 2010, 12:33:29 PM
Pleasure, mate!

Cicka did most of the work, to be honest.  :)

We did the same amount of work :)
Title: Re: Register Redirect
Post by: kat on August 20, 2010, 05:06:31 PM
One half, the person knew what they were doing. ;)

Sorry, Propaganistas. But, "This mod seems not to work with these mods." doesn't give us anything to go on.

You get errors, what?
Title: Re: Register Redirect
Post by: Propaganistas on August 20, 2010, 05:12:28 PM
Quote from: K@ on August 20, 2010, 05:06:31 PM
But, "This mod seems not to work with these mods." doesn't give us anything to go on.
No, that's just my guess because those are quite huge mods..

Quote from: K@ on August 20, 2010, 05:06:31 PM
You get errors, what?
I didn't get any errors. It just won't redirect after an account activation or registration.. (i tried several times)
Title: Re: Register Redirect
Post by: kat on August 20, 2010, 05:17:17 PM
Hmmm...

Well, for most of today, I've been involved doing this:

http://www.simplemachines.org/community/index.php?topic=396349.0

As you might imagine, I'm bloody knackered!

Actually, I've got double-vision, which ain't good.

So, I'm afraid I'm just off to bed (It's 22:15, here in England)

In the morning, assuming I can see straight, I'll see what I can think of.

If you give us the URL for your forum, maybe I can even try to register, to see what happens.
Title: Re: Register Redirect
Post by: Propaganistas on August 20, 2010, 05:44:14 PM
Quote from: K@ on August 20, 2010, 05:17:17 PM
Hmmm...

Well, for most of today, I've been involved doing this:

http://www.simplemachines.org/community/index.php?topic=396349.0

As you might imagine, I'm bloody knackered!

Actually, I've got double-vision, which ain't good.

So, I'm afraid I'm just off to bed (It's 22:15, here in England)

In the morning, assuming I can see straight, I'll see what I can think of.

If you give us the URL for your forum, maybe I can even try to register, to see what happens.

www.uhrator.be

Note that default forum language is set to Dutch.

Normally, only a specific email provider is accepted at registration, but I'll disable this until 21/08/2010, 18h00 so you can take a look..
Title: Re: Register Redirect
Post by: kat on August 21, 2010, 05:02:30 AM
Yep.

Just the normal "Bedankt voor het registreren. Je ontvangt een e-mail met een link om je account te activeren. Als je na verloop van tijd geen e-mail hebt ontvangen, check dan je spamfolder."

I wonder if the "By activation" could be a problem...

I'll check some things and get back to you.
Title: Re: Register Redirect
Post by: Propaganistas on August 21, 2010, 05:26:31 AM
Quote from: K@ on August 21, 2010, 05:02:30 AM
Yep.

Just the normal "Bedankt voor het registreren. Je ontvangt een e-mail met een link om je account te activeren. Als je na verloop van tijd geen e-mail hebt ontvangen, check dan je spamfolder."

I wonder if the "By activation" could be a problem...

I'll check some things and get back to you.
Ok, thanks K@ :)
Title: Re: Register Redirect
Post by: kat on August 21, 2010, 05:30:21 PM
Sorry for the delay.

My wife got carted off to hospital,  today, with chest pains. It's 22:30, here. Just got back. :(

They're keeping her in, overnight.

Depending on what happens, in the morning, I'll get back to as soon as I can.
Title: Re: Register Redirect
Post by: Propaganistas on August 22, 2010, 04:47:56 AM
Quote from: K@ on August 21, 2010, 05:30:21 PM
Sorry for the delay.

My wife got carted off to hospital,  today, with chest pains. It's 22:30, here. Just got back. :(

They're keeping her in, overnight.

Depending on what happens, in the morning, I'll get back to as soon as I can.

I'm sorry to read that..
Thanks :)
Title: Re: Register Redirect
Post by: kat on August 22, 2010, 01:45:15 PM
Just got her back. :)

Tomorrow, I should be OK, for this. :)
Title: Re: Register Redirect
Post by: cicka on August 24, 2010, 03:12:44 PM
Quote from: Propaganistas on August 14, 2010, 11:17:41 AM
Hi,

I'm using SMF RC3, AeMe 2.0 and SP 2.3.2. This mod seems not to work with these mods.

I also took a look at the code and found this:
Quote<operation>
         <search position="replace"><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;]]></search>
         <add><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;
   
   if (!empty($modSettings['instant_register_enable']) && !empty($modSettings['activate_register_url'])){
   $_SESSION['login_url'] = $modSettings['activate_register_url'];
}]]></add>
      </operation>

this has to be the following as we're talking about Account Activation:
Quote<operation>
         <search position="replace"><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;]]></search>
         <add><![CDATA[function Activate()
{
   global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;
   
   if (!empty($modSettings[activate_register_enable']) && !empty($modSettings['activate_register_url'])){
   $_SESSION['login_url'] = $modSettings['activate_register_url'];
}]]></add>
      </operation>

Fixing this doesn't solve the broken redirection.

What did you fix there? There was nothing to fix in the code of the mod. The mod is working well. If you have problems with other mods then I think it is better to post at their threads instead :)
Title: Re: Register Redirect
Post by: cicka on August 24, 2010, 03:13:28 PM
Quote from: K@ on August 22, 2010, 01:45:15 PM
Just got her back. :)

Tomorrow, I should be OK, for this. :)

I am sorry to hear your wife is not feeling well. I wish her a speedy recovery :)
Title: Re: Register Redirect
Post by: cicka on August 24, 2010, 03:14:44 PM
Quote from: Bugo on August 16, 2010, 05:02:48 AM
What about Redirect on Login and/or Logout mod (http://custom.simplemachines.org/mods/index.php?mod=1443)?

This is something entirely different. It redirect on login and logout and K@'s addon redirects on registration. I can not see what is the connection between those 2 things.
Title: Re: Register Redirect
Post by: kat on August 24, 2010, 05:26:31 PM
Quote from: cicka on August 24, 2010, 03:13:28 PMI am sorry to hear your wife is not feeling well. I wish her a speedy recovery :)

Ta, darlin'!

NOT a heart-attack, thank Omnipotent Being!

Still having tests, to see what it is, though. :(
Title: Re: Register Redirect
Post by: Propaganistas on August 24, 2010, 06:13:19 PM
Quote from: cicka on August 24, 2010, 03:12:44 PM
What did you fix there? There was nothing to fix in the code of the mod. The mod is working well. If you have problems with other mods then I think it is better to post at their threads instead :)

I thought that your edits in Register.php are wrong because in function Register() you write the following:
if (!empty($modSettings['instant_register_enable']) && !empty($modSettings['instant_register_url'])){ (instant + instant)

while in function Activate() I think there's a mixed setting:
if (!empty($modSettings['instant_register_enable']) && !empty($modSettings['activate_register_url'])){ (instant + activate)

After checking the other code edits, I found that there's a checkbox called activate_register_enable. Because this box id hasn't been used, methinks it belongs to function Activate(), replacing instant_register_enable.

As a result, the checkbox with id activate_register_enable has a purpose of being there..

Don't you think so?
Title: Re: Register Redirect
Post by: kat on August 25, 2010, 08:05:39 AM
As It works, for everyone but you, could it be a mod clash, somewhere?

Not sure where to check, to be honest.
Title: Re: Register Redirect
Post by: Propaganistas on August 25, 2010, 01:09:50 PM
Quote from: K@ on August 25, 2010, 08:05:39 AM
As It works, for everyone but you, could it be a mod clash, somewhere?

Not sure where to check, to be honest.
Weird.. I disabled every mod and then tried this, but it still doesn't work..
Title: Re: Register Redirect
Post by: kat on August 25, 2010, 01:12:46 PM
Without access to your admin panel, I'm kind blind, with this, I'm afraid.
Title: Re: Register Redirect
Post by: rocknroller on August 28, 2010, 11:53:13 AM
greetings,

After i was install other mod, Welcome Topic (http://custom.simplemachines.org/mods/index.php?mod=789)

Register Redirect does not work anymore. That two mods will be great to work together.


I am on 2.0RC2.

Tnx

EDIT: put ] on right place.
Title: Re: Register Redirect
Post by: kat on August 28, 2010, 03:50:14 PM
What I'd do, if I was in your place, would be to go to the mod's parser and make sure the edits that it made are still there and in the right place.

Installing the second mod may have altered the first.

Fortunately, this mod doesn't have many edits. So, it should be pretty easy to check. :)
Title: Re: Register Redirect
Post by: rocknroller on August 28, 2010, 04:58:24 PM
Quote from: K@ on August 28, 2010, 03:50:14 PM
What I'd do, if I was in your place, would be to go to the mod's parser and make sure the edits that it made are still there and in the right place.

Installing the second mod may have altered the first.

Fortunately, this mod doesn't have many edits. So, it should be pretty easy to check. :)

lines is diferent in each mod. no conflict between file edits, nothing what can i see.

Maybe i should install new SMF on local, and test same situation.
Title: Re: Register Redirect
Post by: kat on August 29, 2010, 08:31:00 AM
When you say "Register Redirect does not work anymore", what do you mean, exactly?
Title: Re: Register Redirect
Post by: rocknroller on August 29, 2010, 11:18:46 AM
Quote from: K@ on August 29, 2010, 08:31:00 AM
When you say "Register Redirect does not work anymore", what do you mean, exactly?

I am sorry for my bad english...

I mean, when I create registration for test.  guest =>register=>(without email activation), that is it. Redirection never happens. Before i was use this great mod for redirecting new users to welcome board, and suggest them to present themselves.

But now i want from system new post, with before the above mentioned mod. (welcome topic).

That would be the result of  =>new member join =>system open welcome post for him=>and the user is redirected to the welcome board.
Title: Re: Register Redirect
Post by: kat on August 29, 2010, 03:48:48 PM
Can you give us a link to your site, so we can try it out?

Don't worry about your English, R&R. Your English is better than mine!

And I'm English!! ;)
Title: Re: Register Redirect
Post by: rocknroller on August 29, 2010, 05:43:53 PM
tnx, K@  :)

Translate for registration is in attachment,

Here is direct link for registration (http://www.logooff.net/smf2/register/)
Here is the URL where you should be redirected (http://www.logooff.net/smf2/dobrodoslica-novim-clanovima/)
If you need here is direct link to change language (http://www.logooff.net/smf2/profile/?area=account)
Title: Re: Register Redirect
Post by: kat on August 30, 2010, 05:11:31 AM
"reffer"?
Title: Re: Register Redirect
Post by: rocknroller on August 30, 2010, 06:39:13 AM
Quote from: K@ on August 30, 2010, 05:11:31 AM
"reffer"?

just leave blank,

This is, if someone of users told you for this site, how do you say?
Title: Re: Register Redirect
Post by: kat on August 30, 2010, 03:23:30 PM
"referrer", probably.

Just gonna take a look...
Title: Re: Register Redirect
Post by: kat on August 30, 2010, 03:26:57 PM
Just to try and narrow things down, a bit, can you tell me if everything works, as it should, if you revert to the SMF default theme?
Title: Re: Register Redirect
Post by: rocknroller on August 30, 2010, 05:37:47 PM
 :)This theme is upgraded Core theme, orginal from installation. and from begining i do not use defaut theme, only files what i need, hehe. And files like display.template, board.index.template, css from default are in coma. I was not never update that templates.
This is reason why i do not can set Default theme.  :D

I suppose that you have other things to do, this maybe may take to much of your time, I will not bother, so thank you very much for helping.


8)
Title: Re: Register Redirect
Post by: kat on August 30, 2010, 06:02:17 PM
Actually, I'd be curious to find out what it is, to be honest.
Title: Re: Register Redirect
Post by: rocknroller on August 31, 2010, 03:35:46 PM
ok than i will make some tests and post results here.
Title: Re: Register Redirect
Post by: kat on August 31, 2010, 03:41:39 PM
(http://www.augk18.dsl.pipex.com/Smileys/c014.gif)
Title: Re: Register Redirect
Post by: Propaganistas on September 01, 2010, 04:34:02 AM
Quote from: K@ on August 25, 2010, 01:12:46 PM
Without access to your admin panel, I'm kind blind, with this, I'm afraid.
PM sent.
Title: Re: Register Redirect
Post by: kat on September 01, 2010, 08:53:52 AM
PM responded to. :)
Title: Re: Register Redirect
Post by: Propaganistas on September 02, 2010, 01:23:48 PM
Any progress yet?
Title: Re: Register Redirect
Post by: kat on September 02, 2010, 03:04:30 PM
No, I really don't have a clue.

If this mod works, if you uninstall the other one, then there must be some kind of conflict with the edits.

Have you tried uninstalling this one and making  the edits manually?
Title: Re: Register Redirect
Post by: Propaganistas on September 03, 2010, 03:05:53 AM
Quote from: K@ on September 02, 2010, 03:04:30 PM
Have you tried uninstalling this one and making  the edits manually?
Yep..
Title: Re: Register Redirect
Post by: sharks on September 03, 2010, 03:23:21 AM
Thanks for implementing this great idea into a mod. Well done, K@. :D

I'll try this ASAP on my SMF 1.1.11 forum using default theme.

After installation, i have some suggestions to improve the functionality of this mod:

1. Like most forums, my forum uses the member activation method, so would it be possible to add another option to the existing "Enable the account activation redirect mod?", where the member would be redirected to another URL directly after registration but before that user has activated his/her account from the email link. And after the user has activated his/her account from the email link, then the member is redirected to another URL.

2. I think this mod would be more appropriately situated in the Registration section of the admin panel, under Settings, at this link:
index.php?action=regcenter;sa=settings
Title: Re: Register Redirect
Post by: kat on September 03, 2010, 01:25:26 PM
I'll have to try and figure something Sharks. :)

Propaganistas... I really don't know where to go, with your problem.

You say it doesn't work with "AeMe".

I don't even know what that is, I'm afraid. :(
Title: Re: Register Redirect
Post by: Propaganistas on September 05, 2010, 08:14:10 AM
Quote from: K@ on September 03, 2010, 01:25:26 PM
You say it doesn't work with "AeMe".

I don't even know what that is, I'm afraid. :(
AeMe = Aeva Media 2.0

Nah, it's just a guess because that mod is kinda huge.. I don't say that AeMe the main reason is for this..
Title: Re: Register Redirect
Post by: kat on September 05, 2010, 02:12:24 PM
Out of curiosity, how do you know it's Aeva that's the problem?
Title: Re: Register Redirect
Post by: Propaganistas on September 06, 2010, 04:50:21 AM
Quote from: K@ on September 05, 2010, 02:12:24 PM
Out of curiosity, how do you know it's Aeva that's the problem?
As I said before: it's just a wild guess. It could be Aeva, it could be SimplePortal, it could be something else... I only thought it could be aeva or simpleportal because those are huge mods..
Title: Re: Register Redirect
Post by: kat on September 06, 2010, 04:56:22 AM
Well, I have SP on my forum and the Register mod went without a problem.

So, yeah, maybe it's AEVA.

Can AEVA be disabled?

If so, does this work, if you disable AEVA?
Title: Re: Register Redirect
Post by: Propaganistas on September 06, 2010, 07:20:12 AM
Still no luck..

I'm going to try your mod on a freshly installed system.. If that doesn't work, it's server-related, if it does work i'll install some mods one by one..
Title: Re: Register Redirect
Post by: Propaganistas on September 06, 2010, 08:03:01 AM
Ok, I got some information.

On a fresh forum, the mod works out of the box for immediate registration, but only works for activation when BOTH checkboxes are ticked.

Sadly, ticking both on my current forum doesn't make it work. I'll install other mods one by one in the next few days.
Title: Re: Register Redirect
Post by: kat on September 06, 2010, 05:18:34 PM
I'm working on the mod, to see if I can figure something.

I'll try and put an update on, tomorrow.
Title: Re: Register Redirect
Post by: kat on September 07, 2010, 04:35:20 PM
The array key name may have been affecting other mods.

That's been fixed, in this version (attached).
Title: Re: Register Redirect
Post by: Propaganistas on September 08, 2010, 04:32:29 AM
Quote from: K@ on September 07, 2010, 04:35:20 PM
The array key name may have been affecting other mods.

That's been fixed, in this version (attached).
The direct registration method now redirects, but activation by mail still doesn't have any luck.. :(

Actually, I'd like to test the redirecting at activation by hardcoding this instead of some settings in the admin panel. That way, it should be clear if it's server-related/variable-related?

Is this the correct code change for hardcoding redirect at activation?:
FINDfunction Activate()
{
global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;

REPLACEfunction Activate()
{
global $context, $txt, $modSettings, $scripturl, $sourcedir, $smcFunc, $language;

   $_SESSION['login_url'] = "http://www.google.com";

Title: Re: Register Redirect
Post by: Propaganistas on September 15, 2010, 09:58:08 AM
I just tried hardcoding the piece above but it didn't work..
Title: Re: Register Redirect
Post by: Propaganistas on September 21, 2010, 03:23:29 AM
Nevermind. I found a workaround by adding menu tabs which are only visible to certain groups.
Title: Re: Register Redirect
Post by: kat on September 21, 2010, 09:49:18 AM
Thanks for sharing that.

Might be useful, that!
Title: Re: Register Redirect
Post by: Propaganistas on September 23, 2010, 04:55:52 AM
FYI:

write everything your members NEED to read after registration/activation in a custom page (eg. SimplePortal pages), then do the following:

in $sourcedir/Subs.php

EDIT 1
FIND
'home' => array(
    'title' => $txt['home'],
    'href' => $scripturl,
    'show' => true,


REPLACE
'home' => array(
    'title' => $txt['home'],
    'href' => $scripturl,
    'show' => !in_array(0, $user_info['groups']),

If your Home button is modded (like SimplePortal does), find the part which defines your home/forum button and then add at the end of the 'show' => -line this snippet:&& !in_array(0, $user_info['groups'])

SimplePortal example:
Quote'show' => in_array($modSettings['sp_portal_mode'], array(1, 3)) && empty($context['disable_sp']) && $context['allow_edit_profile'],
BECOMES
'show' => in_array($modSettings['sp_portal_mode'], array(1, 3)) && empty($context['disable_sp']) && $context['allow_edit_profile'] && !in_array(0, $user_info['groups']),

EDIT 2
FIND
'help' => array(
    'title' => $txt['help'],
    'href' => $scripturl . '?action=help',
    'show' => true,
    'sub_buttons' => array(
    ),
),


ADD BEFORE
'postregister' => array(
    'title' => $txt['home'],
    'href' => $scripturl . '?page=postregister',
    'show' => in_array(0, $user_info['groups']) && empty($user_info['posts']),
    'sub_buttons' => array(
    ),
),

in which ?page=postregister  refers to the custom page.




OPTIONAL EDIT 3

I've also set up a custom tab for members that have made some posts but don't have a primary group anymore. That way, they can't view the forum either without selecting a primary group.

'selectgroup' => array(
    'title' => $txt['home'],
    'href' => $scripturl . '?page=selectgroup',
    'show' => in_array(0, $user_info['groups']) && !empty($user_info['posts']),
    'sub_buttons' => array(
    ),
),

in which ?page=selectgroup  refers to the custom page.




Greetz :)
Title: Re: Register Redirect
Post by: kat on September 23, 2010, 08:10:11 AM
Wow!

You've been working hard!

Thanks!
Title: Re: Register Redirect
Post by: Spacecadet on November 09, 2010, 10:59:30 AM
I know this will sound like a dumb question but where do i find the forms after i create them?
Title: Re: Register Redirect
Post by: kat on November 09, 2010, 03:46:33 PM
You lost me.

You can put these forms, whatever they are, wherever you want them, surely?
Title: Re: Register Redirect
Post by: Spacecadet on November 09, 2010, 07:50:44 PM
Ok but there has to be an actual file right? Where do i see the finished version of the form and where do i direct the link to, to use the form?
Title: Re: Register Redirect
Post by: Spacecadet on November 09, 2010, 10:28:06 PM
In the main section before the forms is created is says:

"View Forms Text"

If I type in the word "Forms" is that supposed to show a link on my main page now to access the forms I created? I have entered "Forms" in both fields and tried other options and cannot find a link to actually access or use the form.
Title: Re: Register Redirect
Post by: Spacecadet on November 11, 2010, 03:19:14 AM
I think I have sort of figured out whats going on. After reading this:

"This setting allows you to chose the title for the action/page that shows the list of forms to a user (at "index.php?action=forms"). By default 'Custom Forms' will be the title."

However I have no such link anywhere on the page, either that or I don't know where to find it. Can someone throw me a bone please? WOOF!
Title: Re: Register Redirect
Post by: kat on November 11, 2010, 05:45:14 AM
The idea is that you make such a page, yourself.
Title: Re: Register Redirect
Post by: Spacecadet on November 11, 2010, 11:52:34 AM
lol OMG K you're killing me, let me say this in a diffrent way. How do i see the finished version of the form?
Title: Re: Register Redirect
Post by: kat on November 11, 2010, 11:56:58 AM
I must be dim, today.

Go to the page that you made? ;)

Or, perhaps, log out of your forum and register?
Title: Re: Register Redirect
Post by: Spacecadet on November 11, 2010, 12:00:54 PM
How do I go to the page that I made? All I can find is the section where the form is created. I want to view the end result but don't know how.
Title: Re: Register Redirect
Post by: kat on November 11, 2010, 12:03:54 PM
Well, that's up to you, innit?

All this mod does, is enable the redirect.

What you redirect TO is entirely your choice.
Title: Re: Register Redirect
Post by: Spacecadet on November 11, 2010, 12:06:51 PM
Wow K I'm sorry, Im trying to merge 2 diffrent MODs in the sence that I need the redirect to go to a custom form that I made. I honestly thought I was in the Custome Form MOD thread until you said that. LOL I'm so sorry for the confusion, thanks for all the help.
Title: Re: Register Redirect
Post by: kat on November 11, 2010, 12:11:53 PM
(http://www.augk18.dsl.pipex.com/Smileys/c008.gif)(http://www.augk18.dsl.pipex.com/Smileys/c014.gif)
Title: Re: Register Redirect
Post by: Spacecadet on November 14, 2010, 01:17:44 AM
HEY K, I'M BACK!

I'm in the right thread this time too, lol. Got a glitch with the redirect MOD. Well actually, it just doesnt work at all, lol. Thats kind of a glitch??? I'm trying to redirect to a custom form and all it does is drop me back on the index page. I have the registration set to "Instant Activation" and the instant register mod checked. Also i left the account activation mod unchecked. Does the format of the redirect URL matter? should it be a www. or just /forum/index.php...... ?

Thanks
Title: Re: Register Redirect
Post by: choloman05 on November 15, 2010, 04:11:34 PM
Any update for 2.0RC4 or does the current version work? Thanks!
Title: Re: Register Redirect
Post by: Spacecadet on November 15, 2010, 11:36:24 PM
At the moment I cannot get it to work on RC3, it installs fine but doesnt actually do anything. K will check in every now and then, he isn't online that much.
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 05:36:50 AM
I just tried it, on my forum.

It takes almost any URL.

So, I'm confuzzled.
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 07:35:47 AM
Oh oh if your confused I'm up the the creek without a paddle! Are there any settings other than the 2 in features and options?
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 11:23:29 AM
If you actually told me what you're trying to do, it might help...

What, exactly, are you trying to redirect to?
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 12:08:00 PM
I'm trying to rediret to a form i made in the custom form MOD
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 12:12:34 PM
Does this form have a URL?

If not, this mod can't redirect to it.
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 12:15:27 PM
http://www.cantfindmyreceipt.com/forum/index.php?action=form;id=1

Would it be possible for you to log on and try yourself so you can see what happenes? I'll paste the link into both fields and check both boxes. The registration should be set to instant or email verification? I tried both by the way.
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 12:34:14 PM
So, what happens, when you put that URL in?
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 12:50:24 PM
Well I tried it on the instant activation and the email verification mode and in both cases in just drops me to the main index page. I have the force read rules on login mod as well and i disabled that beforei tried using this mod. the force read rules mod works fine.
Title: Re: Register Redirect
Post by: choloman05 on November 16, 2010, 01:33:21 PM
Quote from: K@ on November 16, 2010, 05:36:50 AM
I just tried it, on my forum.

It takes almost any URL.

So, I'm confuzzled.

So it does work with RC4? Now I'm confuzzled lol
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 02:18:05 PM
You and me both my confuzzled friend.
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 03:42:11 PM
I've not tried it, to be honest.

I guess that this is the time so-to-do.

'eck, you lot sure want spoon-feeding, doncha? :)
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 03:44:09 PM
Yes, it works with RC4.

I just installed it and all's good. :)
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 03:56:11 PM
In all fairness K I tried for hours to get it working before I asked for help. On another note, spoon feeding is always apreciated hehhehe.
Title: Re: Register Redirect
Post by: kat on November 16, 2010, 04:02:49 PM
Well, with your particular problem, I really have no ideas.

Would making the url a tiny one help?

http://tinyurl.com
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 08:51:40 PM
Interesting, never seen that before, but it didn't work.

Are there any other options other than the 2 check boxes and the url's? I must be missing something ovious. Can you give a quick breakdown of all the settings or is it just the 2 in 'Features and Options'?
Title: Re: Register Redirect
Post by: Spacecadet on November 16, 2010, 09:39:22 PM
K can you explain this to me please? I have very little knowledge of PHP. Is this what I need to do? Is it a mod conflict?

Quote from: Propaganistas on September 23, 2010, 04:55:52 AM
FYI:

write everything your members NEED to read after registration/activation in a custom page (eg. SimplePortal pages), then do the following:

in $sourcedir/Subs.php

EDIT 1
FIND
'home' => array(
    'title' => $txt['home'],
    'href' => $scripturl,
    'show' => true,


REPLACE
'home' => array(
    'title' => $txt['home'],
    'href' => $scripturl,
    'show' => !in_array(0, $user_info['groups']),

If your Home button is modded (like SimplePortal does), find the part which defines your home/forum button and then add at the end of the 'show' => -line this snippet:&& !in_array(0, $user_info['groups'])

SimplePortal example:
Quote'show' => in_array($modSettings['sp_portal_mode'], array(1, 3)) && empty($context['disable_sp']) && $context['allow_edit_profile'],
BECOMES
'show' => in_array($modSettings['sp_portal_mode'], array(1, 3)) && empty($context['disable_sp']) && $context['allow_edit_profile'] && !in_array(0, $user_info['groups']),

EDIT 2
FIND
'help' => array(
    'title' => $txt['help'],
    'href' => $scripturl . '?action=help',
    'show' => true,
    'sub_buttons' => array(
    ),
),


ADD BEFORE
'postregister' => array(
    'title' => $txt['home'],
    'href' => $scripturl . '?page=postregister',
    'show' => in_array(0, $user_info['groups']) && empty($user_info['posts']),
    'sub_buttons' => array(
    ),
),

in which ?page=postregister  refers to the custom page.




OPTIONAL EDIT 3

I've also set up a custom tab for members that have made some posts but don't have a primary group anymore. That way, they can't view the forum either without selecting a primary group.

'selectgroup' => array(
    'title' => $txt['home'],
    'href' => $scripturl . '?page=selectgroup',
    'show' => in_array(0, $user_info['groups']) && !empty($user_info['posts']),
    'sub_buttons' => array(
    ),
),

in which ?page=selectgroup  refers to the custom page.




Greetz :)
Title: Re: Register Redirect
Post by: kat on November 17, 2010, 08:57:29 AM
Honest answer?

I honestly don't know. :(
Title: Re: Register Redirect
Post by: Spacecadet on November 17, 2010, 09:27:48 AM
In other words stop bugging you? Got it! Thanks for trying.

Whats the word I'm looking for if I were english? Well I'm Canadian, close enough!

"Codswallop"

hehehe
Title: Re: Register Redirect
Post by: kat on November 17, 2010, 12:29:42 PM
No. As I said, that was an honest answer.

I REALLY don't have a clue, I'm afraid. :(
Title: Re: Register Redirect
Post by: Spacecadet on November 17, 2010, 05:52:42 PM
This works for my wife, hang on a sec.

:'( :'( :'(

Would that girl "cicka" know? Is she ever on here anymore or did she finally get tired of guys telling her she was cute and leave lol.
Title: Re: Register Redirect
Post by: kat on November 18, 2010, 06:31:48 AM
I'm in contact.

I'll ask her. :)
Title: Re: Register Redirect
Post by: choloman05 on November 19, 2010, 01:02:49 PM
I just installed this on a 2.0RC4 forum and now I'm kinda locked out of my forum.  When I login I get redirected to my portal page (index.html) and when I try to go back to my forum I find that I'm logged out. Had it working on the same forum just fine before I updated.

The only other mod I had installed was Simple Portal 2.3.3 with a portal page at myurl/index.html . I uninstalled the mod manually (register.php, managesettings.php, modifications.english,php) but I'm still staying logged out.

???
Title: Re: Register Redirect
Post by: kat on November 19, 2010, 04:24:19 PM
I don't see how this can be doing that.

Any errors?

I'm going to upload a new version, if I can figure out how...
Title: Re: Register Redirect
Post by: kat on November 19, 2010, 04:32:44 PM
OK. Done.

New version tested and found to work with RC4 and v1.1.12. :)
Title: Re: Register Redirect
Post by: Spacecadet on November 20, 2010, 12:14:30 AM
K I'm going to uninstall the one I have installed now and install the new version. I'll let you know, thanks.
Title: Re: Register Redirect
Post by: Spacecadet on November 20, 2010, 01:57:00 AM
Didn't Work, I give up.
Title: Re: Register Redirect
Post by: kat on November 20, 2010, 03:21:30 PM
Same problem?
Title: Re: Register Redirect
Post by: Spacecadet on November 20, 2010, 06:14:12 PM
Yes same problem, it simply does nothing. I'm sure the MOD works fine, it must be a conflict with another MOD. I tried to uninstall the red the rules on regsiter mod and it gave me a ton of error codes. I'll have to do it manually and let you know if that help.
Title: Re: Register Redirect
Post by: kat on November 21, 2010, 10:40:19 AM
Ta, doood!
Title: Re: Register Redirect
Post by: endomorph on November 21, 2010, 11:27:19 AM
Can confirm also that this does not work on my RC£ either which is a REAL shame as I really could do with this.

Would it have anything to do with EZportal ?
Title: Re: Register Redirect
Post by: kat on November 21, 2010, 02:55:42 PM
When you say "this does not work on my RC£", what do you mean, exactly?
Title: Re: Register Redirect
Post by: endomorph on November 22, 2010, 02:40:27 AM
Sorry, held shift for too long, RC3
Title: Re: Register Redirect
Post by: kat on November 22, 2010, 05:18:42 AM
Yeah. What do you mean by "Does not work", though?
Title: Re: Register Redirect
Post by: endomorph on November 23, 2010, 03:37:01 PM
Does not work. When you register, it will not redirect. When you activate, it will not redirect.

It just goes to index.php
Title: Re: Register Redirect
Post by: kat on November 23, 2010, 03:44:15 PM
Did the mod install, without errors?

Are you redirecting to a proper URL?
Title: Re: Register Redirect
Post by: choloman05 on November 24, 2010, 09:35:51 AM
Quote from: choloman05 on November 19, 2010, 01:02:49 PM
I just installed this on a 2.0RC4 forum and now I'm kinda locked out of my forum.  When I login I get redirected to my portal page (index.html) and when I try to go back to my forum I find that I'm logged out. Had it working on the same forum just fine before I updated.

The only other mod I had installed was Simple Portal 2.3.3 with a portal page at myurl/index.html . I uninstalled the mod manually (register.php, managesettings.php, modifications.english,php) but I'm still staying logged out.

???

btw, I uninstalled old version and installed the new package. Seems to be working fine now.
Title: Re: Register Redirect
Post by: kat on November 24, 2010, 12:00:32 PM
WooT!
Title: Re: Register Redirect
Post by: endomorph on November 24, 2010, 04:12:40 PM
K@,

Yes and yes
Title: Re: Register Redirect
Post by: kat on November 25, 2010, 09:38:08 AM
Them I'm lost.

No idea, I'm afraid. :(
Title: Re: Register Redirect
Post by: mulder1094 on January 13, 2011, 10:44:32 AM
I've found that this MOD only works with Internet Explorer.

I prefer to use Google Chrome, and when registering I get sent to the forum index after.

However, when using Internet Explorer the MOD works...


Any ideas how to solve this?  :)

SMF2 RC4
Title: Re: Register Redirect
Post by: kat on January 13, 2011, 11:04:36 AM
Odd, that.

The mod was tested with Opera (Obviously), Firefox and Chrome.

It was never even tested with IE, coz IE's crap.

I'm not familiar with Chrome. But, I'd suggest that it MIGHT be one of the Chrome settings that's your problem.

Does anything, with regard to this, appear in your forum error-logs?
Title: Re: Register Redirect
Post by: mulder1094 on January 13, 2011, 11:23:47 AM
There is nothing in the error log, I'll check Chromes settings, see what I find
Title: Re: Register Redirect
Post by: kat on January 13, 2011, 11:31:49 AM
(http://www.katzy.dsl.pipex.com/Smileys/c014.gif)

You HAVE enabled the mod, in Admin>Features and options, yes?

EDIT: Ignore that. You MUST've done, to know that it works with IE...  :P
Title: Re: Register Redirect
Post by: sharks on January 13, 2011, 06:34:21 PM
Quote from: K@ on January 13, 2011, 11:04:36 AM
It was never even tested with IE, coz IE's crap.

Amen to that!

Chrome has some display issues, which can sometimes be very annoying on certain sites.

Firefox on the other hand... is the perfect and very best browser in the world right now. I really do not understand why everyone in their sane minds would not be using it. It's madness i tell you... madness... especially since Firefox is free and has a unique wealth of addons.
Title: Re: Register Redirect
Post by: kat on January 14, 2011, 11:14:27 AM
Quote from: sharks on January 13, 2011, 06:34:21 PM
Firefox on the other hand... is the perfect and very best browser in the world right now.

Some might disagree, with that.

Especially as Firefox is AWFUL, with cookies.

When I do my malware checks, I only ever get hassles because of the way Firefox handles cookies.

Chrome might be good, if they ever finish the damned thing. ;)
Title: Re: Register Redirect
Post by: _pi on March 17, 2011, 04:51:16 PM
have not checked code at all, but in combination with SA FBConnect it doesn't work.
i guess your redirect code somewhere needs to be added.
will check for myself later, just wanted to report this.  O:)

it would be quite useful to have facebook users to be redirected too.
Title: Re: Register Redirect
Post by: kat on March 17, 2011, 04:52:55 PM
I have no idea what you just said, to be honest.

Thanks, though. ;)
Title: Re: Register Redirect
Post by: _pi on March 17, 2011, 05:04:42 PM
i set up a new forum for testing SA Facebook Connect Integration (http://custom.simplemachines.org/mods/index.php?mod=2322)
i learned how to create a facebook app and now successfully can create accounts on my forum,
but your mechanism does not work there.
i want to redirect my new members coming from facebook too to the main welcome board.
Title: Re: Register Redirect
Post by: kat on March 17, 2011, 05:19:28 PM
I wouldn't even know where to start, with that.

I don't do Facebook and I never will. ;)
Title: Re: Register Redirect
Post by: Richardgm on June 29, 2011, 07:52:05 AM
Works great! Thanks!
Title: Re: Register Redirect
Post by: kat on August 15, 2011, 03:18:30 PM
Pleasure! :)
Title: Re: Register Redirect
Post by: King Death II on March 15, 2012, 12:32:37 PM
Has this been updated for the newest version of SMF? Im wanting to upgrade my forum to the 2.0.2 version of SMF (I have RC4 atm) but I dont want to lose all my mods and this one is key for my forum's success. Thanks!
Title: Re: Register Redirect
Post by: kat on March 15, 2012, 02:31:25 PM
Let me put it this way...

I have it on my v2.0.2 forum and it works OK. :)
Title: Re: Register Redirect
Post by: Malachachi on February 28, 2013, 12:12:46 PM
Hi,

I'm trying this out in SMF 2.0.4 and am having problems getting it to do what I thought it would.

I install the mod w/o errors. Enable the account activation redirect mod is checked and has a valid url. Then I create a new acct. with Members -> Registration -> Register New Member with the Require User To Activate checked. When I click on the received activation link, it asks me to login then takes me to the index on the forums - I was expecting that right around here it was going to send me to the url I setup.

I didn't see anything useful in the forums logs. BTW, the option to send admins an email on registration is disabled (dunno if that matters).

Ideas?
Title: Re: Register Redirect
Post by: kat on February 28, 2013, 03:39:52 PM
It's been a while... This mod is designed to redirect people when they register, not when you register them.