Rei Kon
Junior Member
Posts: 52
Rei Kon said 0 great things
|
Post by Rei Kon on Nov 12, 2011 14:44:14 GMT -8
Wormo is teleport=null meant to have a ' at the end of it by any chance or not? Both teleport=null; and +dt; do not have a closing ' even though they have an opening ' if that makes any sense?
edit: Okay doing that now gets it to jump it to the right staff board (the edit you told me to make) so far its still popping up that pop up at least twice - once when moved once when you open the thread and in safari it is still popping up all over the place
edit b: __utma=1.1562829923.1321138086.1321138086.1321138086.1; __utmb=1.7.10.1321138086; __utmc=1; __utmz=1.1321138086.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); teleport=null; grvinsights=2f91b99a873a15fb12a4edabfc126a3b
cookie pop up output thing, I am having to click around to get the pop up to repeat itself mind
|
|
|
Post by Wormopolis on Nov 12, 2011 15:38:08 GMT -8
<script type="text/javascript"> <!-- // move topic teleport // popup when moving a topic for destination or source relocation // by wormopolis - [url]www.wormocodes.com[/url] // do not repost - keep header intact
if (location.href.match(/action=movetopic/)) {
function rememberDest() { var mtdest=document.getElementsByName('moveto')[0].value; if (mtdest && mtdest!='') { var dt=new Date(); dt.setFullYear(dt.getFullYear()+1); document.cookie="teleport="+mtdest +'; expires='+dt; } } for (inp=document.getElementsByTagName('input'), ii=0; ii<inp.length; ii++) { if (inp[ii].type=='submit' && inp[ii].value=='Move Thread') { if (inp[ii].addEventListener) { inp[ii].addEventListener('click',rememberDest,true); } else { inp[ii].attachEvent('onclick',rememberDest); } break; } } } if (document.cookie.match(/teleport=(.*?)(;|$)/)) { var bname=RegExp.$1; var bTitle=''; var fj=document.getElementById('forumjump'); for (ff=0; ff<fj.options.length; ff++) { if (fj.options[ff].value.match(new RegExp('board='+bname+'($|&)',''))) { bTitle=fj.options[ff].innerHTML; break;} } bTitle=bTitle.replace(/^\s?-*?\s/,''); var dt=new Date(); dt.setFullYear(dt.getFullYear()-1); document.cookie='teleport=null;expires='+dt; if (bname!='null' && confirm('Topic moved successfully. go to board "'+bTitle+'", or cancel to stay here?')) {location.href='/index.cgi?board='+bname;} }
// --> </script>
alright.. see if safari likes that one...
|
|
|
Post by tunescool on Nov 12, 2011 16:39:36 GMT -8
everything seems to be working fine wormer. great code, thanks for your help Rei Kon
|
|
|
Post by Wormopolis on Nov 12, 2011 16:43:25 GMT -8
Safari is a pain in my ass...
|
|
|
Post by tunescool on Nov 29, 2011 6:34:41 GMT -8
wormer when moving topics in adv mod in the thread page it doesnt bring the pop up or change boards. could you add that real quick
|
|
|
Post by Wormopolis on Nov 29, 2011 13:28:59 GMT -8
try this.. dunno if it will work though since adv moderation kinda messes with things.
change
if (location.href.match(/action=movetopic/)) {
to
if (location.href.match(/action=(movetopic|advancedmoderation)/)) {
|
|
|
Post by tunescool on Nov 29, 2011 17:48:53 GMT -8
it didnt do anything, it was a line rite at the top rite
|
|
|
Post by Wormopolis on Nov 29, 2011 23:46:08 GMT -8
advanced moderation changes the URL location... I dunno if I can make that work if I dont have something to go off of.
|
|
|
Post by tunescool on Nov 30, 2011 1:10:05 GMT -8
alrite thats fine then, it wont work in advanced then
|
|
|
Post by tunescool on May 25, 2012 6:18:59 GMT -8
wormer i have a big situation, when i started my forum i made all those boards for Featured Celebs and now after years some of them arent as popular and i want to move all their threads to a thru m or whatever. but i have to copy every new thread url to put in their new archive thread since its in a new board. so when you move a thread it gets lost on whatever page in the new board.
after moving them it just takes you to a board. could you add an option in the code(in the code to enable it and turn off the Go To The Board) that would take you to the thread you moved in its new board?
<script type="text/javascript"> <!-- // move topic teleport // popup when moving a topic for destination or source relocation // by wormopolis - [url]www.wormocodes.com[/url] // do not repost - keep header intact
if (location.href.match(/action=movetopic/)) {
function rememberDest() { var mtdest=document.getElementsByName('moveto')[0].value; if (mtdest && mtdest!='') { var dt=new Date(); dt.setFullYear(dt.getFullYear()+1); document.cookie="teleport="+mtdest +'; expires='+dt; } } for (inp=document.getElementsByTagName('input'), ii=0; ii<inp.length; ii++) { if (inp[ii].type=='submit' && inp[ii].value=='Move Thread') { if (inp[ii].addEventListener) { inp[ii].addEventListener('click',rememberDest,true); } else { inp[ii].attachEvent('onclick',rememberDest); } break; } } } if (document.cookie.match(/teleport=(.*?)(;|$)/)) { var bname=RegExp.$1; var bTitle=''; var fj=document.getElementById('forumjump'); for (ff=0; ff<fj.options.length; ff++) { if (fj.options[ff].value.match(new RegExp('board='+bname+'($|&)',''))) { bTitle=fj.options[ff].innerHTML; break;} } bTitle=bTitle.replace(/^\s?-*?\s/,''); var dt=new Date(); dt.setFullYear(dt.getFullYear()-1); document.cookie='teleport=null;expires='+dt; if (bname!='null' && confirm('Topic moved successfully. go to board "'+bTitle+'", or cancel to stay here?')) {location.href='/index.cgi?board='+bname;} }
// --> </script>
|
|
|
Post by Wormopolis on May 25, 2012 22:27:15 GMT -8
There isnt a way for it to know what the new thread id is. it gets a new id when it is created and the only way to get it is to go into that thread itself.
|
|
|
Post by tunescool on May 26, 2012 2:11:32 GMT -8
alrite ill leave a moved message for every thread but itll take forever
|
|