Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Themes
Author Message
eagleeye1000
Hangin' Around



Joined: Nov 04, 2007
Posts: 34

PostPosted: Mon Jun 22, 2009 12:01 pm Reply with quote

Hi all,

Been struggling for a few days now with this problem. Can't find the solution here also.

I updated my site to latest ravennuke and now try to setup a new theme for it. Not a default theme that comes with ravennuke.
Everything seems to work quit fine. Except for the forums pages in Firefox.
When I go to the forums main page (forum index page) and all the index pages of the subcategories the pages scroll very slow and stuttering with Firefox 3.

The pages where you read the posts are fine. So only the main index page and the sub index pages give this problem and only in FF 3.

IE works fine, Opera works fine and with FireFox 2 it also goes smooth.

Does anybody know of a firefox 3 issue that's causing this?

I assume for the main page this is setup in the index_body.tpl file? But when I open a categorie to visit the index of that category... which template file is used for that one?
 
View user's profile Send private message
duck
Involved
Involved



Joined: Jul 03, 2006
Posts: 273

PostPosted: Mon Jun 22, 2009 1:08 pm Reply with quote

Never heard of this one before. Do you have a link we can see a sample of? Do you have some mod installed like maybe a box over script on titles? If so likely your problem is related to that a JS leak of some sorts.
 
View user's profile Send private message
eagleeye1000







PostPosted: Mon Jun 22, 2009 1:24 pm Reply with quote

Running a JS indeed. From the bbcode_box mod for phpbb. But on the page where you make your post where the java is used the problem ain't there. It's only on the main forum index page and one level deeper if you click a category.

Here is the content of the javascript from the mod:


Code:
var theSelection = false;


var clientPC = navigator.userAgent.toLowerCase(); // Get client info
var clientVer = parseInt(navigator.appVersion); // Get browser version

var is_ie = ((clientPC.indexOf("msie") != -1) && (clientPC.indexOf("opera") == -1));
var is_nav = ((clientPC.indexOf('mozilla')!=-1) && (clientPC.indexOf('spoofer')==-1)
                && (clientPC.indexOf('compatible') == -1) && (clientPC.indexOf('opera')==-1)
                && (clientPC.indexOf('webtv')==-1) && (clientPC.indexOf('hotjava')==-1));
var is_moz = 0;

var is_win = ((clientPC.indexOf("win")!=-1) || (clientPC.indexOf("16bit") != -1));
var is_mac = (clientPC.indexOf("mac")!=-1);

var baseHeight = 0;

b_help = "Bold: [b]text[/b]";
i_help = "Italic: [i]text[/i]";
u_help = "Underline: [u]text[/u]";
quote_help = "Quote: [quote]text[/quote]";
code_help = "Code: [code]code[/code]";
spoil_help = "Spoiler: [spoil]text[/spoil]";
img_help = "Insert Image: [img]http://image path[/img]";
url_help = "Insert URL: [url]http://xxxxx[/url] or [url=http://www.xxxxx.com]xxxx Website[/url]";
fc_help = "Font Color: [color=red]text[/color] You can use HTML color=#FF0000";
fs_help = "Font Size: [size=10]Small Text[/size]";
ft_help = "Font Type: [font=Tahoma]text[/font]";
rtl_help = "Make message box align from Right to Left";
ltr_help = "Make message box align from Left to Right";
mail_help = "Insert Email: [email]xxxx@xxxx.com[/email]";
grad_help="Insert gradient text (Internet Explorer Only)";
right_help="set text align to right: [align=right]text[/align]";
left_help="set text align to left: [align=left]text[/align]";
center_help="set text align to center: [align=center]text[/align]";
justify_help="justify text: [align=justify]text[/align]";
marqr_help="Marque text to Right: [marq=right]text[/marq]";
marql_help="Marque text to Left: [marq=left]text[/marq]";
marqu_help="Marque text to up: [marq=up]text[/marq]";
marqd_help="Marque text to down: [marq=down]text[/marq]";
stream_help="Insert stream file: [stream]File URL[/stream]";
plain_help="Remove BBCodes from the selected text";
hr_help="Insert Line Break [hr]";
video_help="Insert video file: [video width=# height=#]file URL[/video]";
flash_help="Insert flash file: [flash width=# height=#]flash URL[/flash]";
fade_help = "Fade text: [fade]text[/fade] (Internet Explorer Only)";
list_help = "Ordered list: [list|=1|a]text[/list] Tip: you can use [*] to insert bullet";
strike_help = "Strike text: [s]text[/s]";
sup_help = "Superscript: [sup]text[/sup]";
sub_help = "Subscript: [sub]text[/sub]";
symbol_help = "Insert Symbol Into Post";
youtube_help = "Post a youtube-movie";
googlevid_help = "Post a google video";

