MyBB Community Forums

Full Version: Help! My Site Is Getting Errors!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Not sure what happened, but this morning I saw lots of PHP errors on my site at:

http://www.Bleezed.com

If you scroll down the page, you will see that the site is coming up. But, I need to get rid of all the error messages at the top of the page. The only thing I did other than post entries yesterday was backup the databases via the "Tools & Maintenance --> Database Backup" onto the hosting server. Everything seemed to be working after that. "Analyze and Optimize Selected Tables" was checked when the database was done.

Help! Need to resolve as soon as possible. Thanks.
Steve
That's an uncommon error but it appears to be due to an ad plugin, disable it and see if the errors go.
Thanks Matt! I disabled the plugin and all seems well. Really appreciate your help! BTW, since we're on the subject, I was using the "Ad Randomizer system" plugin. Looks like it was causing the problem as you pointed out. Can you suggest a better plugin that will display ads at the top or bottom of the MyBB installation?

Cheers
Steve
If u u want single ad on Top and Bottom then i can guide u to ad codes in header and footer template. But if u want Ramdon ads then u can use this tutorial http://thetutorialsonline.com/thread-14.html till any good plugin not came on floor.
Hi Alirex:

That would be awesome. I'm a little nervous about touching the php code, so that's why I was hoping for a plugin. But, if there is an easy way to do this then would love to hear about it.

Cheers
Steve
ok then do like i am telling you
FOR HEADER ADS
Step 1 :- go to admin CP and login there Template and Styles -> Templates -> The theme which is present for members and guest

Step 2 :- Click Header Templates -> Header

Find
{$unreadreports}

Place the Code in bottom with with addition <center> </center> in start and end of the code

Add
<script language="Javascript">
<!--


var currentdate = 0;
var core = 0;

function initArray() {

this.length = initArray.arguments.length;
  for (var i = 0; i < this.length; i++) {
  this[i] = initArray.arguments[i];
  }
}

link = new initArray(
"http://www.linkofsite1.com",
"http://www.linkofsite2.com",
"http://www.linkofsite3.com"

);

image = new initArray(
"http://linkofbanner1.com",
"http://linkofbanner2.com",
"http://linkofbanner3.com"

);

text = new initArray(
"Name Of Site1",
"Name Of Site2",
"Name Of Site3"

);

var currentdate = new Date();
var core = currentdate.getSeconds() % image.length;
var ranlink  = link[core];
var ranimage = image[core];
var rantext  = text[core];

document.write('<a href=\"' +ranlink+ '\" target=\"_blank\"><img src=\"'+ranimage+'\" border="0" alt=\"'+rantext+'\"></a>');

//-->
</SCRIPT>

Replace http://www.linkofsite1.com with your advertisement link
Replace http://linkofbanner1.com with your Advertisement banner link
Replace Name Of Site1 with Name of Advertisement site

Do with all the links , banners and site name and add as many as u want.

FOR FOOTER ADS
Step 1 :- go to admin CP and login there Template and Styles -> Templates -> The theme which is present for members and guest

Step 2 :- Click Footer Templates -> footer

Place the Code in bottom with with addition <center> </center> in start and end of the code

Add
<script language="Javascript">
<!--


var currentdate = 0;
var core = 0;

function initArray() {

this.length = initArray.arguments.length;
  for (var i = 0; i < this.length; i++) {
  this[i] = initArray.arguments[i];
  }
}

link = new initArray(
"http://www.linkofsite1.com",
"http://www.linkofsite2.com",
"http://www.linkofsite3.com"

);

image = new initArray(
"http://linkofbanner1.com",
"http://linkofbanner2.com",
"http://linkofbanner3.com"

);

text = new initArray(
"Name Of Site1",
"Name Of Site2",
"Name Of Site3"

);

var currentdate = new Date();
var core = currentdate.getSeconds() % image.length;
var ranlink  = link[core];
var ranimage = image[core];
var rantext  = text[core];

document.write('<a href=\"' +ranlink+ '\" target=\"_blank\"><img src=\"'+ranimage+'\" border="0" alt=\"'+rantext+'\"></a>');

//-->
</SCRIPT>

Replace http://www.linkofsite1.com with your advertisement link
Replace http://linkofbanner1.com with your Advertisement banner link
Replace Name Of Site1 with Name of Advertisement site

Do with all the links , banners and site name and add as many as u want.
Thanks Alirex. I will give this a try. Also, one thing that is annoying me and would love to solve is how to center the banner currently at the top of my site at http://www.Bleezed.com - I know this is probably simple, but can't seem to locate the code for it or what to change.

Cheers
Steve
Go to ADMIN CP -> Template and Styles -> Templates -> Your Working Template -> Click Header Templates -> Header

Find
<img src="{$theme['logo']}" alt="{$mybb->settings['bbname']}" title="{$mybb->settings['bbname']}" />

Replace it with
<center><img src="{$theme['logo']}" alt="{$mybb->settings['bbname']}" title="{$mybb->settings['bbname']}" /></center>
Hi Alirex:

I changed the code in "ADMIN CP -> Template and Styles -> Templates -> Default Templates -> Click Header Templates -> Header"

and finally the top logo is centered!! Thanks so much.
Steve
(2009-11-30, 07:26 PM)bleezed Wrote: [ -> ]Hi Alirex:

I changed the code in "ADMIN CP -> Template and Styles -> Templates -> Default Templates -> Click Header Templates -> Header"

and finally the top logo is centered!! Thanks so much.
Steve

Good , if u want any help just PM me i will feel happy to help u.
Pages: 1 2