Anybody updated this for 4.0 yet?
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; Anybody updated this for 4.0 yet?...
Anybody updated this for 4.0 yet?
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:{vb:stylevar htmldoctype} <html xmlns="http://www.w3.org/1999/xhtml" dir="{vb:stylevar textdirection}" lang="{vb:stylevar languagecode}" id="vbulletin_html"> <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 --> <title>Page Not Found - {vb:raw vboptions.bbtitle}</title> {vb:raw headinclude} </head> <body> {vb:raw header} {vb:raw 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="{vb:raw vboptions.bburl}/search.php">search</a> if you are looking for something specific. </div> {vb:raw 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
Thanks!
Sorry if this has been loosely mentioned and a resolution posted, but I cannot seem to find it. This works greats for threads that were never created, but the problem I have is that if a thread was created and I then delete it, I do not get a 404 error, but am directed to another thread. It never shows the 404. What am I doing wrong?
Do I need to clear some cache or do some maintenance?
THanks
When I installed this on vb 4.01 running vbseo 3.5 rc2 I got the following errors:
Warning: include(/home/cheryl/public_html/404.php ) [function.include]: failed to open stream: No such file or directory in /home/cheryl/public_html/forum/vbseo.php on line 1602
Warning: include() [function.include]: Failed opening '/home/cheryl/public_html/404.php ' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/cheryl/public_html/forum/vbseo.php on line 1602
I tried putting 404.php in root and then moved it to /forum and got the same type of errors either way.
What have I done wrong?
Hello,
It should be in the forum directory. Then make sure you define its location in the cp to include the /forum/ directory.
The Forum Hosting - Forum Hosting from the Forum Experts
This is the same issue I have:
If I have a 'real' not found that never existed it shows the 404 see here: http://www.bizface.co.uk/bizfaceforu...**@hotmail.com
Whereas any other thread that (say) was deleted get redirected and shows 'no valid thread specified' see here: http://www.bizface.co.uk/bizfaceforu...ty-market.html
How can this behaviour be modified?
Regards
Roy
Unfortunately, that is default vbulletin behavior. They never send invalid thread id's to the 404 script to process.
Brian Cummiskey / Crawlability Inc.
Security bulletin - Patch Level for all supported versions released
Unveiling the NEW vBSEO Sitemap Generator 3.0. - available NOW for vBSEO Customers!
How do I find the physical location of the file?
Can you be more specific? I'm not sure what you're asking for....
Brian Cummiskey / Crawlability Inc.
Security bulletin - Patch Level for all supported versions released
Unveiling the NEW vBSEO Sitemap Generator 3.0. - available NOW for vBSEO Customers!
I know that my file is located in forum/misc.php, but I'm not sure what kind of address I'm supposed to enter because I'm not familiar with the term 'physical address.' Should I enter the web URL to this file, public_html/forum/misc.php, ftp://username@url/public_html/forum/misc.php, etc.
That is the URI. You can find this in your phpinfo script (admincp-> maintainence -> view php info)
you should be able to find the current script of the admicp page to pull the path/to/404.php in the script.
Brian Cummiskey / Crawlability Inc.
Security bulletin - Patch Level for all supported versions released
Unveiling the NEW vBSEO Sitemap Generator 3.0. - available NOW for vBSEO Customers!
Thank you. I got it fixed.
wowww wunderfull cok very thanks, super arkadasim ellerine saglik tam aradigim seydi bu .. kusura bakma ingilizcem berbat![]()