var Quote = 0;
var Bold  = 0;
var Italic = 0;
var Underline = 0;
var Code = 0;
var flash = 0;
var fc = 0;
var fs = 0;
var ft = 0;
var center = 0;
var right = 0;
var left = 0;
var justify = 0;
var fade = 0;
var marqd = 0;
var marqu = 0;
var marql = 0;
var marqr = 0;
var mail = 0;
var video = 0;
var stream = 0;
var hr = 0;
var grad = 0;
var plain = 0;
var List = 0;
var Strikeout = 0;
var Spoiler = 0;
var superscript = 0;
var subscript = 0;
var symbol = 0;
var youtube = 0;
var GVideo = 0;

// Fix a bug involving the TextRange object in IE. From
// http://www.frostjedi.com/terra/scripts/demo/caretBug.html
// (script by TerraFrost modified by reddog)
function initInsertions() {
   document.post.message.focus();
   if (is_ie && typeof(baseHeight) != 'number') baseHeight = document.selection.createRange().duplicate().boundingHeight;
}

function BBCplain() {
theSelection = document.selection.createRange().text;
                if (theSelection != '') {
                       temp = theSelection;
                       temp = temp.replace(/\[FLASH=([^\]]*)\]WIDTH=[0-9]{0,4} HEIGHT=[0-9]{0,4}\[\/FLASH\]/gi,"$1");
          temp = temp.replace(/\[VIDEO=([^\]]*)\]WIDTH=[0-9]{0,4} HEIGHT=[0-9]{0,4}\[\/VIDEO\]/gi,"$1");
  document.selection.createRange().text = temp.replace(/\[[^\]]*\]/gi,"");
      }
}

function BBCgrad() {
    var oSelect,oSelectRange;
    document.post.message.focus();
    oSelect = document.selection;
    oSelectRange = oSelect.createRange();
    if (oSelectRange.text.length < 1) { alert("Select text first");
return;
}
    if (oSelectRange.text.length > 120) {
      alert("This only works for less than 120 letters");
      return;
    }
    showModalDialog("modules/Forums/bbcode_box/grad.htm",oSelectRange,"help:no; center:yes; status:no; dialogHeight:50px; dialogWidth:50px");
}

function BBChr() {
   ToAdd = "[hr]";
   PostWrite(ToAdd);
}

function BBCstream() {
        var FoundErrors = '';
        var enterURL   = prompt("Please write stream file URL","http://");
        if (!enterURL) {
                FoundErrors += " You didn't write the file URL.";
        }
        if (FoundErrors) {
                alert("Error:"+FoundErrors);
                return;
        }
        var ToAdd = "[stream]"+enterURL+"[/stream]";
        PostWrite(ToAdd);
}

function BBCvideo() {
   var FoundErrors = '';
   var enterURL   = prompt("Please Enter the video file URL", "http://");
   if (!enterURL)    {
      FoundErrors += " You didn't write the file URL.";
   }
      var enterW   = prompt("Enter the video file width", "400");
   if (!enterW)    {
      FoundErrors += " You didn't enter the video file width.";
   }
   var enterH   = prompt("Enter the video file height", "350");
   if (!enterH)    {
      FoundErrors += " You didn't enter the video file height.";
   }
   if (FoundErrors)  {
      alert("Error:"+FoundErrors);
      return;
   }
   var ToAdd = "[video width="+enterW+" height="+enterH+"]"+enterURL+"[/video]";
   PostWrite(ToAdd);
}


