Avatar of EzEApostle
EzEApostle
 asked on

PHP <div> problem

Hi Experts,

Hope you can help me, I have a list of data which I'm dumping to the screen and If a record header matches another I dont want it to be repeated, if it doesnt then return the next line of data.

I've managed to get the headers to work correctly but now in certain circumstances it ignores the end table and div tags.

I've looked through the code numerous times but cant figure out how to add the tags where it's finishing, I've attached the code in a txt file with links to a working example and the incorrect example.

Can anyone tell me where I'm going wrong and where to add the end table and div tags?

Thanks in advance
league-detail.txt
PHP

Avatar of undefined
Last Comment
EzEApostle

8/22/2022 - Mon
mostart

you have to add your missing </div> and </table> tags to the end of your if {} structure. Not only to the end of the else {} part
ASKER CERTIFIED SOLUTION
bansidhar

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
SOLUTION
bansidhar

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
EzEApostle

ASKER
Thanks bansidhar, works a treat!

Thanks very much for all the help
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes