vBulletin SEO Forums

SEO

vBulletin Search Engine Optimization

Buy vBSEO Now! HACKER SAFE certified sites prevent over 99.9% of hacker crime.
ne nw
vBSEO Total Support Team Launches DeskPro New vBSEO Discount Level for Network Builders vBSEO 3.2.0 GOLD Has Landed Success with vBSEO = 600ore Web Visitors + $1400 in a Day! Crawlability Inc. Files for SEO Technology Patent
se sw

Create a Custom vBulletin "404 Page Not Found" Page, and direct vBSEO to use it.

This is a discussion on Create a Custom vBulletin "404 Page Not Found" Page, and direct vBSEO to use it. within the Member Articles forums, part of the Focus on Members category; This will allow you to create a custom 404 Page Not Found page that uses your vBulletin templates, and includes ...

Go Back   vBulletin SEO Forums > Focus on Members > Member Articles

Enhancing 80 million pages.

Register FAQ Members List Social Groups Calendar Search Today's Posts Mark Forums Read
  1 links from elsewhere to this Post. Click to view. #1  
Old 02-07-2007, 01:16 PM
Keith Cohen's Avatar
vBSEO Staff
vBSEO Total Customer SupportBig Board Administrator
 
Real Name: Keith Cohen
Join Date: Jul 2005
Location: Raleigh, NC USA
Posts: 6,266
Create a Custom vBulletin "404 Page Not Found" Page, and direct vBSEO to use it.

This will allow you to create a custom 404 Page Not Found page that uses your vBulletin templates, and includes your vBulletin header, navbar, and footer. All without modifying any vBulletin files.

Create a new template named custom_404 and paste the following content into it. (Feel free to customize, of course.)
Code:
$stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
 <!-- no cache headers -->
 <meta http-equiv="Pragma" content="no-cache" />
 <meta http-equiv="Expires" content="-1" />
 <meta http-equiv="Cache-Control" content="no-cache" />
 <!-- end no cache headers -->
 $headinclude
 <title>Page Not Found - <phrase 1="$vboptions[bbtitle]">$vbphrase[x_powered_by_vbulletin]</phrase></title>
</head>
<body>
$header
$navbar
<br />
<div style="padding-left: 25px; padding-right: 25px; font-weight: bold;" align="center">
Sorry, the page you have requested cannot be found.
<br/><br/>
You can try a <a href="$vboptions[bburl]/search.php">search</a> if you are looking for something specific.
</div>
$footer
</body>
</html>

Then, create a file called 404.php in your site root, or forums root, and paste the following content into it. You will need to customize the code in red to point to the physical location of the misc.php file that comes with vBulletin.
Code:
<?php
header("HTTP/1.0 404 Not Found");
header("Status: 404 Not Found");
$_GET['do']='page';
$_REQUEST['do']='page';
$_GET['template']='404';
$_REQUEST['template']='404';
define('VBSEO_PREPROCESSED', 1);
include '/usr/home/username/public_html/forums/misc.php';
?>

Then, in your vBSEO Control Panel, for the "File Not Found" requests handling? setting, enter the following. Again, you will need to customize this to point to the actual physical location of the 404.php file that you created in the previous step.
Code:
/usr/home/username/public_html/404.php 
__________________
Keith Cohen / Crawlability Inc.
Support Team Launches New DeskPro Powered Tool Enhanced Support at Your Service

vBSEO 3.2.0 Launched - Maximum Overdrive for Your Web Traffic! Over 100 Instant SEO Optimizations

6X Traffic - $1400 in One Day with vBSEO! Imagine What the vBSEO Patent Pending Technology Can Do For You.


My Personal Sites: My Blog | GPS Discussion Forum

Last edited by Keith Cohen; 02-07-2007 at 11:02 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #2  
Old 02-07-2007, 01:28 PM
Snake's Avatar
Senior Member
vBulletin Hacker
 
Real Name: Josh
Join Date: Oct 2005
Location: Cleveland, OH
Posts: 416
Send a message via AIM to Snake Send a message via MSN to Snake
Wow! This is really SOMETHING! Thanks for the article, Keith. I appreciate it.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #3  
Old 02-07-2007, 03:24 PM
Member
 
Real Name: Derek
Join Date: Sep 2006
Location: Spokane, WA
Posts: 76
Send a message via AIM to Exitilus Send a message via Yahoo to Exitilus
Awesome I'll set this up in a bit!!! :yay
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #4  
Old 02-07-2007, 03:31 PM
Senior Member
Big Board Administrator
 
Real Name: Dhillon
Join Date: Apr 2006
Location: Chandigarh/Glasgow
Posts: 289
this is very neat,thanks much
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #5  
Old 02-07-2007, 07:30 PM
dutchbb's Avatar
Senior Member
vBSEO Pre-Release TeamBig Board Administrator
 
Real Name: ---
Join Date: Oct 2005
Location: Belgium
Posts: 685
Nice, I was thinking about it but not sure if it would be a good idea, with the search option included its actually better than redirecting to the homepage.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #6  
Old 02-07-2007, 08:16 PM
Member
 
Real Name: Derek
Join Date: Sep 2006
Location: Spokane, WA
Posts: 76
Send a message via AIM to Exitilus Send a message via Yahoo to Exitilus
Awesome works great I'm curious is there a way I could include this onto pages that are not re-written with VBSEO ?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #7  
Old 02-07-2007, 08:18 PM
Keith Cohen's Avatar
vBSEO Staff
vBSEO Total Customer SupportBig Board Administrator
 
Real Name: Keith Cohen
Join Date: Jul 2005
Location: Raleigh, NC USA
Posts: 6,266
You can use a .htaccess file to point to a custom 404 page, or some hosts have an online interface to let you specify a custom 404 page. Just point them to that same 404.php file you created.
__________________
Keith Cohen / Crawlability Inc.
Support Team Launches New DeskPro Powered Tool Enhanced Support at Your Service

vBSEO 3.2.0 Launched - Maximum Overdrive for Your Web Traffic! Over 100 Instant SEO Optimizations

6X Traffic - $1400 in One Day with vBSEO! Imagine What the vBSEO Patent Pending Technology Can Do For You.


My Personal Sites: My Blog | GPS Discussion Forum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #8  
Old 02-07-2007, 08:53 PM
dutchbb's Avatar
Senior Member
vBSEO Pre-Release TeamBig Board Administrator
 
Real Name: ---
Join Date: Oct 2005
Location: Belgium
Posts: 685
Changed it a bit for different layout: http://forum.dutchbodybuilding.com/404

If you want it here's the code for in the template:

PHP Code:
$stylevar[htmldoctype]
<
html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<
head>
 <!-- 
no cache headers -->
 <
meta http-equiv="Pragma" content="no-cache" />
 <
meta http-equiv="Expires" content="-1" />
 <
meta http-equiv="Cache-Control" content="no-cache" />
 <!-- 
end no cache headers -->
 
$headinclude
 
