Search DominoPower's 10,675 Lotus-related article archive 
Home
EasyPrint
News details Click here for the RSS feed's XML code. This is not a browser URL.
Articles-only Click here for the RSS feed's XML code. This is not a browser URL.
Twitter Feed Click here for the Twitter feed.
JAVASCRIPT FOR FUN AND PROFIT
Using JavaScript to get the Query_String from a frameset
By Dan Velasco

At my company, we recently received an application a consulting company had created for us that had a fatal flaw. Well, maybe not a fatal flaw, but definitely one that would make developers want to slit their wrists because of all the maintenance and customization involved.

It was an e-commerce application designed to assist our customers in buying our products. The main page was a frameset with three frames: a top frame, a left-hand side frame, and a main body frame. The main body frame, by default, contained login information, and that was all, as you can see in Figure A. The challenge we faced was that we wanted to create custom home/login pages for each of the products showing a picture of the product along with a customized welcome message.

FIGURE A


The default screen only contains login information, challenging us to customize it for each of our products. Roll over picture for a larger image.

The fatal flaw in the application the consulting company had created for us was that in order to create custom home pages for each of our products, it required the following steps:

  1. Create a new frameset and then name it after the product;
  2. Create a custom home page Domino form for the product;
  3. Create a configuration document for each product that includes such information as the name of the product, its home page URL, and an attached file that contains a picture of the product, among other things.

In case you're keeping count, that's two Domino design elements that would have to be created for each product. Multiply this by an initial set of almost 30 products and you get the picture of how unwieldy this could quickly become. As you are no doubt thinking, the method above does not require a lot of skills but it does require that the person who is creating these custom home page framesets and forms have a Notes Designer client. Gee, whom would they come to with change requests?

This solution was simply unacceptable to me, and I knew there had to be a better way. Well, there is, and all it involves is a basic understanding of JavaScript, Query_Strings, and the code I am about to give you. The solution outlined in this article is designed to work in Notes/Domino R5 only. For a sample database containing the complete code described in this article, please go to http://dan.velasco.com.

How do you get the Query_String of a frameset?
OK, here's a quick refresher. The Query_String is the part of the URL that usually starts with either the question mark or exclamation mark, as the case might be. For instance, in the URL http://sample/db.nsf/MainFrameset?OpenFrameset&;fname=Dan&lname=Velasco, the Query_String would be "?OpenFrameset&fname=Dan&lname=Velasco". There are two parameters, one called fname with a value of "Dan" and one called lname with a value called "Velasco." When you are not using framesets, it is fairly easy to get and manipulate the Query_String using a computed for display field on the form set to Query_String or by getting doc.Query_String(0) via LotusScript. When the form is in a frameset, however, you've got to take a different approach.


1  ·  2  ·  3  ·  4  ·  5  ·  Next »
Other articles you might like
Home > Internet Technologies > JavaScript (13 articles)
   Sorting your Domino views with JavaScript
   Give your Domino views life with DHTML
   Using dynamically generated HTML to thwart spam email address harvesting
Get Weekly Email Updates
Subscribe to our regular weekly email newsletter. It's packed with tips, reviews, deep analysis, and the latest news.
 
Recent DominoPower Articles
What to look for in a Domino-based document management solution
Understanding Domino.doc end-of-life options
When the debugger won't debug hidden code that isn't hidden
What to do if the LotusScript debugger won't single-step over code
Top 10 ways to launch and build a Lotus consulting practice (with a little help from the Beatles)
Troubleshooting an OpenSuse Notes install
Incident report: denial of service attack against ConnectedPhotographer.com
Latest Lotus Headlines
SnTT - Enabling ALL the bells and whistles!
Tivoli Data protection causes Domino to crash
Fun when running DB2 CLP scripts
Introducing Flippr, the easy way to admin Quickr
DXL and fake security
Using search forms in IBM Workplace Collaborative Learning 2.7
Schmidt, Freed, and Gering on the OVF Toolkit
>> Read all the news
More from the ZATZ journals
Computing Unplugged: Eight steps to successful and reliable home backups
David Gewirtz Online: CNN commentary and analysis
OutlookPower: Can Outlook run when it's not running (and other mysteries)?
-- Advertisement --

PistolStar: Lotus Notes Authentication That Breaks the Status Quo
Password Power's complete integration with the Microsoft Active Directory password enables Notes client access, ends time-consuming Notes ID password recovery and addresses known issues with Notes 8.5:
  • Passwords are encrypted in volatile memory - not stored on user's hard drive
  • Notes roaming capabilities are fully functional - not limited
  • Password checking is honored - no decreased security or failed compliance
  • All Notes ID file copies are synched automatically with Active Directory password - no remembering old passwords or restoring ID files


Learn more about Password Power's powerful, advanced functionality.
-- Advertisement --

Easy Domino Access: Remove Passwords, End Login Prompts, Reduce Password Management
PistolStar's Password Power provides browser-based single sign-on to Lotus Domino, Sametime and Quickr with the enhanced security of the Kerberos or NTLM authentication protocol.

  • Full support available for NTLM authentication protocol in non-Active Directory environments
  • Seamlessly integrate Microsoft Active Directory and the Kerberos authentication protocol
  • Leverage Active Directory password policies to unify Lotus applications


Learn more about Password Power's powerful, advanced functionality.
ZATZ Home  ·  News  ·  Back Issues  ·  Credits/Trademarks ·  Link To Us
Copyright © 1998-2009, ZATZ Publishing. All rights reserved worldwide.
Editor's Login