Jump to content

Forum Notification


_Kurt
 Share

Recommended Posts

  • Replies 43
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Hi _Kurt,

Congrats with a nice project...:whistle:

I have a few notes/requests if you continue to work on it.

  • We don't all work through IE. So the "logged in as" requirement should only be required when you want notifications for PM's and personal stuff.
  • Don't monitor chat topics unless the user is logged in. (Thanks do @Manadar)
  • If many people start to use this script it will increase the load on the server. May I suggest that you investigate methods to ease the load?
  • Load the printable page rather than the nice looking forum page. (not sure if this eases the load on the server, but ...)
  • Only load the front page and look for changes in it matching any of the monitored topics.
  • A differential monitor pattern. Pages with resent updates are monitored more often than topics with less activity.
Oh, well I guess the list can go on and on. So, as I said, if you continue to work on it.

Happy scripting.

EDIT: Forgot about chat.

Edited by Uten
Link to comment
Share on other sites

Yes I know I have to be logged in to monitor chat pages..:whistle: Forgot to add that to the list. Don't scan for changes in chat topics if your not logged in.

Link to comment
Share on other sites

You don't have to be logged in to use the RSS. This parses the RSS and shows them in MsgBoxes.

Dim $start = 0

Dim $Message[100][4]
Dim $i = 0

If InetGet("http://www.autoitscript.com/forum/index.php?act=rssout&id=5","temp",1) <> 0 Then
    $RSS = FileRead("temp")
    $Array = StringRegExp($RSS,"<(.*?)>(.*?)</(.*?)>",3)
    If Not @error Then
        For $x = 0 to UBound($Array)-1
            If $start = 2 Then
                Switch $Array[$x]
                    Case "title"
                        $Message[$i][0] = StringReplace(StringReplace($Array[$x+1],"<![CDATA[", ""),"]]>","")
                        $x += 2
                    Case "link"
                        $Message[$i][1] = $Array[$x+1]
                        $x += 2
                    Case "starter"
                        $Message[$i][2] = $Array[$x+1]
                        $x += 2
                    Case "poster"
                        $Message[$i][3] = $Array[$x+1]
                        $x += 2
                        $i += 1
                EndSwitch
            EndIf
            If StringInStr($Array[$x],"http://www.autoitscript.com/forum/index.php") Then
                $start += 1
                If $start = 2 Then
                    $x += 1
                EndIf
            EndIf
        Next
        For $x = 0 To UBound($Message)-1
            If $Message[$x][0] Then
                MsgBox(0, "", "Topic Title: " & @TAB & $Message[$x][0] & @CRLF & _
                "URL: " & @TAB & @TAB & $Message[$x][1] & @CRLF & _
                "Topic Starter: " & @TAB &  $Message[$x][2] & @CRLF & _
                "New Reply Poster: " & @TAB &  $Message[$x][3] & @CRLF)
            EndIf
        Next
    EndIf
Else
    MsgBox(0, "", "Error reading rss")
EndIf
Link to comment
Share on other sites

@Uten - Thanks for the reply. I like hearing suggestions, and I will make an attempt at them (espescially the possible problem of increasing the load on the server).

A differential monitor pattern. Pages with resent updates are monitored more often than topics with less activity.

Not too sure how to create that type of pattern. I will put this at the bottom of the list however.

@Manadar - Great example using the rrs, will probably add that method instead of my current way of checking for new replies (_InetGet(..), etc.).

Hopefully I have some spare time these upcoming days, :whistle:

Kurt

Awaiting Diablo III..

Link to comment
Share on other sites

A topic with no replies seems to return an error (invalid link).

Test against this for now.

Link to comment
Share on other sites

A topic with no replies seems to return an error (invalid link).

Test against this for now.

Should be fixed, uploaded attachment. Working on Manadar's idea to log you in for Non-IE Users with the little time I have. That will solve all "logged in as" problems.

Gotta run,

Kurt

Awaiting Diablo III..

Link to comment
Share on other sites

Sorry for these late updates, but I'll have more spare time from now on (hopefully :whistle: ). Added Manadar's suggestion of Automatically logging you in (optional). I'd like to thank DaleHohm for giving me a few pointers on the IE stuff. Haven't found a more "efficient" way to retrieve source code.

Enjoy,

Kurt

Awaiting Diablo III..

Link to comment
Share on other sites

glad to have a script like this dude...people can do this stuff, but you are the one that has the good ideas!

I have a slight bit of a problem, I dont know if its just me getting this or everyone, but when a topic is replied to, the message comes up and everything and I can click and do all that, but it comes up 10 times afterwards. And ive studied it, its only 10 times (no idea why) and then it stops. Is there a way to make the message stop popping up after one time, or after you have clicked on it? I've looked through it and all, but if its just my little brain having trouble early in the morning, just tell me. lol.

~Nikolai

Edited by Nikolai
Link to comment
Share on other sites

Thanks for the reply Nikolai, I will be looking into it, but I can assure you that I will be able to fix this. I'm glad people are reporting bugs :whistle: , I'll try to solve this problem ASAP.

Kurt

EDIT: Wow, I really love your avatar!!

Edited by _Kurt

Awaiting Diablo III..

Link to comment
Share on other sites

  • 4 months later...

Can this be changed to use on any forum? Not just this one? I'd like to be able to use this on many different forums that I frequent and without having to be logged into the forum. For instance this runs in the tray or something then notifies me of a new PM or post and at that time I go look at it as I was busy doing other things and did not want IE open.

The SuperFlyChetGuy
Link to comment
Share on other sites

  • 9 months later...
  • 4 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...