My Assistant
![]() ![]() |
|
|
Aug 25 2011, 09:44 AM
Post
#1
|
|
|
UtterAccess Guru Posts: 566 |
Hello. I currently have a web page where:
1. A user selects from a drop down. 2. The drop-down returns a file name. 3. We use: <% Response.WriteFile(DropDownList2.SelectedItem.Value)%> To view the file on the screen / same page. (all html files) This works great. My question: I'm trying to not have to go in and touch every one of these pages too much. Often the formatting, CSS, etc - messes up the main page. Is there a way to keep that file confined so the formatting stays as is for both pages? (Example: May change the color of font on the main page when a certain file is displayed) My current fix - go in to the sub page being written and remove any special formatting or CSS. Thanks again! |
|
|
|
Aug 26 2011, 08:54 PM
Post
#2
|
|
|
Access Wiki and Forums Moderator Posts: 48,592 From: SoCal, USA |
Hi Julie,
Just thinking out loud here... I wonder if you could enclose the included page inside a DIV tag, would it make any CSS inside it a subclass of that DIV especially if you assign a specific style to that DIV's ID? If not, I wonder what would happen if you enclose the included page inside an IFRAME? If nothing else, you could try using JavaScript to auto strip the CSS from the included page so you won't have to do it manually. Just my 2 cents... |
|
|
|
Aug 27 2011, 05:29 AM
Post
#3
|
|
|
UtterAccess Guru Posts: 566 |
Div Tags i've tried...
IFRAME - Good idea!!! I forgot about that and have done that before with success. auto strip the CSS -- Well, I somewhat tried that. However, these pages are a MESS. And too many. Old history, so ok to keep as is if possible. Thank you!!! :-) |
|
|
|
Aug 27 2011, 09:36 AM
Post
#4
|
|
|
Access Wiki and Forums Moderator Posts: 48,592 From: SoCal, USA |
|
|
|
|
Aug 29 2011, 06:44 AM
Post
#5
|
|
|
UtterAccess Guru Posts: 566 |
OK, what is the correct syntax to include the writefile in the src?
This is my source: fldWhatyr.SelectedItem.Value <% Response.WriteFile(fldWhatyr.SelectedItem.Value)%> How would you do that with the src / iframe?? ---------------------> <IFRAME SRC=fldWhatyr.SelectedItem.Value WIDTH=950 HEIGHT=300> If you can see this, your browser doesn't understand IFRAME. </IFRAME> |
|
|
|
Aug 29 2011, 06:55 AM
Post
#6
|
|
|
UtterAccess Guru Posts: 566 |
Nevermind - I got it. So far, so good! Going to make some minor code changes, below works so far ---
<IFRAME SRC=<%Response.Write(fldWhatyr.SelectedItem.Value)%> frameborder="0" WIDTH=950 HEIGHT=600> If you can see this, your browser doesn't understand IFRAME. </IFRAME> Thank you again :-) |
|
|
|
Aug 29 2011, 10:40 AM
Post
#7
|
|
|
Access Wiki and Forums Moderator Posts: 48,592 From: SoCal, USA |
Hi Julie,
Glad to hear you got it sorted out. Good luck with your project. |
|
|
|
Aug 29 2011, 10:45 AM
Post
#8
|
|
|
UtterAccess Guru Posts: 566 |
Thank you
|
|
|
|
![]() ![]() |
|
Go to Top · Lo-Fi Version | Time is now: 18th June 2013 - 04:19 PM |