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)
 Some questions about images, avatars and smilies
 New Topic  Reply to Topic
 Printer Friendly
Previous Page
Author Previous Topic Topic Next Topic
Page: of 2

texanman
Junior Member

United States
410 Posts

Posted - 08 July 2008 :  11:33:00  Show Profile  Reply with Quote
I think Shaggy had a tweak that allows image in the topic (not replies). I adopted it and it is great. Let me see if I can find it.<
Go to Top of Page

radiodelicate
New Member

Sweden
53 Posts

Posted - 08 July 2008 :  11:42:35  Show Profile  Visit radiodelicate's Homepage  Reply with Quote
quote:
Originally posted by texanman

I think Shaggy had a tweak that allows image in the topic (not replies). I adopted it and it is great. Let me see if I can find it.


I'm not sure if I understand exactly what you mean. If you are referring to my first question, I've already got it fixed. Thanks anyway <
Go to Top of Page

Carefree
Advanced Member

Philippines
4217 Posts

Posted - 08 July 2008 :  12:00:52  Show Profile  Reply with Quote
quote:
Originally posted by radiodelicate

it's all pages.
I will check if things get better when I remove the changes as soon as I get home from work, don't have access to my files from here.
I really hope it's the image tweak that slows things down, because other wise I'm clueless, and more or less up shit-creek without a paddle...

uhm, never mind. I checked the rest of the site, outside of the forum, and it's well slow as well. I suppose it's the server that has decided to run a bit extra slow for some reason :/

edit: the speed is back to normal again, so it certainly didn't have anything to do with the mod.



Check your computer indexing & defragmentation. Sometimes a defrag taking place while your forum is in use can make things horrendously slow. Microsoft's default indexing on XP is bad enough, but adding the IIS indexing to it can also make things drag. The forum's search ability works well enough without having every character indexed constantly.

If you find that two indexing programs are autostarting, try disabling one or both. Nero Burning ROM also installs an indexer - so you could have three. None are needed.<
Go to Top of Page

JamesPossible
Starting Member

1 Posts

Posted - 31 January 2009 :  17:54:45  Show Profile  Reply with Quote
Hi radiodelicate and others, I am new to Snitz, just wanted a simple ASP forum that I could easily manage and from appearances looks like modify easily as well.

Anyways, I just wanted a simple way to display photos to posts and this is what I did...keeping that in mind all data arrays where modified by appending to rather than changing the structure in the middle.

After scanning the code and identifying topic.asp as the file to modify I ended up making the following mods...simple was all I had on my mind.



Step 1:

130	Member_Country = rsTopic("M_COUNTRY")

Insert:        Member_PhotoURL = rsTopic("M_PHOTO_URL")

131	Topic_Date = rsTopic("T_DATE")

----------------------------------------

Step 2:


290	strSql = strSql & ", R.R_LAST_EDITBY, R.R_SIG, R.R_STATUS, R.R_DATE"

Modified:	strSql = strSql & ", R.R_LAST_EDITBY, R.R_SIG, R.R_STATUS, R.R_DATE, M.M_PHOTO_URL"

----------------------------------------

Step 3:

510             rR_DATE = 21
511             if CanShowSignature = 1 then
512                rM_SIG = 22
513             end if


510             rR_DATE = 21

Insert:            rM_PHOTO_URL = 22

511             if CanShowSignature = 1 then
Modified 513:      rM_SIG = 23
512             end if

----------------------------------------

Step 4:

538             Reply_Date = arrReplyData(rR_DATE, iForum)
539             if CanShowSignature = 1 then
540                Reply_MemberSig = trim(arrReplyData(rM_SIG, iForum))
541             end if


538             Reply_Date = arrReplyData(rR_DATE, iForum)

Insert:            Reply_PhotoURL = arrReplyData(rM_PHOTO_URL, iForum)

539             if CanShowSignature = 1 then
540                Reply_MemberSig = trim(arrReplyData(rM_SIG, iForum))
541             end if

----------------------------------------

Step 5:

560             Response.Write	"                </p>" & vbNewLine & _
561                             "                <p>" & vbNewLine
562             if strCountry = "1" and trim(Reply_MemberCountry) <> "" then


560             Response.Write	"                </p>" & vbNewLine & _

Insert:            Response.write GetMemberPhoto(Reply_PhotoURL)

561                             "                <p>" & vbNewLine
562             if strCountry = "1" and trim(Reply_MemberCountry) <> "" then

----------------------------------------

Step 6:

767             Response.Write	"                </p>" & vbNewLine & _
768                             "                <p>" & vbNewLine
769             if strCountry = "1" and trim(Member_Country) <> "" then

767             Response.Write	"                </p>" & vbNewLine & _

Insert:            Response.write GetMemberPhoto(Member_PhotoURL)

768                             "                <p>" & vbNewLine
769             if strCountry = "1" and trim(Member_Country) <> "" then

----------------------------------------

Step 7:

Last step, I added this function to the end of the file.

If the photo url does not have a .gif, .jpg, or .png extention 
nothing is displayed.  It's a simple function you can change it
easily.

   '***************************************************************************
   '*** 20090131 Modified by James Possible added GetMemberPhoto() function ***
   '*** Displays the member's profile picture with posts only if the        ***
   '*** Photo URL contains any one of the following image extensions        ***
   '*** .gif or .jpg or .png                                                ***
   '***************************************************************************
   Function GetMemberPhoto(ImageURL)

      Const VALID_PICTURE_EXTENSIONS = " .gif .jpg .png "

      Dim sReturn

      sReturn = ""

      If Len(ImageURL) > 4 Then
         If Instr(1, VALID_PICTURE_EXTENSIONS, Right(ImageURL, 4), 1) > 0 Then
            sReturn = "<p>" & vbNewLine & _
                      "<img src=" & """" & ImageURL & """" & vbNewLine & _
                      "     width=" & """" & "150" & """" & vbNewLine & _
                      "    height=" & """" & "150" & """" & vbNewLine & _
                      "    border=" & """" & "0" & """" & "/>" & vbNewLine & _
                      "</p>" & vbNewLine
         End If
      End If

      GetMemberPhoto = sReturn

   End Function


Again, it's clean, it's simple and anyone change modify with ease.

If the user has an image that's to big they can goto...

http://www.resizeyourimage.com/

...save file and upload to any number of sites, (i.e., flickr.com, photobucket.com etc.)

I decided to worry about uploading later, infact I'm considering the integration with http://www.gravatar.com/ in the future.

Appreciate Snitz and hope this helps someone.

James

<
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Previous 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.2 seconds. Powered By: Snitz Forums 2000 Version 3.4.07