Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(41)  |  Call(20)  |  Derive(0)  |  Import(21)

src/r/a/raptus.mercurialstorage-1.0b4/raptus/mercurialstorage/download.py   raptus.mercurialstorage(Download)
 
from Products.Five.browser import BrowserView
from Products.Archetypes.utils import contentDispositionHeader
 
# Import conditionally, so we don't introduce a hard dependency
                filename = unicode(filename, self.context.getCharset())
            header_value = contentDispositionHeader(
                disposition='attachment',
                filename=filename)
            self.request.RESPONSE.setHeader("Content-Disposition", header_value)

src/w/c/wc.pageturner-1.3.6/wc/pageturner/views.py   wc.pageturner(Download)
from zope.formlib import form
from webdav.common import rfc1123_date
from Products.Archetypes.utils import contentDispositionHeader
from os import fstat
from Products.CMFCore.utils import getToolByName
    def render_blob_version(self):
        # done much like it is done in plone.app.blob's index_html
        header_value = contentDispositionHeader(
            disposition='inline',
            filename=self.context.getFilename().replace('.pdf', '.swf'))

src/c/o/collective.xsendfile-HEAD/collective/xsendfile/utils.py   collective.xsendfile(Download)
from zope.component import getUtility
 
from Products.Archetypes.utils import contentDispositionHeader
from plone.i18n.normalizer.interfaces import IUserPreferredFileNameNormalizer
from plone.registry.interfaces import IRegistry
            unicode(filename, instance.getCharset()))
        header_value = contentDispositionHeader(
            disposition=disposition,
            filename=filename)
        RESPONSE.setHeader("Content-disposition", header_value)

src/u/w/uwosh.timeslot-1.5.5/uwosh/timeslot/browser/exporttocsv.py   uwosh.timeslot(Download)
from Products.Five import BrowserView
from Products.Archetypes.utils import contentDispositionHeader
 
import time
 
    def exportToCSV(self):
        currentDateTime = time.strftime('%Y%m%d%H%M', time.localtime())
        filename = '%s-%s.csv' % (self.context.Title(), currentDateTime)
        header_value = contentDispositionHeader('attachment',
                                                self.context.getCharset(),

src/e/n/enpraxis.educommons-4.1.2/enpraxis/educommons/browser/searchview.py   enpraxis.educommons(Download)
from enpraxis.educommons.events import CourseUpdate
from enpraxis.educommons.events import DeleteObjectEvent
from Products.Archetypes.utils import contentDispositionHeader
from zope.event import notify
 
        RESPONSE = self.context.REQUEST.RESPONSE
        filename = 'email_list.csv'
        header_value = contentDispositionHeader('attachment', 'UTF-8',filename=filename)
        RESPONSE.setHeader("Content-disposition", header_value)
        return email_list        

src/e/n/enpraxis.educommons-4.1.2/enpraxis/educommons/browser/position.py   enpraxis.educommons(Download)
from zope.publisher.browser import BrowserView
from enpraxis.educommons.utilities.interfaces import IECUtility
from Products.Archetypes.utils import contentDispositionHeader
 
class SearchView(BrowserView):
        RESPONSE = self.context.REQUEST.RESPONSE
        filename = 'email_list.csv'
        header_value = contentDispositionHeader('attachment', 'UTF-8',filename=filename)
        RESPONSE.setHeader("Content-disposition", header_value)
        return email_list        

src/p/r/Products.ATPhoto-1.0/Products/ATPhoto/ATPhotoTransform.py   Products.ATPhoto(Download)
from Products.ATContentTypes.lib.imagetransform import TRANSPOSE_MAP
from Products.ATContentTypes.configuration import zconf
from Products.Archetypes.utils import contentDispositionHeader
from Products.CMFCore.utils import getToolByName
from interfaces import IZippable
 
        if(REQUEST):
            header_value = contentDispositionHeader('attachment', self.getCharset(), filename=newfilename)
            REQUEST.RESPONSE.setHeader("Content-disposition", header_value)
            REQUEST.RESPONSE.write(str(file))

src/f/t/ftw.pdfgenerator-1.3.0/ftw/pdfgenerator/assembler.py   ftw.pdfgenerator(Download)
from Products.Archetypes.utils import contentDispositionHeader
from ftw.pdfgenerator.interfaces import IBuilderFactory
from ftw.pdfgenerator.interfaces import ILaTeXLayout
from ftw.pdfgenerator.interfaces import IPDFAssembler
from zope.component import adapts
            'Content-disposition',
            contentDispositionHeader(
                'attachment', 'utf-8', filename=filename))
 
        response.write(data)

src/p/r/Products.PloneFormGen-1.7.14/Products/PloneFormGen/content/customScriptAdapter.py   Products.PloneFormGen(Download)
# Plone imports
from Products.Archetypes.public import *
from Products.Archetypes.utils import contentDispositionHeader
from Products.ATContentTypes.content.schemata import finalizeATCTSchema
from Products.ATContentTypes.content.base import registerATCT

src/p/r/Products.PloneFormGen-HEAD/Products/PloneFormGen/content/customScriptAdapter.py   Products.PloneFormGen(Download)
# Plone imports
from Products.Archetypes.public import *
from Products.Archetypes.utils import contentDispositionHeader
from Products.ATContentTypes.content.schemata import finalizeATCTSchema
from Products.ATContentTypes.content.base import registerATCT

Previous  1 | 2 | 3  Next