Forum Hosting  

Go Back   Forum Hosting > IPB Support > IPB General Support

IPB General Support Post your questions here, no bug reports.


Closed Thread
 
LinkBack Thread Tools Display Modes
Old 09-12-2005, 10:41 AM   #1 (permalink)
Active Forumer
 
elmazagangi's Avatar
 
Join Date: Aug 2005

Location: Alexandria; Egypt
Posts: 363
Rep Power: 4 elmazagangi is on a distinguished road
fTrader: (5)
fBuck$: 394.0
Bank: 678.6
Total fBuck$: 1,072.6

My Forumer
My Country:
Send a message via ICQ to elmazagangi Send a message via MSN to elmazagangi Send a message via Yahoo to elmazagangi
Cool Here is the code that send automatic PM to the newest member

Hi,
I got this code from a friend, it must send PM to the newest registered member automaticlly, but i have one problem that i don't know where to past it. Can somebody search for this?

Here is the code:

Code:
<script language="javascript" type="text/javascript">
<!--

appearFrom = ["Admin", 1]
msgTitle = "Title"
msgContents = "Contents.\n" + "Contents.\n"

// Write in the contents
// \n is the simple for go down .Never use enter.
// + is space between to line
// ok happy"

home = "http://"+location.hostname
home += location.pathname.match(/\/[^\/]+\//) ? "/" + location.pathname.substr(1).substr(0, location.pathname.substr(1).indexOf("/") + 1) : location.pathname + "/"
home += "index.php?"

if(document.forms['REG'])
document.forms['REG'].onsubmit = function()
{
if(!Validate())
return false
document.cookie = "newMember=1; expires=" + new Date("1/1/2010").toGMTString()
return true
}

userLinks = document.getElementById("userlinks")
userName = userLinks.getElementsByTagName("A")[0].innerHTML.replace(/<[^>]+>/g, "")

if(userLinks.innerHTML.match("Logged in")&&document.cookie.match("newMember=1"))
{
document.cookie = "newMember=0; expires=" + new Date().toGMTString()
document.write("<iframe src='" + home + "act=Msg&CODE=4&MODE=1&entered_name=" + escape(userName) + "&msg_title=" + escape(msgTitle) + "&Post=" + escape(msgContents) + "' style='display:none'></iframe>")
alert("You have a new personal message from "+ appearFrom[0])
}

if(location.href.match(/act=Msg&CODE=0*1/))
{
td = document.getElementsByTagName("TD")
for(i = 0; i < td.length; i++)
if(td[i].innerHTML.replace(/<[^>]+>/g, "") == msgTitle)
{
a = td[i + 1].getElementsByTagName("A")
a[0].href = home + "showuser=" + appearFrom[1]
a[0].innerHTML = appearFrom[0]
a[1].href = a[1].href.replace(/MID=\d+/, "MID=" + appearFrom[1])
}
}

if(location.href.match(/MSID=\d+/))
{
b = document.getElementsByTagName("B")
for(i = 0; i < b.length; i++)
if(b[i].innerHTML == msgTitle && b[i].parentNode.className == "postdetails")
{
td = document.getElementsByTagName("TD")
for(n = 0; n < td.length; n++)
if((td[n].className == "post1") && td[n].width != "100%")
{
a = td[n - 2].getElementsByTagName("A")[0]
if(a.innerHTML.replace(/<[^>]+>/g,"") != userName)
break
a.href = home + "showuser=" + appearFrom[1]
a.innerHTML = appearFrom[0]
div = td[n + 1].getElementsByTagName("DIV")
for(x = 0; x < div.length; x++)
if(div[x].className == "signature")
div[x].removeNode(true)
a = td[n + 3].getElementsByTagName("A")
for(x = 0; x < a.length; x++)
if(a[x].href.match(/MID=\d+/))
a[x].href = a[x].href.replace(/MID=\d+/, "MID=" + appearFrom[1])
td[n + 1].colSpan = "2"
td[n].removeNode(true)
break
}
break
}
}

//-->
</script>
I hope i will get help here, thanks.

elmazagangi is offline  
Old 09-12-2005, 10:57 AM   #2 (permalink)
Banned User
 
Adam's Avatar
 
Join Date: Aug 2005

Location: Wales
Posts: 3,175
Rep Power: 0 Adam is on a distinguished road
fTrader: (51)
fBuck$: 5,893.6
Bank: 0.6
Total fBuck$: 5,894.2

My Forumer
My Country:
Send a message via AIM to Adam Send a message via MSN to Adam
Default Re: Here is the code that send automatic PM to the newest member

Must be in board index
Adam is offline  
Old 09-12-2005, 11:16 AM   #3 (permalink)
Active Forumer
 
elmazagangi's Avatar
 
Join Date: Aug 2005

Location: Alexandria; Egypt
Posts: 363
Rep Power: 4 elmazagangi is on a distinguished road
fTrader: (5)
fBuck$: 394.0
Bank: 678.6
Total fBuck$: 1,072.6

My Forumer
My Country:
Send a message via ICQ to elmazagangi Send a message via MSN to elmazagangi Send a message via Yahoo to elmazagangi
Default Re: Here is the code that send automatic PM to the newest member

I tried, i didn't work on it.
Did you tried it?

elmazagangi is offline  
Old 09-12-2005, 11:20 AM   #4 (permalink)
Banned User
 
Adam's Avatar
 
Join Date: Aug 2005

Location: Wales
Posts: 3,175
Rep Power: 0 Adam is on a distinguished road
fTrader: (51)
fBuck$: 5,893.6
Bank: 0.6
Total fBuck$: 5,894.2

My Forumer
My Country:
Send a message via AIM to Adam Send a message via MSN to Adam
Default Re: Here is the code that send automatic PM to the newest member

I will now
Adam is offline  
Old 09-12-2005, 11:42 AM   #5 (permalink)
Elite Forumer
 
bart5986's Avatar
 
Join Date: Oct 2004

Location: Australia, Brisbane
Posts: 2,786
Rep Power: 7 bart5986 is on a distinguished road
fTrader: (8)
fBuck$: 4,499.1
Bank: 0.1
Total fBuck$: 4,499.1

My Forumer
My Country:
Default Re: Here is the code that send automatic PM to the newest member

did your friend say it works on forumer? I doubt it would...

bart5986 is offline  
Old 09-12-2005, 11:59 AM   #6 (permalink)
Active Forumer
 
elmazagangi's Avatar
 
Join Date: Aug 2005

Location: Alexandria; Egypt
Posts: 363
Rep Power: 4 elmazagangi is on a distinguished road
fTrader: (5)
fBuck$: 394.0
Bank: 678.6
Total fBuck$: 1,072.6

My Forumer
My Country:
Send a message via ICQ to elmazagangi Send a message via MSN to elmazagangi Send a message via Yahoo to elmazagangi
Default Re: Here is the code that send automatic PM to the newest member

He don't know if it works on forumer or not.

elmazagangi is offline  
Old 09-12-2005, 04:38 PM   #7 (permalink)
Banned
 
Mark's Avatar
 
Join Date: Feb 2005

Posts: 8,730
Rep Power: 0 Mark is on a distinguished road
fTrader: (44)
fBuck$: 2,275.0
Bank: 0.0
Total fBuck$: 2,275.0

My Forumer
My Country:
Default Re: Here is the code that send automatic PM to the newest member

Can a mod please tell me if this is truly possible, and where can I put this?


P.S. I have 2 boards, and one is not Forumer, so if it is possible- regardless of Forumer compatibility, please say so.



-Mark
Mark is offline  
Old 09-13-2005, 06:01 AM   #8 (permalink)
Active Forumer
 
Iyeru's Avatar
 
Join Date: Jul 2005

Posts: 326
Rep Power: 4 Iyeru is on a distinguished road
fTrader: (0)
fBuck$: 2,332.7
Bank: 0.0
Total fBuck$: 2,332.7

My Forumer
My Country:
Default Re: Here is the code that send automatic PM to the newest member

You should also try putting it in the Board Header. ACP >> Skins & Templates >> HTML Templates >> Global HTML elements >> Board Header

put it above the giant JS Code.

EDIT: ERP... your code is set to operate only on the index.php? part. Put it in the board header and then try going to: http://YOURFORUM.#.forumer.com/index.php?

^^With the questionmark there. I know I have to have the questionmark then nothing after it to do the IPDynamic Lite as first page modification.

Last edited by Iyeru; 09-13-2005 at 06:04 AM.

Banned FMODS.com Member
Do not give me support I do not already know...
Iyeru is offline  
Old 09-13-2005, 07:56 AM   #9 (permalink)
VIP Team
 
shane's Avatar
 
Join Date: Feb 2004

Location: Kansas City, MO
Posts: 3,769
Rep Power: 8 shane is on a distinguished road
fTrader: (14)
fBuck$: 1,377.1
Bank: 0.0
Total fBuck$: 1,377.1

My Forumer
My Country:
Default Re: Here is the code that send automatic PM to the newest member

Since this isn't part of the default Forumer board install, we don't offer official support here. However, you can head over to FMods.com (A Forumer-owned company), and we'll be able to help ya out with it there.

Thanks for understanding.

-shane

Owner/CEO - ComputerHelpForum.org
Administrator - Revision3.com
Administrator - Scopetech.net
Lowe's (my employer) Department Manager - Lumber/Building Materials/Millwork
shane is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Quick Arcade V1.0 jcink General Chat Area 118 10-04-2006 10:38 PM
The newest registered member elmazagangi IPB Skinning Help 6 08-18-2005 03:42 AM
Add Code To Body And Head Tags Dimitri IPB General Support 1 12-20-2004 04:11 PM
Send Automatic Pm To Newbies mclaren IPB General Support 3 08-08-2004 05:33 PM
Quick Arcade V 1.0 12369874 IPB Skinning Help 11 08-08-2004 01:14 PM