function BBCmail() {
        var FoundErrors = '';
        var entermail   = prompt("Enter the Email Address","");
        if (!entermail) {
                FoundErrors += " You didn't write the Email Address.";
        }
        if (FoundErrors) {
                alert("Error:"+FoundErrors);
                return;
        }
        var ToAdd = "[email]"+entermail+"[/email]";
        PostWrite(ToAdd);
}

function BBCstrike() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[s]" + theSelection + "[/s]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[s]", "[/s]");
      return;
   }
   if (Strikeout == 0) {
      ToAdd = "[s]";
      document.strik.src = "modules/Forums/bbcode_box/images/strike1.gif";
      Strikeout = 1;
   } else {
      ToAdd = "[/s]";
      document.strik.src = "modules/Forums/bbcode_box/images/strike.gif";
      Strikeout = 0;
   }
   PostWrite(ToAdd);
}

function BBCspoil() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[spoil]" + theSelection + "[/spoil]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[spoil]", "[/spoil]");
      return;
   }
   if (Spoiler == 0) {
      ToAdd = "[spoil]";
      document.spoil.src = "modules/Forums/bbcode_box/images/spoil1.gif";
      Spoiler = 1;
   } else {
      ToAdd = "[/spoil]";
      document.spoil.src = "modules/Forums/bbcode_box/images/spoil.gif";
      Spoiler = 0;
   }
   PostWrite(ToAdd);
}

function BBCmarqu() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[marq=up]" + theSelection + "[/marq]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[marq=up]", "[/marq]");
      return;
   }
   if (marqu == 0) {
      ToAdd = "[marq=up]";
      document.post.marqu.src = "modules/Forums/bbcode_box/images/marqu1.gif";
      marqu = 1;
   } else {
      ToAdd = "[/marq]";
      document.post.marqu.src = "modules/Forums/bbcode_box/images/marqu.gif";
      marqu = 0;
   }
   PostWrite(ToAdd);
}

function BBCmarql() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[marq=left]" + theSelection + "[/marq]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[marq=left]", "[/marq]");
      return;
   }
   if (marql == 0) {
      ToAdd = "[marq=left]";
      document.post.marql.src = "modules/Forums/bbcode_box/images/marql1.gif";
      marql = 1;
   } else {
      ToAdd = "[/marq]";
      document.post.marql.src = "modules/Forums/bbcode_box/images/marql.gif";
      marql = 0;
   }
   PostWrite(ToAdd);
}

function BBCmarqr() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[marq=right]" + theSelection + "[/marq]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[marq=right]", "[/marq]");
      return;
   }
   if (marqr == 0) {
      ToAdd = "[marq=right]";
      document.post.marqr.src = "modules/Forums/bbcode_box/images/marqr1.gif";
      marqr = 1;
   } else {
      ToAdd = "[/marq]";
      document.post.marqr.src = "modules/Forums/bbcode_box/images/marqr.gif";
      marqr = 0;
   }
   PostWrite(ToAdd);
}

function BBCdir(dirc) {
       document.post.message.dir=(dirc);
}

function BBCfade() {
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[fade]" + theSelection + "[/fade]";
      document.post.message.focus();
      return;
      }
   }
   if (fade == 0) {
      ToAdd = "[fade]";
      document.post.fade.src = "modules/Forums/bbcode_box/images/fade1.gif";
      fade = 1;
   } else {
      ToAdd = "[/fade]";
      document.post.fade.src = "modules/Forums/bbcode_box/images/fade.gif";
      fade = 0;
   }
   PostWrite(ToAdd);
}

function BBCjustify() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[align=justify]" + theSelection + "[/align]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[align=justify]", "[/align]");
      return;
   }
   if (justify == 0) {
      ToAdd = "[align=justify]";
      document.post.justify.src = "modules/Forums/bbcode_box/images/justify1.gif";
      justify = 1;
   } else {
      ToAdd = "[/align]";
      document.post.justify.src = "modules/Forums/bbcode_box/images/justify.gif";
      justify = 0;
   }
   PostWrite(ToAdd);
}

