• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.4 404 error when users attempt direct login to Xenforo (site has Wordpress + Amember Integration)

So if the users start with the wordpress site, and login there, the single login carries over into Xenforo and Amember in the background flawlessly.

The problem is that if, say, I wanted to directly link users to an interesting forum topic, they can get to the post fine, but when they try to login to Xenforo from that page (without passing through wordpress first), they get a 404 error.

Has anyone had this problem before?


XenForo developer
Staff member
Looking at your forum, I can see the login request in XenForo is redirected to an Amember URL (/amember/login). This is the URL that's 404'ing, so I believe you would need to ask Amember about this problem. I assume it's their add-on that is triggering the redirect.
Thanks, quick question maybe you would be able to help me since you are a developer. I think i've found the problem. In the Amember instructions for installing the amember plugin into xenforo they have the following instructions:

install aMember plugin to XenForo (plugin will do redirect for login/logout links)
- copy folder Amember from xenforo_plugin to folder library of your XenForo installation
- go to XenForo Admin Interface -> Home -> Install Add-ons
and install from file addon-Amember.xml
- to disable Xenforo sliding login form and make redirect working
please edit template PAGE_CONTAINER
and remove the next code
<xen:elseif is="!{$visitor.user_id} && !{$hideLoginBar}" />
<xen:include template="login_bar" />

However the code I have for PAGE_CONTAINER is:
class_exists('XenForo_Application', false) || die('Invalid');

$contents = strval($contents);
$hasInstallSidebar = (strpos($contents, 'id="sideNav"') !== false);
<!DOCTYPE html>
<html id="XenForo" class="Install">
<meta charset="utf-8" />
<title><?php echo ($title ? htmlspecialchars($title) . ' | ' : ''); ?>XenForo</title>

<link rel="stylesheet" type="text/css" href="install.css" />

<script src="../js/jquery/jquery-1.11.0.min.js"></script>
<script src="../js/jquery/jquery.xenforo.rollup.js"></script>
<script src="../js/xenforo/xenforo.js"></script>

jQuery.extend(true, XenForo, {
<?php if (!empty($visitor['csrf_token_page'])) { echo "_csrfToken: '$visitor[csrf_token_page]'"; } ?>

<div id="header">

<div id="logoLine">
<div class="pageWidth">
<a href="http://xenforo.com" target="XenForo"><img src="../styles/default/xenforo/XenForo-small.png" id="logo" /></a>
<h2 id="version"><a href="http://xenforo.com" target="XenForo">XenForo</a> <?php echo XenForo_Application::$version; ?></h2>

<div id="tabsNav">
<div class="pad"></div>


<div id="body" class="pageWidth">
<?php if ($hasInstallSidebar) { ?>
<?php echo $contents; ?>
<?php } else { ?>
<div id="contentContainer" class="noSideBar">
<div id="content">
<div class="titleBar">
<?php if (!empty($title)) { ?>
<h1><?php echo htmlspecialchars($title); ?></h1>
<?php } ?>

<?php echo $contents; ?>

<div id="footer">
<div id="copyright"><?php echo XenForo_Template_Helper_Core::callHelper('copyright', array()); ?></div>
<?php } ?>


I don't see anything in the page_container file that resembles that code. Is there something i'm not seeing? Thanks for your help, I sent a ticket to amember too asking for their help. But I was hoping you might have some insight as a developer, I have zero coding experience, no idea what i'm doing lol.


XenForo moderator
Staff member
You will need to contact Amember for support.

We are unable to provide support for third party products as we are not familiar with them.