Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/O Code)
 Adding signatures to private messages
 New Topic  Reply to Topic
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 11 April 2008 :  09:51:45  Show Profile  Reply with Quote
Hi,

I want to have the option to include profile signatures in private messages.

So far I've coded :-

Response.Write " </font></td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" </font></td>" & vbNewLine & _
" <td bgColor=""" & strPopUpTableColor & """><textarea cols=""45"" name=""Message"" rows=""10"" wrap=""VIRTUAL""

onselect=""storeCaret(this);"" onclick=""storeCaret(this);"" onkeyup=""storeCaret(this);"" onchange=""storeCaret(this);"">" & Trim(CleanCode(TxtMsg)) &

"</textarea><hr><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><input name=""Sig"" id=""Sig"" type=""checkbox"" value=""yes""

checked><label for=""Sig"">Check here to include your profile signature.</label></td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" <tr>" & vbNewLine & _

In privatesend.asp

What do I add next.

<

Phil

cripto9t
Average Member

USA
881 Posts

Posted - 11 April 2008 :  19:57:27  Show Profile  Reply with Quote
I don't have pm running but I do have a copy, so I'm guessing at this.

Open privatesend_info.asp

find this
		txtMessage = ChkString(Request.Form("Message"),"message")
		txtSubject = ChkString(Request.Form("Subject"),"SQLString")


Add this after it
		if strSignatures = "1" and strDSignatures <> "1" then
			if Request.Form("sig") = "yes" and GetSig(strDBNTUserName) <> " " then
				txtMessage = txtMessage & vbNewline & vbNewline & ChkString(GetSig(strDBNTUserName), "signature" )
			end if
		end if

find this
		txtMessage = ChkString(Request.Form("Message"),"message")
		txtSubject = ChkString(strPMSubject,"SQLString")
		txtSubject = Replace(txtSubject, "RE: ", "")
		txtSubject = Replace(txtSubject, "FWD: ", "")

And add the same code as above under it

I think that will work
ps: this won't work for dynamic sigs. You'll have to make changes in another file for that. Search for "sig" in "topic.asp" to see how it's done there.<

    _-/Cripto9t\-_
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 12 April 2008 :  15:43:24  Show Profile  Reply with Quote
got dynamic signatures turned off

tired this and no luck

any more ideas ?<

Phil
Go to Top of Page

MaD2ko0l
Senior Member

United Kingdom
1053 Posts

Posted - 12 April 2008 :  17:07:49  Show Profile  Visit MaD2ko0l's Homepage  Reply with Quote
u need dynamic sigs turned on for that bit of code to work

if strSignatures = "1" and strDSignatures <> "1" then
that line is saying that if sigs and dynamic sigs are on then get the sig<

© 1999-2010 MaD2ko0l
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 13 April 2008 :  01:25:31  Show Profile  Reply with Quote
turn it on and still does not work, can i send the two files to someone to double check.

thanks in advance.<

Phil
Go to Top of Page

cripto9t
Average Member

USA
881 Posts

Posted - 13 April 2008 :  13:27:08  Show Profile  Reply with Quote
You should be getting an error saying it can't find the GetSig() function :)
Add in_func_members.asp to the includes
%>
<!--#INCLUDE FILE="config.asp" -->
<!--#INCLUDE FILE="inc_func_common.asp" -->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_member.asp" -->
<%


If that doesn't work, post a link to a txt file and I'll look at them.
<

    _-/Cripto9t\-_
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 14 April 2008 :  04:37:16  Show Profile  Reply with Quote
http://philsbbs.com/privatesend.txt

http://philsbbs.com/privatesend_info.txt

Thanks in advance for your help.<

Phil
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 16 April 2008 :  07:30:34  Show Profile  Reply with Quote
any news on this.<

Phil
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 17 April 2008 :  15:25:28  Show Profile  Reply with Quote
cripto9t and news on this.<

Phil
Go to Top of Page

cripto9t
Average Member

USA
881 Posts

Posted - 17 April 2008 :  18:57:09  Show Profile  Reply with Quote
Phil, I don't see anything wrong with it.
The input name is spelled "Sig" in Privatesend and "sig" in privatesend_info, so you can start there.
The next step I would take is see if I am getting all the right values.
Add these lines after "<%" in privatesend_info near the top of the page. and try to post a test pm.
Response.Write Request.Form("sig") & "<br >" & strSignatures & "<br />" & strDSignatures & "<br />" GetSig(strDBNTUserName)
Request.End

You should get

yes
1
0
signature text

if one of those values is missing then that's your problem, If not it should be working.<

    _-/Cripto9t\-_

Edited by - cripto9t on 17 April 2008 19:00:36
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 19 April 2008 :  19:00:12  Show Profile  Reply with Quote
Sig to sig had no inpact, about to try next suggestion.<

Phil
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 19 April 2008 :  19:04:55  Show Profile  Reply with Quote
i got:-

Microsoft VBScript compilation error '800a0401'

Expected end of statement

/privatesend_info.asp, line 48

Response.Write Request.Form("sig") & "<br >" & strSignatures & "<br />" & strDSignatures & "<br />" GetSig(strDBNTUserName)
----------------------------------------------------------------------------------------------------^
<

Phil
Go to Top of Page

MaD2ko0l
Senior Member

United Kingdom
1053 Posts

Posted - 19 April 2008 :  21:17:30  Show Profile  Visit MaD2ko0l's Homepage  Reply with Quote
Response.Write Request.Form("sig") & "<br >" & strSignatures & "<br />" & strDSignatures & "<br />" & GetSig(strDBNTUserName)
Request.End

;-) add the part in red<

© 1999-2010 MaD2ko0l
Go to Top of Page

cripto9t
Average Member

USA
881 Posts

Posted - 20 April 2008 :  18:20:05  Show Profile  Reply with Quote
Response.Write Request.Form("sig") & "<br >" & strSignatures & "<br />" & strDSignatures & "<br />" GetSig(strDBNTUserName)
Request.End

also Request.End should be Response.End
Response.Write Request.Form("sig") & "<br >" & strSignatures & "<br />" & strDSignatures & "<br />" & GetSig(strDBNTUserName)
Response.End

Sorry about that :)<

    _-/Cripto9t\-_
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 21 April 2008 :  18:11:54  Show Profile  Reply with Quote
Done that change and got

1
1
Phil Forum Admin

But the message was not sent, not even in out box.

I've uploaded new .txt see previous message for link.

Please advise.
<

Phil
Go to Top of Page

philsbbs
Junior Member

United Kingdom
397 Posts

Posted - 30 April 2008 :  10:14:00  Show Profile  Reply with Quote
bump<

Phil
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Next Page
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.12 seconds. Powered By: Snitz Forums 2000 Version 3.4.07