Skip to main content
All CollectionsZapier IntegrationsAdvanced Configurations
Customizing Widget Embeds on Your Site
Customizing Widget Embeds on Your Site

How to Modify and Implement Our Calculator Widget

Updated over a week ago

Our calculator widget is a versatile tool designed to fit seamlessly into your website. Currently, we do not offer a desktop-specific version of this widget, but it can be customized to meet your specific needs with some HTML and CSS adjustments. This article will guide you through the process of modifying the widget width and implementing it effectively on your platform.

Important Note: Our widget is provided as-is, and we do not support custom development for external platforms. To customize the widget, you will need basic knowledge of HTML and CSS. You can modify the widget's width and other styles to better integrate it with your website's design.

Step-by-Step Guide to Modifying Your Widget

Here's a basic example of how to center and resize the widget to make it responsive on both mobile and desktop views:

HTML Structure

Start with a basic HTML structure. Add your calculator widget within an <iframe> tag to ensure it can be embedded properly.

<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Responsive and Centered Calculator Widget</title> </head> <body> <iframe src="https://yourwidgetsource.com/widgetpath" frameborder="0"></iframe> </body> </html>

CSS for Responsiveness

To make the widget responsive and centered, you can use the following CSS. This will adjust the widget to be centered on the page and scale according to different screen sizes, with a maximum size limit.

<style>

body {

display: flex;

justify-content: center;

align-items: center;

height: 100vh;

margin: 0;

}

iframe {

width: 100%;

height: 100%;

max-width: 800px; /* You can adjust this value based on your preference */

max-height: 800px; /* You can adjust this value based on your preference */

}

</style>


Code Example

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Responsive and Centered Calculator Widget</title>
<style>
body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}
iframe {
width: 100%;
height: 100%;
max-width: 800px;
max-height: 800px;
}
</style>
</head>
<body>
<iframe src="https://leslielender.cardtapp.com/mobile?is_demo=true&is_widget=true#purchase" frameborder="0"></iframe>
</body>
</html>

The above code displays as this on a Desktop Device

Did this answer your question?