Author |
Topic  |
|
Andy Humm
Average Member
  
United Kingdom
908 Posts |
Posted - 21 March 2007 : 10:20:22
|
Having succesfully installed the Link Mod v3 beta 2 on forum version 06 It all appears to run okay, except when clicking [Rate this Link] the following error appears:
Microsoft VBScript runtime error '800a000d' Type mismatch: 'strPostDate' /forum/pop_links.asp, line 188
line 188 is coloured in red below strPostDate = ChkDate(rsLink("POST_DATE")," ", true) strLastUpdate = ChkDate(rsLink("LAST_UPDATE")," ",true) If strLastUpdate > strPostDate Then dateSince = DateDiff("d", Date(), strLastUpdate)+7 Else dateSince=DateDiff("d", Date(), strPostDate)+7 End If Response.Write All the database updates were successfull, knowing I have just installed the mod today and checking out a link inserted today, does the datediff need a date delay or is there another problem. Any clues would be appreciated andy
|
Edited by - Andy Humm on 21 March 2007 15:06:09 |
|
OneWayMule
Dev. Team Member & Support Moderator
    
Austria
4969 Posts |
|
Andy Humm
Average Member
  
United Kingdom
908 Posts |
Posted - 21 March 2007 : 11:39:32
|
I do have the Today/Yesterday MOD installed with looks at the date and if the last post was today or yesterday it displays Today/Yesterday instead of the full date. We had an issue on other files ie Topic.asp to get this to work and the following was the solution:
dim strCloseFont if instr("admin_accounts_pending.asp,admin_config_datetime.asp,pop_printer_friendly.asp",mid(strScriptName,instrrev(strScriptName,"/")+1))=0 then select case left(fDate,8) case left(DateToStr(strForumTimeAdjust),8) chkDate="<font color=""colour"">Today" strCloseFont="</font>" case left(DateToStr(dateadd("d",-1,strForumTimeAdjust)),8) chkDate="<font color=""colour"">Yesterday" strCloseFont="</font>" end select end if if fTime then chkDate=chkDate&separator&chkTime(fDate) chkDate=chkDate&strCloseFont
This was discussed on thread Is there away of adjusting the code on strPostDate to accommodate the today/yesterday change Or simply could you suggest where I could remove the rating link in the links page.. rgds andy
|
 |
|
Shaggy
Support Moderator
    
Ireland
6780 Posts |
Posted - 22 March 2007 : 04:17:06
|
In the updated code I provided you with, that would then look like this:dim strCloseFont
if instr("admin_accounts_pending.asp,admin_config_datetime.asp,pop_links.asp,pop_printer_friendly.asp",mid(strScriptName,instrrev(strScriptName,"/")+1))=0 then
select case left(fDate,8)
case left(DateToStr(strForumTimeAdjust),8)
chkDate="<font color=""colour"">Today"
strCloseFont="</font>"
case left(DateToStr(dateadd("d",-1,strForumTimeAdjust)),8)
chkDate="<font color=""colour"">Yesterday"
strCloseFont="</font>"
end select
end if
if fTime then chkDate=chkDate&separator&chkTime(fDate)
chkDate=chkDate&strCloseFont |
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
 |
|
Andy Humm
Average Member
  
United Kingdom
908 Posts |
Posted - 25 March 2007 : 06:04:06
|
Shaggy thanks for your provided amendment rgds andy |
 |
|
Shaggy
Support Moderator
    
Ireland
6780 Posts |
Posted - 26 March 2007 : 04:19:15
|
You're welcome.
|
Search is your friend “I was having a mildly paranoid day, mostly due to the fact that the mad priest lady from over the river had taken to nailing weasels to my front door again.” |
 |
|
|
Topic  |
|
|
|