function BBCleft() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[align=left]" + theSelection + "[/align]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[align=left]", "[/align]");
      return;
   }
   if (left == 0) {
      ToAdd = "[align=left]";
      document.post.left.src = "modules/Forums/bbcode_box/images/left1.gif";
      left = 1;
   } else {
      ToAdd = "[/align]";
      document.post.left.src = "modules/Forums/bbcode_box/images/left.gif";
      left = 0;
   }
   PostWrite(ToAdd);
}

function BBCright() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[align=right]" + theSelection + "[/align]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[align=right]", "[/align]");
      return;
   }
   if (right == 0) {
      ToAdd = "[align=right]";
      document.post.right.src = "modules/Forums/bbcode_box/images/right1.gif";
      right = 1;
   } else {
      ToAdd = "[/align]";
      document.post.right.src = "modules/Forums/bbcode_box/images/right.gif";
      right = 0;
   }
   PostWrite(ToAdd);
}

function BBCcenter() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[align=center]" + theSelection + "[/align]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[align=center]", "[/align]");
      return;
   }
   if (center == 0) {
      ToAdd = "[align=center]";
      document.post.center.src = "modules/Forums/bbcode_box/images/center1.gif";
      center = 1;
   } else {
      ToAdd = "[/align]";
      document.post.center.src = "modules/Forums/bbcode_box/images/center.gif";
      center = 0;
   }
   PostWrite(ToAdd);
}

function BBCft() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[font="+document.post.ft.value+"]" + theSelection + "[/font]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[font="+document.post.ft.value+"]", "[/font]");
      return;
   }
   ToAdd = "[font="+document.post.ft.value+"]"+" "+"[/font]";
   PostWrite(ToAdd);
}

function BBCfs() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[size="+document.post.fs.value+"]" + theSelection + "[/size]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[size="+document.post.fs.value+"]", "[/size]");
      return;
   }
   ToAdd = "[size="+document.post.fs.value+"]"+" "+"[/size]";
   PostWrite(ToAdd);
}

function BBCfc() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[color="+document.post.fc.value+"]" + theSelection + "[/color]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[color="+document.post.fc.value+"]", "[/color]");
      return;
   }
   ToAdd = "[color="+document.post.fc.value+"]"+" "+"[/color]";
   PostWrite(ToAdd);
}

function BBCmarqd() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[marq=down]" + theSelection + "[/marq]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[marq=down]", "[/marq]");
      return;
   }
   if (marqd == 0) {
      ToAdd = "[marq=down]";
      document.post.marqd.src = "modules/Forums/bbcode_box/images/marqd1.gif";
      marqd = 1;
   } else {
      ToAdd = "[/marq]";
      document.post.marqd.src = "modules/Forums/bbcode_box/images/marqd.gif";
      marqd = 0;
   }
   PostWrite(ToAdd);
}

function BBCflash() {
   var FoundErrors = '';
   var enterURL   = prompt("Enter the flash file URL", "http://");
   if (!enterURL)    {
      FoundErrors += " You didn't write the flash file URL.";
   }
   var enterW   = prompt("Enter the flash width", "250");
   if (!enterW)    {
      FoundErrors += " You didn't write the flash width.";
   }
   var enterH   = prompt("Enter the flash height", "250");
   if (!enterH)    {
      FoundErrors += " You didn't write the flash height.";
   }
   if (FoundErrors)  {
      alert("Error:"+FoundErrors);
      return;
   }
   var ToAdd = "[flash width="+enterW+" height="+enterH+"]"+enterURL+"[/flash]";
   PostWrite(ToAdd);
}

function BBCGVideo() {
   var FoundErrors = '';
   var enterURL   = prompt("Enter the movie URL", "http://");
   if (!enterURL)    {
      FoundErrors += " You didn't write the file URL";
   }
   if (FoundErrors)  {
      alert("Error:"+FoundErrors);
      return;
   }
   var ToAdd = "[GVideo]"+enterURL+"[/GVideo]";
   PostWrite(ToAdd);
}

