oliverk Posted June 7 Report Share Posted June 7 A quick question. How do I apply styling in the datapage that appears in a modal, but not the datapage(s) in the main page that the modal appears on? For example, I want this to appear in the header of my modal datapage, and not affect the other datapages: <style> .cbResultSetTable { display: none !important; } <style> Thanks Quote Link to comment Share on other sites More sharing options...
0 kpcollier Posted June 7 Report Share Posted June 7 You can try wrapping the modal datapage in a div with a unique id, and then use a selector to only style the cbResultSetTable element within that div. Something like this: In the header: <div id="someID"> In the footer: </div> CSS Rule: #someID .cbResultSetTable { /* Your CSS rules here */ } Quote Link to comment Share on other sites More sharing options...
0 CoopperBackpack Posted June 10 Report Share Posted June 10 Hello @oliverk, Forms, Reports, Calendars, Charts DataPages has the following tag: <form method="post" id="caspioform" action="https://accountID.caspio.com/dp/AppKey?cbUI=1" style="margin: 0px;"> Each DataPage has its unique AppKey. Actually AppKey is the unique DataPage identifier. So, the reliable way to reference styles of this particular DataPage is to refer to its AppKey. For that use the [@cbAppKey] parameter that will be replaced with the DataPage AppKey when the DataPage is loaded. For example: <style> form[action*="[@cbAppKey]"] .cbResultSetTable{ display: none !important; } </style> oliverk 1 Quote Link to comment Share on other sites More sharing options...
0 oliverk Posted June 14 Author Report Share Posted June 14 On 6/10/2024 at 7:36 AM, CoopperBackpack said: Hello @oliverk, Forms, Reports, Calendars, Charts DataPages has the following tag: <form method="post" id="caspioform" action="https://accountID.caspio.com/dp/AppKey?cbUI=1" style="margin: 0px;"> Each DataPage has its unique AppKey. Actually AppKey is the unique DataPage identifier. So, the reliable way to reference styles of this particular DataPage is to refer to its AppKey. For that use the [@cbAppKey] parameter that will be replaced with the DataPage AppKey when the DataPage is loaded. For example: <style> form[action*="[@cbAppKey]"] .cbResultSetTable{ display: none !important; } </style> Thanks, this worked! CoopperBackpack 1 Quote Link to comment Share on other sites More sharing options...
Question
oliverk
A quick question.
How do I apply styling in the datapage that appears in a modal, but not the datapage(s) in the main page that the modal appears on?
For example, I want this to appear in the header of my modal datapage, and not affect the other datapages:
<style>
.cbResultSetTable {
display: none !important;
}
<style>
Thanks
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.