: 4401 | 106125 | 11885

One Content-Type fits all? 
Use this IdeaSpace to post ideas about Domino Designer.

: 14
: 14
: 0
: Domino Designer
: Web, Content-Type, Mobile
: Jason Hook2830 28 Jan 2009
:
: / Email
Imagine going to buy your morning coffee and being told by the vendor "I only make expresso and tea".  But "I want a Latte" you say. She says "I could make a Latte but then I'd have to make a Latte for everyone".  She doesn't sound very flexible and neither is the way Domino traditionally handles the HTTP Header Content-Type.
 
When a client makes an HTTP request the Content-Type HTTP Header is sent from server to client with the response telling the client what kind of resource is being sent.

The content-type header is related to the ACCEPT header which is sent to the server with a request and tells the server what kind of content the client can accept.

Currently Domino Pages and Forms allow the designer to specify the following Content-Type options: Notes, HTML or Other (which a text field).  Alternatively Domino has a @SetHTTPHeader function but when used to set Content-Type the value seems to be overwritten by the form property.

Being able to compute the Content-Type based on the ACCEPT header would be useful where a client may be a full-fat or microbrowser.

Potential values of Content-Type for an HTML page might include:

application/vnd.wap.xhtml+xml
application/xhtml+xml
text/html

It's possible to dynamically generate the header in other webservers that for example use PHP or JSP

I would like to be able to set the Content-Type programatically either by making the content-type form property computable or giving the @SetHTTPHeader precedence over the form property.

It may be possible to reproduce this functionality with xPages but it would be useful to have this in the 8.0.x code stream.
 
What do you think, am I missing a trick somewhere?
 



1) Jeff Gilfelt1049 (28 Jan 2009)
This would be extremely useful. I think @SetHTTPHeader is totally broken by the execution precedence of the context in which you can call it. I raised a similar idea about giving developers complete control over HTTP headers for any design element:

{ Link }
2) Ben Poole1695 (28 Jan 2009)
I looked into this far too much when I was playing about with content-type in DominoWiki 1.1 a couple of years back (Jason, as discussed, you can see from the template what I do now).

@SetHttpHeader doesn't work for certain attributes—content-type being one of them—intentionally. Apparently it's some kind of security thang. Although given that we can set this value in form properties, I'm not sure that's really a valid reason.
3) Matt White9250 (28 Jan 2009)
I suspect any changes to "classic" web development are onto a loser unfortunately now that we have XPages, but I totally agree this is a good idea.
4) Rob Wills1020 (28 Jan 2009)
This xPages blog entry from Stephan covers one way that you can write completely dynamic content with whatever content type you want. Not entirely on topic and I agree it would be useful to have in the 8.0.x codestream:

{ Link }










:
:

Welcome to IdeaJam™


You can run IdeaJam™ in your company. It's easy to install, setup and customize. Your employees, partners and customers will immediately see results.

Use IdeaJam to:

  • Collect ideas from employees
  • Solicit feedback and suggestions from employees and customers
  • Run innovation contests and competitions
  • Validate concepts
  • Use the power of "crowd-sourcing" to rank ideas and allow the best ideas to rise to the top

IdeaJam™ works with:

  • IBM Connections
  • IBM Lotus Quickr
  • Blogs and Wikis
  • Websphere Portal
  • Microsoft Sharepoint
  • and other applications.

IdeaJam has an extensive set of widgets and API's that allow you to extend and integrate IdeaJam™ with other applications.

Learn more about IdeaJam >>


4
Add server and database as optional parameters for @GetProfileField and @SetProfileField
9
Have an option to copy an URL from an e-mail (or other)
-1
System wide Web Query Save
56
Please update Domino to fully support TLS (SSL v3.1)
4
Integrated ICS OneUI Editor for Designer
0
Design Element PostSave event
55
When deleting user, delete archive & roaming files as well as mail file
0
Please make the 'Database Users' view collapsible
6
Agent context menu in editor tab eg. "Run Agent"
2
Give us @commands for splitting & joining table cells, and hence smarticons for the same







IdeaJam developed by