function BBCyoutube() {
   var FoundErrors = '';
   var enterURL   = prompt("Enter the movie URL", "http://");
   if (!enterURL)    {
      FoundErrors += " You didn't write the file URL";
   }
   if (FoundErrors)  {
      alert("Error:"+FoundErrors);
      return;
   }
   var ToAdd = "[youtube]"+enterURL+"[/youtube]";
   PostWrite(ToAdd);
}

function helpline(help) {
   document.post.helpbox.value = eval(help + "_help");
   document.post.helpbox.readOnly = "true";
}

function checkForm() {
   formErrors = false;   
   if (document.post.message.value.length < 2) {
      formErrors = "You must enter a message when posting";
   }
   if (formErrors) {
      alert(formErrors);
      return false;
   } else {
      //formObj.preview.disabled = true;
      //formObj.submit.disabled = true;
      return true;
   }
}

function emoticon(text) {
   var txtarea = document.post.message;
   text = ' ' + text + ' ';
   if (txtarea.createTextRange && txtarea.caretPos) {
      if (baseHeight != txtarea.caretPos.boundingHeight) {
         txtarea.focus();
         storeCaret(txtarea);
      }
      var caretPos = txtarea.caretPos;
      caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ? caretPos.text + text + ' ' : caretPos.text + text;
      txtarea.focus();
   } else
   if (txtarea.selectionEnd && (txtarea.selectionStart | txtarea.selectionStart == 0))
   {
      mozWrap(txtarea, text, "");
      return;
   } else {
      txtarea.value  += text;
      txtarea.focus();
   }
}

function bbfontstyle(bbopen, bbclose) {
   var txtarea = document.post.message;

   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (!theSelection) {
         txtarea.value += bbopen + bbclose;
         txtarea.focus();
         return;
      }
      document.selection.createRange().text = bbopen + theSelection + bbclose;
      txtarea.focus();
      return;
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, bbopen, bbclose);
      return;
   }
   else
   {
      txtarea.value += bbopen + bbclose;
      txtarea.focus();
   }
   storeCaret(txtarea);
}

function storeCaret(textEl) {
   if (textEl.createTextRange) textEl.caretPos = document.selection.createRange().duplicate();
}

function PostWrite(text) {
   if (document.post.message.createTextRange && document.post.message.caretPos) {
      var caretPos = document.post.message.caretPos;
      caretPos.text = caretPos.text.charAt(caretPos.text.length - 1) == ' ' ?   text + ' ' : text;
   }
   else document.post.message.value += text;
   document.post.message.focus(caretPos)
}

function BBCsup() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[sup]" + theSelection + "[/sup]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[sup]", "[/sup]");
      return;
   }
   if (superscript == 0) {
      ToAdd = "[sup]";
      document.supscript.src = "modules/Forums/bbcode_box/images/sup1.gif";
      superscript = 1;
   } else {
      ToAdd = "[/sup]";
      document.supscript.src = "modules/Forums/bbcode_box/images/sup.gif";
      superscript = 0;
   }
   PostWrite(ToAdd);
}

function BBCsub() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[sub]" + theSelection + "[/sub]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[sub]", "[/sub]");
      return;
   }
   if (subscript == 0) {
      ToAdd = "[sub]";
      document.subs.src = "modules/Forums/bbcode_box/images/sub1.gif";
      subscript = 1;
   } else {
      ToAdd = "[/sub]";
      document.subs.src = "modules/Forums/bbcode_box/images/sub.gif";
      subscript = 0;
   }
   PostWrite(ToAdd);
}

function BBCcode() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[code]" + theSelection + "[/code]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[code]", "[/code]");
      return;
   }   
   if (Code == 0) {
      ToAdd = "[code]";
      document.post.code.src = "modules/Forums/bbcode_box/images/code1.gif";
      Code = 1;
   } else {
      ToAdd = "[/code]";
      document.post.code.src = "modules/Forums/bbcode_box/images/code.gif";
      Code = 0;
   }
   PostWrite(ToAdd);
}

