Community Forum

Member Login Landing Page

The default behavior of the login form “Log In” button at /index.cfm?method=memberlogin.showLogin is to take users to the Edit Profile page. This is confusing for many users and I want to override this behavior to take them to a welcome page I have created instead. How do I change that button’s behavior?

I am 99% sure I used to know how to do this, but I’ve forgotten the work-around and thought it might be faster to ask than search through all my old files.

I’m replying to bump and tagging @Andrea to see if she can give some insight.

Hey @marketing1,

There isn’t a set way to do this, but if you’re comfortable with the FTP, you can go in and add the following to your style.js file making sure to replace “NEW PAGE URL” with your welcome package page.

$(document).ready(function(){
   $('#v65-loginForm').find('[name="referrerQueryString"]').attr('value', 'NEW PAGE URL');
   $('#user-tools').find('[v65js="modalLoginLink"]').attr('referrerquerystring', 'NEW PAGE URL');
});
2 Likes

Perfection! Thanks, @Andrea

1 Like

Hi Andrea, Looking for an update on this to see if this code is still the way as it doesn’t appear to be working on our site. Wondering if maybe there has been a change with v65 to an updated name with wine direct?

Hey @melissa,

I don’t believe so. Do you know which file the script is in so that I could take a look?

Appreciate it, Andrea. It may be an error on my end but just wanted to check. I put it in the styles.js under the admin folder.

Anything you can assist with is much appreciated! Thank you,

@melissa Problem found! :slight_smile:

I should’ve been more specific, sorry. The file to edit should be found under assets > js > scripts.js.

I’ve moved it for you so it should all be working now. Let me know if that’s not the case :slight_smile:

You’re amazing! Thank you so much!

You’re welcome!