Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/O Code)
 Add a post in a forum

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!
Before posting, make sure you have read this topic!

Screensize:
UserName:
Password:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
   

T O P I C    R E V I E W
kyodai Posted - 20 April 2010 : 14:14:38
I know it sounds stupid, but i would like to have an asp page that adds a post to a (secret) forum. We have an app which is checking our backend server (The one for videos, images and so on) and can report system state by calling a website.

What i need is an asp page that adds a post to a specific forum, like when i call it http://mysite.com/pager.asp?Message=Server%20Down&Detail=The%20Server%20is%20down%20since%2009:34

so it would make a post in the admin forum that has the subject "Server down" and the message text "The Server is down since 09:34".

I fumbled a lot with it but simply didn't get it to work, it looks like it should work, but i never see the post.



I tried it with a raw SQL statement as i had no better idea. Can anyone help?



strSql = "INSERT INTO " & strTablePrefix & "TOPICS ("
				strSql = strSql & " CAT_ID"
				strSql = strSql & ", FORUM_ID"
				strSql = strSql & ", T_SUBJECT"
				strSql = strSql & ", T_AUTHOR"
				strSql = strSql & ", T_MESSAGE"
				strSql = strSql & ") VALUES ("
				strSql = strSql & " '" & "2" & "'"
				strSql = strSql & ", '" & "60" & "'"
				strSql = strSql & ", '" & "Test Subject" & "'"
				strSql = strSql & ", '" & "1" & "'"
				strSql = strSql & ", '" & "The Server is down test test test" & "'"

my_Conn.Execute (strSql)
2   L A T E S T    R E P L I E S    (Newest First)
cripto9t Posted - 21 April 2010 : 10:50:14
you need inc_header_short or inc_header because the database connection (my_Conn) is created and opened there. It's closed and destroyed in inc_footer_short.
kyodai Posted - 20 April 2010 : 15:44:18
nvm, i just added

<!--#INCLUDE FILE="inc_sha256.asp" -->
<!--#INCLUDE FILE="inc_header_short.asp" -->
<!--#INCLUDE FILE="inc_func_member.asp" -->

besides config.asp to the includes and it works. Dun get why these were required, prolly something i overlooked. Anyways, what counts is it works now.

Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.07 seconds. Powered By: Snitz Forums 2000 Version 3.4.07