snipt

Ctrl+h for KB shortcuts

CSS

ONTRAPORT - Make your forms responsive with this snippet of code.

1
2
3
4
5
6
7
<style>
.moonray-form
{
    width: 100%!important;
    max-width: 400px; /* Or whatever maximum width you would prefer to change it to */
}
</style>
https://snipt.net/embed/f0caca1d2c3cfe9883c88fba6abf1c2a/
/raw/f0caca1d2c3cfe9883c88fba6abf1c2a/
f0caca1d2c3cfe9883c88fba6abf1c2a
css
CSS
7
2016-12-29T03:13:28
True
False
True
Apr 09, 2014 at 07:41 PM
/api/public/snipt/128765/
ontraport-make-your-forms-responsive-with-this-snippet-of-code
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a> <a href="#L-2">2</a> <a href="#L-3">3</a> <a href="#L-4">4</a> <a href="#L-5">5</a> <a href="#L-6">6</a> <a href="#L-7">7</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a><span class="o">&lt;</span><span class="nt">style</span><span class="o">&gt;</span> </span><span id="L-2"><a name="L-2"></a><span class="nc">.moonray-form</span> </span><span id="L-3"><a name="L-3"></a><span class="p">{</span> </span><span id="L-4"><a name="L-4"></a> <span class="nb">width</span><span class="o">:</span> <span class="m">100%</span><span class="cp">!important</span><span class="p">;</span> </span><span id="L-5"><a name="L-5"></a> <span class="nb">max-width</span><span class="o">:</span> <span class="m">400px</span><span class="p">;</span> <span class="c">/* Or whatever maximum width you would prefer to change it to */</span> </span><span id="L-6"><a name="L-6"></a><span class="p">}</span> </span><span id="L-7"><a name="L-7"></a><span class="o">&lt;/</span><span class="nt">style</span><span class="o">&gt;</span> </span></pre></div> </td></tr></table>
ONTRAPORT, css