Jump to content

w3 css - max width


mg19

Recommended Posts

Question, I am new to w3 css but I plan on using this versus bootstrap.  One thing I am trying to figure out is how to not use the screen 100% like bootstrap.  Is there a way to use only 80% or so of the screen or a certain pixel width and still make it work with all devices?

 

thanks for your help!

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...
On 2/11/2019 at 10:56 PM, mg19 said:

One thing I am trying to figure out is how to not use the screen 100% like bootstrap

Normally by default, bootstrap uses a fixed smaller width for larger devices, then 100% for smaller devices. You would only get 100% width on all devices if you used the class that gives 100% width whatever device size.

Link to comment
Share on other sites

  • 1 month later...

dsonesuk, thank you for this help! :)  have another question you might be able to answer.

I am using w3-modal to display account notes.  the idea is when you click more on any account note it brings up the entire note in a modal.  I was wanting a way to when you click the link it will have a unique id and search the SQL database for the id and load the data into the modal so I don't have to load a bunch of models with unique names in the code increasing the page load time.

Can you point me in a direction for this?  I was thinking javascipt/json but i don't know if this is right.  When I look in google all I get is bootstrap and jquery which I dont want to use.  My back end is php/sql and w3-css.

Thank you,

Link to comment
Share on other sites

Ss it possible to use only javascript without jquery?  I read about people saying to stay away from jquery, not sure why but don't want to make a mistake and have to re-code everything later.

As always, thank you.

Link to comment
Share on other sites

JQuery IS JavaScript, but is a library framework of functions to make code cross browser friendly and easier  to manipulate elements

If you use vanilla JavaScript you have to make sure it runs in all main browsers, as some browsers (MS IE for instance, (seven hail marys)) think you should do it their way for a specific coding, while better browsers follow common set method.

Link to comment
Share on other sites

Hey dsonesuk:

I am trying to get a input and button on the same line.  Here is what I am using but it keeps putting the search button below the input.  Thanks for all your help.

<p><input class="w3-input w3-border" name="searchString" type="text" id="start" placeholder="Search for Customer (address, name, phone and contacts)" value="<?php echo $searchString;?>" maxlength="40" required><button class="w3-btn w3-light-grey" type=submit name="location">Search</button></p>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...