var topUpdate = -1; var CATEGORIES = new Array; var CATEGORIESDEF = new Array; var CATEGORIESID = new Array; var CATEGORIESLAUNCH = new Array; var NUMBERCATEGORIES = 29; var NUMBERLAUNCHCATEGORIES = 0; CATEGORIES = {0 : "Websearch", 1 : "Images", 2 : "Entertainment", 3 : "News", 4 : "Reference", 5 : "Shopping", 6 : "Video", 7 : "Auctions", 8 : "Cars", 9 : "Blogs", 10 : "Downloads", 11 : "Directories", 12 : "Education", 13 : "Games", 14 : "Government", 15 : "Finance", 16 : "Friends", 17 : "Health", 18 : "Jobs", 19 : "Local", 20 : "Maps", 21 : "Personals", 22 : "Real Estate", 23 : "Tech", 24 : "Travel", 25 : "Webmaster", 26 : "Weather", 27 : "My Category", 28 : "tits"}; CATEGORIESDEF = {0 : "Web: Type in a websearch", 1 : "Images: Type in an image search", 2 : "Entertainment: Type in your search", 3 : "News: Type in a news search", 4 : "Reference: Type in a search", 5 : "Shopping: Type in a product", 6 : "Video: Type in a video search", 7 : "Auctions: Type in a product", 8 : "Cars: Type in a Make", 9 : "Blogs: Type in a search", 10 : "Downloads: Type something to download", 11 : "Directories: Type in a business type & area", 12 : "Education: Type in a research topic", 13 : "Games: Type in a game title", 14 : "Government: Browse government sites", 15 : "Finance: Type in a finance search", 16 : "Friends: Type in a person`s name", 17 : "Health: Type in your symptoms/drug/disease", 18 : "Jobs: Type in a job and area", 19 : "Local: Type in a search", 20 : "Maps: Browse the best maps sites", 21 : "Personals: Currently you can only browse these sites", 22 : "Real Estate: Type in a postcode", 23 : "Tech: Type in a tech search", 24 : "Travel: Type in a travel search", 25 : "Webmaster: Type in a search", 26 : "Weather: Type in a city", 27 : "", 28 : ""}; CATEGORIESID = {0 : "287", 1 : "293", 2 : "276", 3 : "282", 4 : "286", 5 : "288", 6 : "294", 7 : "296", 8 : "267", 9 : "301", 10 : "273", 11 : "272", 12 : "274", 13 : "297", 14 : "292", 15 : "278", 16 : "283", 17 : "280", 18 : "275", 19 : "300", 20 : "299", 21 : "284", 22 : "285", 23 : "295", 24 : "290", 25 : "291", 26 : "298", 27 : "302", 28 : "303"}; CATEGORIESLAUNCH = {0 : "1", 1 : "1", 2 : "1", 3 : "1", 4 : "1", 5 : "1", 6 : "1", 7 : "2", 8 : "2", 9 : "3", 10 : "2", 11 : "2", 12 : "2", 13 : "2", 14 : "2", 15 : "2", 16 : "2", 17 : "2", 18 : "2", 19 : "3", 20 : "3", 21 : "2", 22 : "2", 23 : "2", 24 : "2", 25 : "2", 26 : "3", 27 : "3", 28 : "3"};var topShiftFactor = -1; var topShiftFactorID = -1; function draw_top_categories() { var myString = ''; document.getElementById('growBox').innerHTML = myString; Sortable.create('child_1' ,{tag:"li", only:"categories", constraint:"horizontal", overlap:"horizontal", onUpdate: function() { var theOrders1 = Sortable.sequence('child_1'); var theCookieArray = ""; for(var i = 0; i < theOrders1.length; i++) { if(i > 0) theCookieArray += ","; theCookieArray += CATEGORIESID[theOrders1[i]]; } createCookie("categories_6",theCookieArray,365); storeSettings("features_title", "Join Wookah", "Keep your customizations, add new sites and more. Join Wookah Now!", "1px", "80px"); } } ); } function scrollToTop() { var agt=navigator.userAgent.toLowerCase(); var is_ie = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1)); try{ if(topShiftFactor >= 0 && is_ie) { var distFromLeft = document.getElementById('grow_' + (topShiftFactor + 1)).offsetLeft; var totalWidth = document.getElementById('grow_' + (topShiftFactor + 1)).offsetWidth; topShiftFactor = -1; topShiftFactorID = -1; var scrollSize = distFromLeft - 660 + totalWidth; scrollSize = scrollSize / 10; scrollSize = Math.floor(scrollSize); scrollSize *= 10; if(scrollSize > 0) ScrollUntil('sup_search_bar', scrollSize, 680); } } catch(ex) {} } function showTopMenu() { var myString = ''; var numFound = 0; for(var i = 0; i < 29; i++) { if(CATEGORIESLAUNCH[i] == 2) { if(numFound != 0) myString += "
"; myString += '' + CATEGORIES[i] + ''; numFound++; } } if(numFound != 0) myString += "
"; myString += "Edit"; document.getElementById('moreMenu').innerHTML = myString; } function storeCategoryCookie() { var theCookieArray = ""; for(var i = 0; i < 29; i++) { if(CATEGORIESLAUNCH[i] == 1) { if(i > 0) theCookieArray += ","; theCookieArray += CATEGORIESID[i]; } } createCookie("categories_6",theCookieArray,365); } function moreOnClick(vv) { CATEGORIESLAUNCH[vv] = 1; getNumLaunchCategories(); if(NUMBERLAUNCHCATEGORIES > 7) dropLastCategory(vv); hideBar('moreMenu'); topShiftFactorID = CATEGORIESID[vv]; draw_top_categories(); growMe(document.getElementById('grow_' + (vv + 1)), (vv + 1), CATEGORIES[vv],CATEGORIESID[vv] , true); scrollToTop(); currentCat(CATEGORIESID[vv]); storeCategoryCookie(); } function getNumLaunchCategories() { var count = 0; for(var i = 0; i < 29; i++) { if(CATEGORIESLAUNCH[i] == 1) count += 1; } NUMBERLAUNCHCATEGORIES = count; } function dropLastCategory(vv) { var index = 0; for(var i = 0; i < 29; i++) { if(i != vv && CATEGORIESLAUNCH[i] == 1) index = i; } CATEGORIESLAUNCH[index] = 2; } function clickAndSubmit(vv) { var myCurCat = getCategoryPlace(vv); draw_top_categories(); growMe(document.getElementById('grow_' + (myCurCat + 1)), (myCurCat + 1), CATEGORIES[myCurCat],CATEGORIESID[myCurCat] , true); scrollToTop(); showCategoryBar(vv); /*if(warningNumber == 0) { displayClickSubmitContent(); var myEle = document.getElementById('bottom_box'); var myEle3 = document.getElementById('popover_2'); myEle3.style.width = myEle.offsetWidth; showBar('popover_2'); var myAdTimer2 = setTimeout("hideBar('popover_2');", 5000); warningNumber++; }*/ } function displayClickSubmitContent() { document.getElementById('popover_2').innerHTML = '
'; } function getCategoryPlace(vv) { for(var i = 0; i < 29; $i++) { if(CATEGORIESID[i] == vv) return i; } return 0; } var http = createRequestObject(); var randomizer = 0; var timeString = '1228284692'; function createRequestObject() { var xmlhttp; try { xmlhttp=new ActiveXObject("Msxml2.XMLHTTP"); } catch(e) { try { xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");} catch(f) { xmlhttp=null;} } if(!xmlhttp && typeof XMLHttpRequest!="undefined") { xmlhttp = new XMLHttpRequest(); } return xmlhttp; } function doAjax(fileAndParams, catchFunction) { try{ http.open('GET', fileAndParams, true); http.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded'); http.onreadystatechange = catchFunction; http.send(null);} catch(e) {} } function doAjaxPost(file, Params, catchFunction) { try{ http.open('POST', file , true); http.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded'); http.onreadystatechange = catchFunction; http.send(Params + '&rando=' + timeString + (randomizer++)); } catch(e) {} } function noFunction() { } function insertValues() { if(http.readyState == 4) { document.getElementById('popover_links').innerHTML = http.responseText; var linkString = 'http://www.wookah.com.au/#' + getCategoryName() + '/' + getSubCategoryName() + '/' + getSiteName(currentGlowTabID); var siteInfo = getSiteURLs(currentGlowTabID); if(topform.q.value != '') linkString += '/' + topform.q.value; linkString = linkString.replace(/ & /g, '___'); linkString = linkString.replace(/ /g,'_'); if (window.sidebar) document.getElementById('dl_bookmark').innerHTML = "You can use the link above to add to your Bookmarks"; else if (window.external) document.getElementById('dl_bookmark').innerHTML = "Add to Favorites "; else if (window.opera && window.print) document.getElementById('dl_bookmark').innerHTML = "Add Bookmark "; document.getElementById('dl_url').innerHTML = linkString; document.getElementById('dl_url_input').value = linkString; document.getElementById('dl_links').innerHTML = "View site in a new window
View site in a new window without Wookah "; try{ document.getElementById('dl_b').value = siteInfo[0]; document.getElementById('dl_u').value = siteInfo[1]; } catch(ex) { } } } function wookmarkAdded() { if(http.readyState == 4) { var div = document.getElementById('dl_wookmark_form'); div.innerHTML = "Wookmark Added"; } } function showCustom(value) { var input = document.getElementById('custom_wookmark'); if(value != "-1") { hideBar('custom_wookmark'); input.disabled = true; } else { showBar('custom_wookmark'); input.disabled = false; } } function CreateBookmarkLink(title, url) { if( window.external ) { /* IE Favorite */ window.external.AddFavorite( url, title); } else if(window.opera && window.print) { /* Opera Hotlist */ return true; } }