View Single Post
  #862  
Old 03-23-2004, 02:13 AM
d3nnis d3nnis is offline
 
Join Date: Jun 2003
Location: Singapore
Posts: 211
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by a43079
Well I don?t know where to go anymore I have posted on vb.org earlier this week and got one reply and it wasn?t much help but I thank him for the effort? but the problem is when I log in, the home page doesn?t change to reflect that I am logged in, but, when I try and register, it notice that I am logged in. How do I fix this?

Any help would be greatly appreciated

My site url is

http://erowebs.org

and the test account I made is

U/N: homet
P/W: homet

Thank you,
A4

okies i fixed it. If you read my findings earlier, what I assume is correct.

replace your login crumb with mine :

Code:
<!-- Welcome / Login Block -->
	<if condition="!$bbuserinfo['userid']">
	<script src="http://forums.keeptouch.net/clientscript/md5.js" type="text/javascript"></script>
	<form action="http://forums.keeptouch.net/login.php" method="post" onsubmit="md5hash(vb_login_password,vb_login_md5password)">
	<input name="vb_login_md5password" type="hidden" />
	<input name="s" type="hidden" value="$session[sessionhash]" />
	<input name="do" type="hidden" value="login" />
	</if>
			
	<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder" width="100%">
	<tr>
	<td class="tcat"><span class="smallfont"><b>$vboptions[blockbullet] 
	<if condition="$bbuserinfo['userid']">
	<a href="$vboptions[bburl]/usercp.php?$session[sessionurl]">$vbphrase[a_usercp]</a><else />$vbphrase[a_login]
	</if></b></span></td>
	</tr>
	<tr>
	<td class="$getbgrow">
	
	<if condition="$bbuserinfo['userid']">
	<span class="smallfont">$vbphrase[a_welcome_back], <b>$bbuserinfo[username]</b></span><br />
	
	<if condition="$vboptions['showavatar']">
		<table cellpadding="3">
		<tr>
		<td><a href="$vboptions[bburl]/profile.php?do=editavatar"><img src="$avatarurl" border="0" alt="$vbphrase[a_edit_avatar]" /></a>
		</td>
		</tr>
		</table>
	</if>

	<span class="smallfont">Last visit: $lastvisitdate $lastvisittime<br />
	<if condition="$vboptions['showpm']"><a href="$vboptions[bburl]/private.php?$session[sessionurl]">$vbphrase[a_new_pms]</a>: $bbuserinfo[pmunread]<br /></if>
	<if condition="$vboptions['shownewposts']"><a href="$vboptions[bburl]/search.php?$session[sessionurl]do=getnew">$vbphrase[a_new_posts]</a>: $newposts<br /></if>
	<a href="$vboptions[bburl]/login.php?$session[sessionurl]do=logout" onclick="return log_out()">$vbphrase[a_logout]</a></span>
	
	<else />
		<table width="100%">
		<tr>
		<td>
		<span class="smallfont"><b>$vbphrase[a_username]:<br />
		<input class="bginput" name="vb_login_username" size="12" type="text" /><br />
		$vbphrase[a_password]:</b></span><br />
		<input class="bginput" name="vb_login_password" size="12" type="password" /><br />
		<input checked="checked" class="bginput" name="cookieuser" id="cb_cookieuser" type="checkbox" value="1" /><span class="smallfont">$vbphrase[a_remember_me]</span>
		</td>
		</tr>
		<tr>
		<td>
		<input class="button" type="submit" value="Login!" />
		</td>
		</tr>
		<tr>
		<td>
		<span class="smallfont">$vbphrase[a_not_a_member_yet]<br /><a href="$vboptions[bburl]/register.php">$vbphrase[a_register_now]</a></span>
		</td>
		</tr>
		</table>
	</if>
	</td>
	</tr>
	</table>
	<br />

	<if condition="!$bbuserinfo['userid']">
	</form>
	</if>
</if>
<!-- End Welcome / Login Block -->
I only added $session[sessionhash] to the value parameter
<input name="s" type="hidden" value="$session[sessionhash]" />


which was previously

<input name="s" type="hidden" value="" />

I guess after login, as there is no sessionhash, the homepage cannot recognise you being logon.
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01520 seconds
  • Memory Usage 1,790KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete