MATC alignment

Open to all! Ask other shopowners for help.
Post Reply
User avatar
tessthepup
Certified Developer
Posts: 383
Joined: Mon Mar 01, 2021 5:55 pm
Phoenix Version:
Has thanked: 47 times
Been thanked: 62 times

MATC alignment

Post by tessthepup »

Hi guys,

This particular problem has been bugging me for quite a while and I am stumped now how to resove it.

The issue is the alignment of the MATC (see image). This is the closest I can get it to center align on the page.

No matter how many columns I set the width to and it is driving me nuts lol

A little help will save my sanity and my ocd :o

Code: Select all

<div class="col-5 mx-auto">
   <div class="form-group row align-items-center d-flex justify-content-center">
    <div class="col-form-label text-left text-sm-right"><?= ENTRY_MATC ?></div>
    <div class="pl-5 custom-control custom-switch">
      <?= $input->set('id', 'inputMATC') ?>
      <label for="inputMATC" class="custom-control-label text-muted"><small><?= ENTRY_MATC_TEXT ?></small></label>
    </div>
  </div>
</div>
You do not have the required permissions to view the files attached to this post.


Join The Code Co-op to get access to your library in the Code Co-op Forum
heatherbell
Senior Contributor
Posts: 2540
Joined: Mon Oct 07, 2019 4:39 am
Phoenix Version:
Has thanked: 35 times
Been thanked: 243 times

Re: MATC alignment

Post by heatherbell »

A quick look at your site with Dev Tools shows the MATC is centred in the div class row (that wraps the div class col-sm-10 mt-4).
That needs justify-content-center adding to class.
Then there are all the unused labels for each row that are col-sm-3 that throw the alignment to the right.
Remove them and everything should then centre.
You might want to then adjust the width of the div class col-sm-10 mt-4 and all the div class col-sm-9 (that wrap the inputs) as required.
User avatar
tessthepup
Certified Developer
Posts: 383
Joined: Mon Mar 01, 2021 5:55 pm
Phoenix Version:
Has thanked: 47 times
Been thanked: 62 times

Re: MATC alignment

Post by tessthepup »

heatherbell wrote: Mon Feb 26, 2024 8:26 am A quick look at your site with Dev Tools shows the MATC is centred in the div class row (that wraps the div class col-sm-10 mt-4).
That needs justify-content-center adding to class.
Then there are all the unused labels for each row that are col-sm-3 that throw the alignment to the right.
Remove them and everything should then centre.
You might want to then adjust the width of the div class col-sm-10 mt-4 and all the div class col-sm-9 (that wrap the inputs) as required.
@heatherbell

Thank you very much for the help. After quite a bit of fiddling I managed to get it centered.
LeeFoster
Contributor
Posts: 263
Joined: Sun Feb 28, 2021 9:41 pm
Phoenix Version: v1.0.8.20
Has thanked: 1 time
Been thanked: 5 times

Re: MATC alignment

Post by LeeFoster »

@tessthepup any chance you can help me? I'm currently setting up a 1.0.9.4 store and can't find any MATC for the registration page. Is it a hook like it used to be or a module now?
heatherbell
Senior Contributor
Posts: 2540
Joined: Mon Oct 07, 2019 4:39 am
Phoenix Version:
Has thanked: 35 times
Been thanked: 243 times

Re: MATC alignment

Post by heatherbell »

LeeFoster wrote: Mon Jul 15, 2024 8:39 pmMATC for the registration page.
Admin>Modules>Customer Data
User avatar
tessthepup
Certified Developer
Posts: 383
Joined: Mon Mar 01, 2021 5:55 pm
Phoenix Version:
Has thanked: 47 times
Been thanked: 62 times

Re: MATC alignment

Post by tessthepup »

LeeFoster wrote: Mon Jul 15, 2024 8:39 pm @tessthepup any chance you can help me? I'm currently setting up a 1.0.9.4 store and can't find any MATC for the registration page. Is it a hook like it used to be or a module now?
Hi Lee, did you get sorted using @heatherbell suggestion?
LeeFoster
Contributor
Posts: 263
Joined: Sun Feb 28, 2021 9:41 pm
Phoenix Version: v1.0.8.20
Has thanked: 1 time
Been thanked: 5 times

Re: MATC alignment

Post by LeeFoster »

tessthepup wrote: Tue Jul 16, 2024 8:21 am
LeeFoster wrote: Mon Jul 15, 2024 8:39 pm @tessthepup any chance you can help me? I'm currently setting up a 1.0.9.4 store and can't find any MATC for the registration page. Is it a hook like it used to be or a module now?
Hi Lee, did you get sorted using @heatherbell suggestion?
Yes I did, thank you both


Join The Code Co-op to get access to your library in the Code Co-op Forum
Post Reply