Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

PHP, divs and layout issue!

Featured Replies

Hi guys, hopefully someone can give me a bit of help, as I'm out of idea's!!

 

I have been developing a boxing website for a while and am having some layout issues as I'm upgrading.

 

Basically the site news section I am going to make it pull the latest news from the database. Currently only the first topic is from the database, the rest of those news items are hardcoded into the html.

 

http://www.total-boxing.com/sitenews

 

The problem occurs in IE (and probably other browsers, I've mainly tested for Firefox, I know its a rookie mistake) anyway, all this content is currently in a div called "content" which is featured on most other pages. The problem occurs when you click the link. The content shifts to the left, and the footer becomes larger with a gap at the bottom of the footer image and the outline border.

 

I don't understand at all what is happening. The only difference between these pages is that the text in the content is being pulled from the database so in the readnews.php files it just has the echo commands to show the content.

 

I'm guessing this is the issue, because the other pages are all lined up in the middle and the footer is flush.

 

Can anyone give any advice of what potentially the problem is?? If it is not clear what the issue is I can try and re-type it in a more clear way! lol.

 

By the way I have looked over line after line for any differences in code, looking for missing php parts like semi colons etc and as far as I can tell nothin seems to be wrong! I'm pulling my hair out!

 

Cheers for now.

I've had a quick look, missing html doctype on the read more page

I'm not sure how your generating this page but I think by adding the doctype should fix it

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.