function BBCquote() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[quote]" + theSelection + "[/quote]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[quote]", "[/quote]");
      return;
   }
   if (Quote == 0) {
      ToAdd = "[quote]";
      document.post.quote.src = "modules/Forums/bbcode_box/images/quote1.gif";
      Quote = 1;
   } else {
      ToAdd = "[/quote]";
      document.post.quote.src = "modules/Forums/bbcode_box/images/quote.gif";
      Quote = 0;
   }
   PostWrite(ToAdd);
}

function BBClist() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[list]" + theSelection + "[/list]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[list]", "[/list]");
      return;
   }
   if (List == 0) {
      ToAdd = "[list]";
      document.listdf.src = "modules/Forums/bbcode_box/images/list1.gif";
      List = 1;
   } else {
      ToAdd = "[/list]";
      document.listdf.src = "modules/Forums/bbcode_box/images/list.gif";
      List = 0;
   }
   PostWrite(ToAdd);
}

function BBCbold() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[b]" + theSelection + "[/b]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[b]", "[/b]");
      return;
   }
   if (Bold == 0) {
      ToAdd = "[b]";
      document.post.bold.src = "modules/Forums/bbcode_box/images/bold1.gif";
      Bold = 1;
   } else {
      ToAdd = "[/b]";
      document.post.bold.src = "modules/Forums/bbcode_box/images/bold.gif";
      Bold = 0;
   }
   PostWrite(ToAdd);
}

function BBCitalic() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[i]" + theSelection + "[/i]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[i]", "[/i]");
      return;
   }
   if (Italic == 0) {
      ToAdd = "[i]";
      document.post.italic.src = "modules/Forums/bbcode_box/images/italic1.gif";
      Italic = 1;
   } else {
      ToAdd = "[/i]";
      document.post.italic.src = "modules/Forums/bbcode_box/images/italic.gif";
      Italic = 0;
   }
   PostWrite(ToAdd);
}

function BBCunder() {
   var txtarea = document.post.message;
   
   if ((clientVer >= 4) && is_ie && is_win) {
      theSelection = document.selection.createRange().text;
      if (theSelection != '') {
      document.selection.createRange().text = "[u]" + theSelection + "[/u]";
      document.post.message.focus();
      return;
      }
   }
   else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
   {
      mozWrap(txtarea, "[u]", "[/u]");
      return;
   }
   if (Underline == 0) {
      ToAdd = "[u]";
      document.post.under.src = "modules/Forums/bbcode_box/images/under1.gif";
      Underline = 1;
   } else {
      ToAdd = "[/u]";
      document.post.under.src = "modules/Forums/bbcode_box/images/under.gif";
      Underline = 0;
   }
   PostWrite(ToAdd);
}

function BBCurl() {
   var FoundErrors = '';
   var enterURL   = prompt("Enter the URL", "http://");
   var enterTITLE = prompt("Enter the page name", "Web Page Name");
   if (!enterURL)    {
      FoundErrors += " You didn't write the URL.";
   }
   if (!enterTITLE)  {
      FoundErrors += " You didn't write the page name.";
   }
   if (FoundErrors)  {
      alert("Error:"+FoundErrors);
      return;
   }
   var ToAdd = "[url="+enterURL+"]"+enterTITLE+"[/url]";
   PostWrite(ToAdd);
}

function BBCimg() {
   var FoundErrors = '';
   var enterURL   = prompt("Enter the image URL","http://");
   if (!enterURL) {
      FoundErrors += "You didn't write the image URL";
   }
   if (FoundErrors) {
      alert("Error :"+FoundErrors);
      return;
   }
   var ToAdd = "[img]"+enterURL+"[/img]";
   document.post.message.value+=ToAdd;
   document.post.message.focus();
}

function storeCaret(textEl) {
   if (textEl.createTextRange) textEl.caretPos = document.selection.createRange().duplicate();
}

function mozWrap(txtarea, open, close)
{
   var selLength = txtarea.textLength;
   var selStart = txtarea.selectionStart;
   var selEnd = txtarea.selectionEnd;
   if (selEnd == 1 || selEnd == 2)
      selEnd = selLength;

   var s1 = (txtarea.value).substring(0,selStart);
   var s2 = (txtarea.value).substring(selStart, selEnd)
   var s3 = (txtarea.value).substring(selEnd, selLength);
   txtarea.value = s1 + open + s2 + close + s3;
   return;
}