<title>Error 404Page Not Found - <phrase 1="$vboptions[bbtitle]">$vbphrase[x_powered_by_vbulletin]</phrase></title>
</
head>
<
body>
$header
$navbar
<div style="text align:center;">
<
div style="margin:auto;text-align:left;padding:20px 30px 20px 30px;width:750px;border:1px solid #333;">
<
h2 style="font:normal 26px Verdana,sans-serif;">Error 404Page Not Found</h2>
<
p>Unfortunatelywe couldnt find the page you tried to view.</p>
<
p>It is possible that the link you followed to get here was invalid, or out of date.</p>
<
h3 style="font:20px Verdana,sans-serif;">Alternative Pages</h3>
<
p>Please use the Search facility (aboveto find the page you were looking for. Alternativelyyou can go to one of the following popular pages:</p>
<
ul>
<
li><a rel="nofollow" href="/search.php">Advanced Forums Search</a></li>
<
li><a href="/">Forums Home Page</a></li>
</
ul>
</
div>
</
div>
$footer
</body>
</
html
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #9  
Old 02-07-2007, 09:16 PM
BamaStangGuy's Avatar
Senior Member
vBSEO Pre-Release TeamBig Board Administrator
 
Real Name: Brent Wilson
Join Date: Aug 2005
Location: Huntsville, Alabama
Posts: 2,347
Send a message via AIM to BamaStangGuy Send a message via MSN to BamaStangGuy
Why is it not seeing my CSS? http://www.mustangevolution.com/foru...eadlights.html

NM I just copied and pasted it into the template.

Is there a problem reading it when the style is stored in the file system?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #10  
Old 02-07-2007, 11:01 PM
Keith Cohen's Avatar
vBSEO Staff
vBSEO Total Customer SupportBig Board Administrator
 
Real Name: Keith Cohen
Join Date: Jul 2005
Location: Raleigh, NC USA
Posts: 6,266
Ok, Oleg to the rescue!

You need to add this line to the 404.php file to correct the issue. (First post updated.)

This is the line that was added:
Code:
define('VBSEO_PREPROCESSED', 1);
__________________
Keith Cohen / Crawlability Inc.
Support Team Launches New DeskPro Powered Tool Enhanced Support at Your Service

vBSEO 3.2.0 Launched - Maximum Overdrive for Your Web Traffic! Over 100 Instant SEO Optimizations

6X Traffic - $1400 in One Day with vBSEO! Imagine What the vBSEO Patent Pending Technology Can Do For You.


My Personal Sites: My Blog | GPS Discussion Forum
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #11  
Old 02-08-2007, 07:07 AM
Snake's Avatar
Senior Member
vBulletin Hacker
 
Real Name: Josh
Join Date: Oct 2005
Location: Cleveland, OH
Posts: 416
Send a message via AIM to Snake Send a message via MSN to Snake
Hehe. I'm not sure whether you'll like mine but here you go. Check it out.

Final Fantasy Forums - HTTP Error 404: File Not Found

If you guys like it, then I'd be happy to share it with you all. Also I have even created from 400 till 505 custom error pages which took me a while to do that.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #12  
Old 02-08-2007, 11:25 PM
Member
 
Real Name: Derek
Join Date: Sep 2006
Location: Spokane, WA
Posts: 76
Send a message via AIM to Exitilus Send a message via Yahoo to Exitilus
Quote:
Originally Posted by Keith Cohen View Post
You can use a .htaccess file to point to a custom 404 page, or some hosts have an online interface to let you specify a custom 404 page. Just point them to that same 404.php file you created.
Been trying to use

ErrorDocument 404 /forums/404.php

but the stupid thing just won't work ... *cries*
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #13  
Old 02-20-2007, 11:19 PM
Junior Member
 
Real Name: abdulla
Join Date: Feb 2007
Posts: 1
DarkBlade, can you please share your custom error pages? they really look good
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #14  
Old 02-21-2007, 02:12 PM
Senior Member
vBSEO Pre-Release Team
 
Real Name: Michael
Join Date: Oct 2005
Posts: 1,682
Blog Entries: 1
Thanks Keith! and Thanks Tijl for the modified template. Been wanting something custom for this for quite some time now and had no clue how to do it.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
  #15  
Old 02-23-2007, 08:42 PM
Junior Member
Big Board Administrator
 
Real Name: Joe
Join Date: Oct 2005
Posts: 28
Thanks Keith, nice custom feature!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on Facebook!
Reply With Quote
Reply

Tags
404, custom pages

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


LinkBacks (?)
LinkBack to this Thread: http://www.vbseo.com/f34/create-custom-vbulletin-404-page-not-found-page-direct-vbseo-use-11288/

Posted By For Type Date
Solo 297 pagine indicizzate, ma perchè? This thread Refback 02-21-2007 09:33 AM


All times are GMT -4. The time now is 09:00 AM.


Powered by vBulletin Version 3.8.0 Beta 4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.5 ©2008, Crawlability, Inc.