|
Post by tunescool on Dec 20, 2009 4:10:41 GMT -8
i wanted to add a whole other field for plans
|
|
|
Post by Wormopolis on Dec 20, 2009 8:35:38 GMT -8
you do that in that array. see how the other inputs have more boxes after them?
|
|
|
Post by tunescool on Dec 20, 2009 11:54:38 GMT -8
i wouldnt have any idea what i was doing
|
|
|
Post by Wormopolis on Dec 20, 2009 15:22:24 GMT -8
just duplicate one of the other ones like "watching" and change the names.
|
|
|
Post by tunescool on Dec 20, 2009 15:53:29 GMT -8
i didnt think it was that easy, thanks
|
|
|
Post by tunescool on Dec 20, 2009 17:06:28 GMT -8
can you get it so the next line is rite under the first one and not under the image
|
|
|
Post by Wormopolis on Dec 20, 2009 21:00:06 GMT -8
dunno.. it might be a task...[wayd:3:testing blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah-_-_-http://i197.photobucket.com/albums/aa250/WORMOPOLIS/sitebuttons/btn_home.jpg]
|
|
|
Post by Wormopolis on Dec 20, 2009 21:43:32 GMT -8
you will have to replace a chunk of code. look at the starting and ending lines:
var str = "<b><font color='"+firstColor+"'>"+opts[id][1]+"</font> "; var str2=""; if (st[0].match(/http:/)) { str2 += "<img align='absmiddle' src='"+st[0]+"' height='50' width='50' /> "; } else { str+=st[0]; }
var n = 1; while(st[n]){ if(st[n] != " "){ if(!st[n+1] && st[n].match(/http:/)){ str2 = "<img align='absmiddle' src='"+st[n]+"' height='50' width='50' /> "; } else { str += opts[id][n+1]+" "+st[n]+" "; } } n++; } nwtbl='<table width="100%"><tr><td width="5%">'+str2+'</td><td>'+str+'</td></tr></table>'; aFO[a].innerHTML = aFO[a].innerHTML.replace(waydReg, ""); var d = document.createElement("div"); d.innerHTML = nwtbl+"</b><hr size='1' class='hr' />"; aFO[a].parentNode.insertBefore(d, aFO[a]);
|
|
|
Post by tunescool on Dec 20, 2009 22:18:06 GMT -8
cool thanks
|
|
|
Post by tunescool on Jul 10, 2010 4:21:53 GMT -8
you said extending the text input cell probably couldnt be done, or putting the image cell above the text input cell. could i ask on pbs someday. and would i need chris' permission im so confused about all this other people working on other peoples codes because you do it all the time and they do it everyday on pbs.
|
|
|
Post by Wormopolis on Jul 10, 2010 19:58:17 GMT -8
It depends on the code really. certain codes I will ask the author to let me make a change. if the author hasnt been around in along time, and its a small change, I will make it, but huge changes I just cant do.
that particular code has a "do not edit" clause on it, and I had to ask Chris's permission to make the changes I did. If you post for more mods on PBS, someone might go for it, but it will be up to Chris if he allows it.
|
|
|
Post by tunescool on Aug 16, 2010 21:00:52 GMT -8
where can i make the text bigger and italic in the post Headlines - Jennifer Aniston @ The Switch Los Angeles Premiere - August 16th 2010 exactly like the example in each array, keeping the blue non italic but still changing the font size
<script type="text/Javascript"> // "What Are You Doing?" When Posting v1 By Chris // Do not redistirbute without permission of the creator // Mods by Wormopolis
var enableImg = "Yes"; // Should they be able to add an image before the information?
var firstColor = "#0000DD"; // Color for first object. Leave blank to disable.
var opts = [ // First set of quotations is the title in the dropdown // Each extra input box is defined by an extra set of quotations. If you're confused with editing, // just ask for help. ["Nothing..."], //default text in the drop down - no options ["Listening To", " Listening To - ", " By", " From"], ["Watching", " Watching - ", " On" ], ["Headlines", " Headlines - " ], ["Mood", " Mood - " ], ["Plans", " Plans - " ] ];
// DON'T EDIT if(enableImg){ for(a=1;a<opts.length;a++){ opts[a].push("<br>Image:"); } }
function changeBox(n){ var st = []; var p = document.postForm.message;
if(p.value.match(waydReg)){ n = RegExp.$1; st = RegExp.$2.split(/-_-_-/); p.value = p.value.replace(waydReg, ""); document.getElementById("waydselect").selectedIndex = n; }
var x = document.getElementById("waydhold"); var g = "";
for(a=1;a<opts[n].length;a++){ g += opts[n][a]+" <input id='waydbox"+a+"' "+(st[a-1] && st[a-1] != " "?"value='"+st[a-1]+"'":"")+" />"; }
x.innerHTML = g; }
function saveForm(){ if(document.postForm.message.value.length == 0) return;
var s = []; var n = 1;
while(document.getElementById("waydbox"+n)){ if(document.getElementById("waydbox"+n).value.length == 0){ if(n == 0) return; s.push(" "); } else { s.push(document.getElementById("waydbox"+n).value); } n++; } var x = document.getElementById("waydselect"); if (x.selectedIndex!=0 || s[0].length>1) { s = "[wayd:"+x.options[x.selectedIndex].value+":"+s.join("-_-_-")+"]"; document.postForm.message.value += s; }
}
var waydReg = /\[wayd:(\d+):(.+?)\]/i; var aFO = document.getElementsByTagName("font"); if(document.postForm && document.postForm.color && !document.postForm.to && !document.postForm.month){ var d = "<select id='waydselect' onchange='changeBox(this.options[this.selectedIndex].value)'>";
for(a=0;a<opts.length;a++){ d += "<option value='"+a+"'>"+opts[a][0]+"</option>"; } d += "</select>"; var n = document.postForm.icon.parentNode.parentNode; var r = n.parentNode.insertRow(n.rowIndex+2); var c1 = r.insertCell(0); c1.className = "windowbg"; c1.innerHTML = "<font size='2'>Tunes/Screen/Headlines/Mood/Plans</font>"; var c2 = r.insertCell(1); c2.className = "windowbg"; c2.innerHTML = d+" <span id='waydhold'></span>";
changeBox(0); if(document.addEventListener) document.postForm.addEventListener("submit", saveForm, true); else document.postForm.attachEvent("onsubmit", saveForm);
if(document.postForm.value.match(waydReg)){ document.postForm.value = document.postForm.value.replace(waydReg, ""); }
} else if(location.href.match(/action=display/) || document.title.match(/\s-\sSearch\sResults/)){ for(a=0;a<aFO.length;a++){ if(aFO[a].size == 2 && aFO[a].innerHTML.match(waydReg)){ var id = RegExp.$1; var st = RegExp.$2.split(/-_-_-/); var str = "<b><font color='"+firstColor+"'>"+opts[id][1]+"</font> "; var str2=""; if (st[0].match(/http:/)) { str2 += "<img align='absmiddle' src='"+st[0]+"' height='50' width='50' /> "; } else { str+=st[0]; }
var n = 1; while(st[n]){ if(st[n] != " "){ if(!st[n+1] && st[n].match(/http:/)){ str2 = "<img align='absmiddle' src='"+st[n]+"' height='50' width='50' /> "; } else { str += opts[id][n+1]+" "+st[n]+" "; } } n++; } nwtbl='<table width="100%"><tr><td width="5%">'+str2+'</td><td>'+str+'</td></tr></table>'; aFO[a].innerHTML = aFO[a].innerHTML.replace(waydReg, ""); var d = document.createElement("div"); d.innerHTML = nwtbl+"</b><hr size='1' class='hr' />"; aFO[a].parentNode.insertBefore(d, aFO[a]); } } } </script>
|
|
|
Post by Wormopolis on Aug 17, 2010 10:58:42 GMT -8
change
str += opts[id][n+1]+" "+st[n]+" ";
to
str += "<i>"+opts[id][n+1]+" "+st[n]+"</i> ";
|
|
|
Post by tunescool on Aug 17, 2010 11:30:10 GMT -8
that didnt do anything. n+1 is the font size?
|
|
|
Post by Wormopolis on Aug 17, 2010 22:29:41 GMT -8
if (st[0].match(/http:/)) { str2 += "<img align='absmiddle' src='"+st[0]+"' height='50' width='50' /> "; } else { str+=st[0]; }
change to
if (st[0].match(/http:/)) { str2 += "<img align='absmiddle' src='"+st[0]+"' height='50' width='50' /> "; } else { str+="<i>"+st[0]+"</i>"; }
|
|