regardless of whatever was wrong with the PageSource+code. i was able to fix it this way:
I added the following code to App.HTMLHeader:
<Style>.BackgroundImage { background-image: url("url/to/img.jpg"); background-attachment: fixed; background-position: center center; background-repeat: repeat; min-height: 100%; body{min-height: 100%;}</Style>
Then i added a webstyle named: BackgroundImage
Set each Webpage style to BackgroundImage, built, ran fine.
I am truly not sure what was going on. PageSource+code above was working just fine initially and then suddenly stopped. The only other thing i changed was i had a method that was scaling images retrieved from a database. with the following code found on this forum:
#if DebugBuild=False then
#pragma BackgroundTasks false
#pragma BoundsChecking false
#pragma NilObjectChecking false
#pragma StackOverflowChecking false
#endif
dim pIn,pOut as Picture
Dim s As RGBSurface
Dim o As RGBSurface
Dim x,y,xMax, yMax As Integer
dim xx() as Double
Dim c1, c2, c3, c4, c5 As Color
dim xMult,yMult, a,b, xSub,ySub, xAdd,yAdd as Double
if p=nil then
Return p
end
s=p.RGBSurface
if s=nil then
Return nil
end
pOut=NewPicture( newWidth, newHeight, 32 )
if pOut=nil then
Return nil
end
o=pOut.RGBSurface
if o=nil Then
Return nil
end
xMax = pOut.Width - 1
yMax = pOut.Height - 1
yMult=p.Height/newHeight
xMult=p.Width/newWidth
a=newWidth/p.Width
if a>.5 then
xSub=.45
xAdd=.5
Elseif a<.5 then
xSub=.75
xAdd=2
else
xSub=0
xAdd=1
end
a=newHeight/p.Height
if a>.5 then
ySub=.45
yAdd=.5
Elseif a<.5 then
ySub=.75
yAdd=2
else
ySub=0
yAdd=1
end
redim xx(xMax)
for x=0 to xMax
xx(x)=(x * xMult)- xSub
next
For y = 0 To yMax
b = (y * yMult)- ySub
For x = 0 To xMax
a = xx(x)
c1 = s.Pixel(a , b )
c2 = s.Pixel(a + xAdd , b )
c3 = s.Pixel(a , b + yAdd)
c4 = s.Pixel(a + xAdd , b + yAdd)
o.Pixel(x, y) = RGB( _
(c1.Red + c2.Red + c3.Red + c4.Red) \\ 4, _
(c1.Green + c2.Green + c3.Green + c4.Green) \\ 4, _
(c1.Blue + c2.Blue + c3.Blue + c4.Blue) \\ 4 _
)
Next
Next
Return pOut
The section “pOut=NewPicture( newWidth, newHeight, 32 )” triggered an error in the new 2017 Xojo IDE saying NewPicture did not exist. This code was found here on the forum and an attempt to smooth out the scaling of pictures since graphics does a horrible job, i have since reverted back to graphics. My old 2015 Xojo did not register this as an error. I can understand the error the new IDE gave me but what i can’t understand is why this was working perfectly before hand with a compiled cgi.
ANYWAY, i’m back to where i was about 48 hours ago. Hopefully nothing breaks again :-/.