Hi Esteban,
Thanks for the reply. I don't use WAFileLibrary. I don't remember why. I may have starter this before WAFileLibrary was around or it wasn't used much or I just didn't know much about it. I have included some code below that I will get to in a minute.
The HTML sent to the web browser includes things like this:
The V12 and V13 output is the same so the problem is not in the web page generation.
The code below gets the requests from the web browser. The #fileData variable in the last line:
aRequestContext respond: [:response | response contentType: mimeType; nextPutAll: fileData].
contains the file data. I have break pointed the code there an everything looks good. #fileData has the file data that it should have. After that I don't know what happens. Tomorrow, I will dig deeper and try to see why the data isn't returned to the browser.
Lou
handleFiltered: aRequestContext
| file fileInfo fileData mimeType pathArray fileStream fileStream2 tempData file2 |
fileCache isNil ifTrue: [fileCache := LookupTable new].
pathArray := aRequestContext request uri path asOrderedCollection.
fileStream := WriteStream on: ''.
fileStream2 := WriteStream on: ''.
pathArray do: [:p | fileStream nextPutAll: p] separatedBy: [fileStream nextPut: $/].
file := fileStream contents.
(pathArray notEmpty and: [pathArray first = 'root']) ifTrue: [pathArray removeFirst].
fileStream2 nextPut: $/.
pathArray do: [:p | fileStream2 nextPutAll: p] separatedBy: [fileStream2 nextPut: $/].
file2 := fileStream2 contents.
fileInfo := fileCache at: file asSymbol ifAbsent: [].
tempData := fileInfo notNil ifTrue: [
self readFileIfNeeded: fileInfo.
mimeType := fileInfo mimeType.
fileInfo data.
] ifFalse: [''].
fileData := tempData isEmpty ifTrue: [
mimeType := WAMimeType textPlain.
file2, ' not found!'.
] ifFalse: [tempData].
aRequestContext respond: [:response | response contentType: mimeType; nextPutAll: fileData].