Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
lims_connect
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pub
lims_connect
Commits
db44d771
Commit
db44d771
authored
Sep 06, 2017
by
Johannes Metscher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved file download
parent
9b0200a8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
16 deletions
+28
-16
vba_sample_client/default.asp
vba_sample_client/default.asp
+28
-16
No files found.
vba_sample_client/default.asp
View file @
db44d771
...
...
@@ -229,22 +229,35 @@ If query <> "" Then
'Outlier if download is asked for
If InStr(host, "download") Then
Response.Buffer = False
'When query is available prepare for request sending
Dim file_url_only
file_url_only = False
'Split query
d = Split(query, vbCrLf)
'Set filetype to pdf
'Response.ContentType = "application/pdf"
'Response.Charset = "UTF-8"
'Response.AddHeader "Content-Transfer-Encoding", "binary"
Response.AddHeader "Pragma", "no-cache"
Response.AddHeader "Expires", "0"
'Iterate through variable d - data
'Read from data text input field and save it in newLicenseData to send it in request
For Each e In d
ps = Split(e, "=>")
If UBound(ps) = 1 Then
If Trim(ps(0))
<>
"" and Trim(ps(0)) = "file_url_only" Then
If Trim(ps(1)) = 1 Then
file_url_only = True
Else
file_url_only = False
End If
End If
End If
Next
'Set filename of downloaded attachment
Response.AddHeader "Content-Disposition", "attachment; filename=Lizenz.pdf"
dim convertedBody
convertedBody = AlterCharset(body, "UTF-8" ,"ISO-8859-1")
Response.BinaryWrite convertedBody
Response.End
If file_url_only
<>
True Then
body = "This request cannot be handled by this Script. Please use the file_url_only parameter for licesnse download."
End If
End If
'If is no response yet, show some standard text
...
...
@@ -291,5 +304,4 @@ label { display: block; }
<pre>
CodePage:
<
%
response.write
Response.CodePage
%
></pre>
</body>
</html>
</html>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment