Heyhoe Posted December 11, 2016 Share Posted December 11, 2016 I can usually muddle my way through these kind of things but this one has me stumped. Basically, as you can see in the above screenshots, I want the Title, user, price and questions data to be inline with the record image on mobile. If I uncheck "Block" on the firefox rules, the content moves to where I want it. I tried this code: /* Smartphones (portrait and landscape) ----------- */ @media screen and (max-width: 979px) { /* Styles */ [data-pageapp='classifieds'].ipsDataList .ipsDataItem_main { display: inline; } However, this does not work. I'm obviously not using the correct classes and it is inheriting "block" from somewhere else. It looks like there are loads of classes using the same CSS and I don't want to mess up anything by using unnecessary classes. If somebody could point me in the right direction it would be appreciated. Thanks guys. Link to comment Share on other sites More sharing options...
Heyhoe Posted December 11, 2016 Author Share Posted December 11, 2016 Sorted! Probably not correctly mind. I just copied all of the CSS selectors in the big list and set the display to "table-cell" and it seems to have sorted it.. Link to comment Share on other sites More sharing options...
Heyhoe Posted December 11, 2016 Author Share Posted December 11, 2016 UGH! This didn't work as it messed up the CSS on the main page with the categories listing. Is there any way to target a single page within an app?? Link to comment Share on other sites More sharing options...
Adlago Posted December 11, 2016 Share Posted December 11, 2016 1 hour ago, Heyhoe said: /* Smartphones (portrait and landscape) ----------- */ @media screen and (max-width: 979px) { /* Styles */ [data-pageapp='classifieds'].ipsDataList .ipsDataItem_main { display: inline; } In this code you are missing a closing brace "}" Link to comment Share on other sites More sharing options...
TAMAN Posted December 11, 2016 Share Posted December 11, 2016 You can target by data-baseurl="http://www.kartreview.co.uk/classifieds/category/1-for-sale/?page=1" to apply only on that page @media screen and (max-width: 979px) { [data-pageapp='classifieds'] [data-baseurl="http://www.kartreview.co.uk/classifieds/category/1-for-sale/?page=1"] .ipsDataList .ipsDataItem_main { display: table-cell; } } or everywhere on classifieds page @media screen and (max-width: 979px) { [data-pageapp="classifieds"] .ipsDataList .ipsDataItem_main { display: table-cell; } } Link to comment Share on other sites More sharing options...
Heyhoe Posted December 12, 2016 Author Share Posted December 12, 2016 Thanks for the help TAMAN. Could you use a partial URL in the data-baseurl?, such as: [data-baseurl="http://www.kartreview.co.uk/classifieds/category"] .ipsDataList .ipsDataItem_main which would target pages containing that URL? For now I have added some inline CSS on the template of the category template which seems to do the job but is not ideal for upgrades etc. Link to comment Share on other sites More sharing options...
TAMAN Posted December 12, 2016 Share Posted December 12, 2016 51 minutes ago, Heyhoe said: Thanks for the help TAMAN. Could you use a partial URL in the data-baseurl?, such as: [data-baseurl="http://www.kartreview.co.uk/classifieds/category"] .ipsDataList .ipsDataItem_main which would target pages containing that URL? For now I have added some inline CSS on the template of the category template which seems to do the job but is not ideal for upgrades etc. No, this is auto generated if you dont want to apply the css on .ipsDataItem_main on other pages you could just target by this id elTable_68cdb9dfa56b2f6a5bf628131a316fb5 Its in the page category @media screen and (max-width: 979px) { #elTable_68cdb9dfa56b2f6a5bf628131a316fb5 .ipsDataList .ipsDataItem_main { display: table-cell; } } this will target the category you posted in the image above Link to comment Share on other sites More sharing options...
Ohio Guns Posted December 12, 2016 Share Posted December 12, 2016 Have you tried just adding it to the classifieds CSS so it won't mess with the forums CSS? Link to comment Share on other sites More sharing options...
Heyhoe Posted December 12, 2016 Author Share Posted December 12, 2016 Its messing up the category listings on the Classifieds app @Ohio Guns. Thanks TAMAN, that's worked! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.