NetTalk Central

Author Topic: Error in PageFooterTag p_web.Script  (Read 3705 times)

mtabakin

  • Jr. Member
  • **
  • Posts: 53
    • View Profile
    • Email
Error in PageFooterTag p_web.Script
« on: September 23, 2013, 11:23:48 AM »
While Bruce is at CIDC - anyone know why and how to get rid of the error after I updated from NT 7.19 to 7.25 "Cannot call procedure as Function" on the p_web.Script(......) line in the following Capesoft embed code in PageFooterTag:

  if (p_web.GetSessionLoggedIn() and p_web.PageName <> p_web.site.LoginPage)
    ! parameter 1 is the session time
    ! parameter 2 is the name of the login page.
    ! parameter 3 is the id of the <div> in the html.
    packet = clip(packet) & p_web.Script('startCountDown('& int(p_web.site.SessionExpiryAfterHS/100) &',"'& clip(p_web.site.LoginPage) &'","countdown");')
    do SendPacket
  end


urayoan

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • AZ Rock Radio
Re: Error in PageFooterTag p_web.Script
« Reply #1 on: September 23, 2013, 04:38:15 PM »
Change this line
packet = clip(packet) & p_web.Script('startCountDown('& int(p_web.site.SessionExpiryAfterHS/100) &',"'& clip(p_web.site.LoginPage) &'","countdown");')

For this
 p_web.Script('startCountDown('& int(p_web.site.SessionExpiryAfterHS/100) &',"'& CLIP(p_web.site.LoginPage) &'","countdown");')

Or delete the bold text.

Cheers
Ura

mtabakin

  • Jr. Member
  • **
  • Posts: 53
    • View Profile
    • Email
Re: Error in PageFooterTag p_web.Script
« Reply #2 on: September 23, 2013, 07:21:33 PM »
Thanks Ura that's what I figured needed to be done given the error. Nice to get confirmation.

urayoan

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • AZ Rock Radio
Re: Error in PageFooterTag p_web.Script
« Reply #3 on: September 24, 2013, 04:41:42 AM »
Your welcome mtabakin. That change is documented by Bruce here if you need aditional information:

http://capesoft.com/docs/NetTalk7/NetTalk7Upgrade.htm#Embeds

Another one that i have problems is using <CR,LF> in some hand code. If you get problems use this p_web.CRLF