Solved

How to create a simple preview page before form submit.

Posted on 2010-11-21
9
877 Views
Last Modified: 2012-05-10
I am trying to find a simple way to create a preview page before submitting.
Not sure if it would make a difference that I am using a form in asp with some fields automatically filled from a table based on their login.
Is there a simple way to do this?

Thanks in advance.
0
Comment
Question by:colonelblue
9 Comments
 
LVL 4

Accepted Solution

by:
Slim81 earned 250 total points
ID: 34184689
Couldn't you just pass the data to a page that displays the data, then submit the form data via hidden fields (via button click on the "display page")?

Are you using Dreamweaver?

-Slim
0
 
LVL 44

Assisted Solution

by:scrathcyboy
scrathcyboy earned 250 total points
ID: 34184743
** simple  and  preview ** are largely contradictory.  Any preview takes a new page refresh or a lot of code writing, and is not "Simple".

You can compose a preview page in a popup window entirely with javascript's document write which would be the javascript purists' way to do this, or you can send the data to PHP and have it send back a new page with the preview, which would be considered the "normal" way to do this.  Both take work.
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 34185091
I agree with @scrathcyboy on this.  The preview pages I've had to do took a lot more code than the original forms.
0
 

Author Comment

by:colonelblue
ID: 34185443
@Slim81 : Thank you that was what I was assuming. I just thought there might be a simpler way, so I asked. Yes I am using Dreamweaver.

@scrathcyboy: As I had said above (  I just thought there might be a simpler way which prompted me to ask)  and what DaveBaldwin had ascertained that it took more code to do than the original form.

Incidentally as I initially posted , I am using ASP NOT PHP.
Also, if I knew how to "compose a preview page in a popup window entirely with javascript's document write" this question would be redundant, no? But thank you just the same.
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 44

Expert Comment

by:scrathcyboy
ID: 34190380
I was merely pointing out that every way you go, ASP, PHP, javascript, it is doing a whole new page all over again.  However, there is a way you can get around ALL of this problem, if you are interested.

You develop 2 CSS style sheets -- one for viewing and one for printing.  Then at the top of the page you have a link View as webpage / view as print page -- and you simple TOGGLE the two style sheets to use either the one for printing or the one for previewing.

Once you do this at the outset, it is less than 2 pages of work, it is about 1.5 pages effort.  Note that the view as printed also includes making headers, graphics, icons and pictures disappear, so it takes a fair bit of CSS effort to get it right -- but it does work, and many sites are now doing it.

It will be the trend of the future, just as multilingual sites are now doing.
0
 
LVL 44

Expert Comment

by:scrathcyboy
ID: 34190438
Didn't finish, sorry -- multilingual sites are doing this toggle button for the web pages for different languages.

And as far as a FORM, it is basically the same as a print preview, because you are redesigning it (by CSS or by page refresh) to look how you want it to look.  Most dual CSS pages are with the thought of final print layout.  It would take some careful thought as to how to style the form for preview, but it is doable.
0
 

Author Comment

by:colonelblue
ID: 34815150
Thank you.
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 34830219
This question has been classified as abandoned and is being closed as part of the Cleanup Program. See my comment at the end of the question for more details.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Adobe Dreamweaver CS5 is a WYSIWYG web page editor that has advanced HTML, CSS, and Javascript rendering functionality and is probably the most well-known HTML editor available. Much of Dreamweaver's appeal centers around the Design View interfac…
This article is very specific and is only intended to help if you are installing Dreamweaver 8 in a Windows 7 environment with Office 2007 installed.   I'm not sure why Microsoft tends to release OS' that should not be released but they do.  Windows…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now