Vertical spacing between tags

Helpdesk for my helpdesk software

Moderator: mkoch227

Post Reply
ArcherData
Posts: 10
Joined: Wed Aug 18, 2021 1:22 am

Vertical spacing between tags

Post by ArcherData »

Script URL: https://archerdatahosting.com
Version of script: 3.2.4
Hosting company: Archer Data Hosting
URL of phpinfo.php: https://archerdatahosting.com/serverprofile.php
URL of session_test.php: ?
What terms did you try when SEARCHING for a solution: margin padding spacing

Write your message below:

I have noticed that whenever a <p>text</p> follows a <div></div> tag (in this case, the image is centered in a 100% width DIV) there is no vertical spacing with padding between the two. I've tried everything I can think of, but I cannot overcome this issue. Also, whenever a <p>text</p> follows <ul></ul> there is a double-space between the two, as shown at the bottom.

I would greatly appreciate some insight into these two issues. Thanks!

Image
Don
Archer Data Hosting
Klemen
Site Admin
Posts: 10142
Joined: Fri Feb 11, 2005 4:04 pm

Re: Vertical spacing between tags

Post by Klemen »

Could you provide the sample HTML code you use instead of the screenshot? I will see if I can spot the issue.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
ArcherData
Posts: 10
Joined: Wed Aug 18, 2021 1:22 am

Re: Vertical spacing between tags

Post by ArcherData »

Here's the code for what is in the screenshot:

Code: Select all

<div style="width:100%;padding-bottom:20px;">
<img src="https://archerdatahosting.com/helpdesk/kb/wp-security-list-02.webp" border="0" align="left" width="640" height="300" />
</div>

<p style="padding-top:10px;">The same goes for other software, like MySQL, MariaDB, cPanel, Plesk, and the server operating system.</p>

<ul>
<li style="padding-bottom: 10px;"><strong>Firewalls and other security defenses</strong>. There are literally hundreds of ways your hosting provider can keep their servers secure. If they own their own servers and are co-locating them, for example, putting strict controls on the ways someone can physically access that server, for example, is something they should be doing. They should also be using firewalls and other defense mechanisms, like intrusion detection to keep unauthorized users out.</li>
<li style="padding-bottom: 10px;"><strong>Malware monitoring and/or removal apps</strong>: You should select a host that makes an effort to detect and prevent malware infections, and possibly offers full-service malware scanning and removal. When doing your research, you should inquire what the policy is when the host spots an account infected with malware and whether they offer such services, and if so, what their costs are.</li>
</ul>
Don
Archer Data Hosting
Klemen
Site Admin
Posts: 10142
Joined: Fri Feb 11, 2005 4:04 pm

Re: Vertical spacing between tags

Post by Klemen »

Can you add

Code: Select all

style="margin-bottom: 10px;"
to the img tag?

As for <ul> you will need to overwrite the margin-top value which is set to 1em which seems to be the default browser value in most browsers (source):
margin-top: 0em;
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
ArcherData
Posts: 10
Joined: Wed Aug 18, 2021 1:22 am

Re: Vertical spacing between tags

Post by ArcherData »

Both helped and allowed me to remove styles from the <p>text</p> tags, making the content easier to read. Thank you so much for taking the time to review this issue for me. I really appreciate it!
Don
Archer Data Hosting
ArcherData
Posts: 10
Joined: Wed Aug 18, 2021 1:22 am

Re: Vertical spacing between tags

Post by ArcherData »

As a follow-up, I've tried to tweak the formatting of the vertical spacing. What I've learned is that it is far easier to just accept the spacing that's built it to Hesk and to not use inline styling to adjust it further. Inline styling is good for adjustments to fonts, alignment, table cell padding, etc., but not worth the effort to alter vertical spacing. Plain tags work best and are simply easier.
Don
Archer Data Hosting
Klemen
Site Admin
Posts: 10142
Joined: Fri Feb 11, 2005 4:04 pm

Re: Vertical spacing between tags

Post by Klemen »

You can always edit the defaults in the template style files :)
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Post Reply