<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Gravity Support Forums Topic: Automatic login</title>
		<link>https://legacy.forums.gravityhelp.com/topic/automatic-login</link>
		<description>Gravity Support Forums Topic: Automatic login</description>
		<language>en-US</language>
		<pubDate>Mon, 20 Apr 2026 13:33:28 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>https://legacy.forums.gravityhelp.com/search.php</link>
		</textInput>
		<atom:link href="https://legacy.forums.gravityhelp.com/rss/topic/automatic-login" rel="self" type="application/rss+xml" />

		<item>
			<title>David Peralty on "Automatic login"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/automatic-login#post-222293</link>
			<pubDate>Wed, 24 Apr 2013 07:19:03 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">222293@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Can you copy and paste your functions.php file to pastebin and link to the page here so we can take a look? This code shouldn't effect wp-login.php at all.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Blogit on "Automatic login"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/automatic-login#post-222108</link>
			<pubDate>Wed, 24 Apr 2013 04:30:37 +0000</pubDate>
			<dc:creator>Blogit</dc:creator>
			<guid isPermaLink="false">222108@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hello!&#60;/p&#62;
&#60;p&#62;I know there are several post about this, but none of them have helped me. I simply want to auto login users after they have submitted a user registration form. &#60;/p&#62;
&#60;p&#62;I see that a number of people are using this code, but its not working: &#60;/p&#62;
&#60;pre&#62;&#60;code&#62;add_action( &#38;#39;gform_user_registered&#38;#39;, &#38;#39;pi_gravity_registration_autologin&#38;#39;, 10, 4 );
02
/**
03
 * Auto login after registration.
04
 */
05
function pi_gravity_registration_autologin( $user_id, $user_config, $entry, $password ) {
06
    $user = get_userdata( $user_id );
07
    $user_login = $user-&#38;gt;user_login;
08
    $user_password = $password;
09

10
    wp_signon( array(
11
        &#38;#39;user_login&#38;#39; =&#38;gt; $user_login,
12
        &#38;#39;user_password&#38;#39; =&#38;gt;  $user_password,
13
        &#38;#39;remember&#38;#39; =&#38;gt; false
14
    ) );
15
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;I added the above code at the end of my functions.php. Is there anything else thats needs to be done? &#60;/p&#62;
&#60;p&#62;All that happened when I added the code was my login got broke. When I go to domain.com/wp-login.php and enter user and password and hit login, I just come to a blank page. &#60;/p&#62;
&#60;p&#62;Any input would be lovely.
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