Site link with login pm'd (working on that as a side project to the live site, prefer to keep that away from public untill finished Smile
 
duck







PostPosted: Mon Jun 22, 2009 1:59 pm Reply with quote

You are running several JS which are not necessary on indexes could be improved upon by not running when not necessary however I don't believe them to be the problem. I disabled JS and was still choppy then I hid all images and she scrolled smooth so I am figuring firefox 3 is having an issue with your images. I checked file byte sizes for the 51 images displayed on index and they didn't seem all that unreasonable so what I am thinking here is that many of them are being browser resized instead of natively in their output dimensions.

So what I would do if I were you is try to make sure all forum images are in their output size and recompress if possible images even smaller. After all you are using a lot of jpg's were gif or png would be suitable at about 1/4 or less the compression. Then I would also redo the forum tpl files to be xhtml compliant. Run them through the validator and change the TPL code to reflect the validators recommendations
 
eagleeye1000







PostPosted: Mon Jun 22, 2009 2:19 pm Reply with quote

Could indeed be an image issue. Check this link:
[ Only registered users can see links on this board! Get registered or login! ]

What would be the proper location to place that script file? Tried in main root but no luck, in modules/Forums/ no luck.

Or is there a way to set in the template files from the theme to make the background image "non fixed"?

Also just noticed. When you open the page in Internet Explorer and open the "news and announcements" section of the forum .. then for example the post called "test" you see a red cross image appear on top. Like a missing image. Seems to me there should be some button like "quick reply" or so there. That red cross image is only displayed in internet explorer. Firefox doesn't display that Confused
 
duck







PostPosted: Mon Jun 22, 2009 2:34 pm Reply with quote

Well I just looked quickly at the page you linked and that says it is a greasemonkey script. Which means you plug it into the firefox extension greasemonkey so that is not your best option.

What I would reccomend is to recode your theme to not use BG images where possible. For instance the page bg is not necessary since it is just one big grey block. Just set a page bg color and don't use the image there. (though this is not the issue image) the issue image is the table row bg images. Find this image (fback.gif) and resize it to about 60 height by 5 width. and resave it. Your forum rows are using the sitees main background image which is 800 x 4000 and resizing it down. Alternatively for even faster loading remove the bg image from forum rows completely and just use a bg color. But it won't be a nice gradient then.

*** EDIT Oh and for the IE issue that is IE having trouble with an image. It quite commonly happens with spacer images. Check spacer image paths and make sure they are correct. if you try to view the image in IE it will tell you what path it is expecting for the image. Make sure the image exists where it is looking.
 
Guardian2003
Site Admin



Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam

PostPosted: Mon Jun 22, 2009 2:48 pm Reply with quote

Please post a link to your site.
 
View user's profile Send private message Send e-mail
eagleeye1000







PostPosted: Mon Jun 22, 2009 2:55 pm Reply with quote

almost there Smile

just changed this code:

Code:
/* Main table cell colours and backgrounds */

td.row1   { background-color: #333333; background-image: url(../forums/images/fback.gif); background-repeat: repeat-x; border: 1px #000000 solid;}
td.row2   { background-color: #333333; background-image: url(../forums/images/fback.gif); background-repeat: repeat-x; border: 1px #000000 solid;}
td.row3   { background-color: #333333; background-image: url(../forums/images/fback.gif); background-repeat: repeat-x; border: 1px #000000 solid;}
td.row4   { background-color: #333333; background-image: url(../forums/images/fback.gif); background-repeat: repeat-x; border: 1px #000000 solid;}


to this.. to remove the image, scrolls very smooth now:

Code:
/* Main table cell colours and backgrounds */

td.row1   { background-color: #333333; background-repeat: repeat-x; border: 1px #000000 solid;}
td.row2   { background-color: #333333; background-repeat: repeat-x; border: 1px #000000 solid;}
td.row3   { background-color: #333333; background-repeat: repeat-x; border: 1px #000000 solid;}
td.row4   { background-color: #333333; background-repeat: repeat-x; border: 1px #000000 solid;}


but the only problem now is that when you go over the forum topics with your mouse the color changes to light grey and stays like that. Hope you have a fix for that?
 
eagleeye1000







PostPosted: Mon Jun 22, 2009 3:13 pm Reply with quote

ok it's fixed Smile

resized the image to 16x80 and it works great now. Even with the old code in style.css Smile

Only issue left is that red cross image I mentioned:

Quote:

Also just noticed. When you open the page in Internet Explorer and open the "news and announcements" section of the forum .. then for example the post called "test" you see a red cross image appear on top. Like a missing image. Seems to me there should be some button like "quick reply" or so there. That red cross image is only displayed in internet explorer. Firefox doesn't display that
 
duck







PostPosted: Mon Jun 22, 2009 3:59 pm Reply with quote

themes/yourtheme/images/spacer.gif

Make sure the above exists. If not put a blank 1px by 1px gif in there under that name.
 
eagleeye1000







PostPosted: Mon Jun 22, 2009 4:18 pm Reply with quote

I have it already here:

/themes/Clanswaw/forums/images/spacer.gif

have put it in:

/themes/Clanswaw/images/spacer.gif

aswell. But still the red mark in IE.
 
duck







PostPosted: Mon Jun 22, 2009 4:56 pm Reply with quote

This line is showing up next to your post reply button
Code:
 <a href="" target="_blank">

<img border="0" align="middle" alt="" src=""/>
</a>


This line is probably found in your viewtopic_body.tpl under forums for your theme you will find an area like this near top and bottom of that file but yours will have an extra link

Code:
  <tr> 

   <td align="left" valign="bottom" nowrap="nowrap"><span class="nav"><a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" alt="{L_POST_NEW_TOPIC}" align="middle" /></a>&nbsp;&nbsp;&nbsp;<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" alt="{L_POST_REPLY_TOPIC}" align="middle" /></a>&nbsp;</span></td>
   <td align="left" valign="middle" width="100%"><span class="nav">&nbsp;&nbsp;&nbsp;</span></td>
  </tr>


Just remove the extra link
 
eagleeye1000







PostPosted: Tue Jun 23, 2009 10:55 am Reply with quote

sorted it by removing this link from the code:

Code:
&nbsp;&nbsp;&nbsp;<a target="_blank" href="{U_PRINTER_TOPIC}"><img src="{PRINTER_IMG}" border="0" alt="{L_PRINTER_TOPIC}" align="middle" /></a>


tnx alot for all your help
 
eagleeye1000







PostPosted: Tue Jun 23, 2009 11:30 am Reply with quote

oohhwww.. just noticed a new issue Sad

When you look between the left blocks and the center blocks a thin black horizontal line is there now. Any idea where to fix this?
 
duck







PostPosted: Tue Jun 23, 2009 12:28 pm Reply with quote

I don't see one between left and center but I do see one between right and center. I think this is because of a shadow on your image that is displayed there. You'll need to clean up that image story_home_07.jpg

BTW I noticed a little late now but generally here at Raven their policy is not to support sites without Credits in the footer so I recommend you put at the very least a link back to Raven there. While I am not an official Raven Team member I like to respect their policy practices so please put some credit to Raven in your themes footer.
 
eagleeye1000







PostPosted: Tue Jun 23, 2009 1:04 pm Reply with quote

That's weird I only see it between the left blocks and center one. What exactly do you mean with "cleaning the image up"?

You can see the line on the left very clearly also on the forum page. You see it just left of the center block for the forums.

As for the credits they are supposed to scroll over the footer image. I've seen it working before. Checked under preferences from the theme and the footer boxes are empty now. Don't know what I messed to cause that. But will ofcourse fix that issue.
 
duck







PostPosted: Tue Jun 23, 2009 1:24 pm Reply with quote

I see it on the right in forums as well. But what I mean is open the image and repaint the edge the right color as I think it has a black shadow. It could be that column has a border applied via CSS but I didn't see it.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Themes

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©