We’re with you. JoomShaper is offering a 20% Discount on all plans due to the impact of COVID-19.

Support Offline : Mon - Fri / 10am - 6pm (GMT +6)

Your Time: Our Time:

Remove CSS / insert CSS per PHP with Pagebuilder

Featured Lock Resolved Issue
Hi,

i need to know what command you use for inserting inline CSS.
Look this Code, How is the PHP for that (the php part which inserts the dynamicall inline CSS?


<link href="/components/com_sppagebuilder/assets/css/animate.min.css" rel="stylesheet" type="text/css" />
<link href="/components/com_sppagebuilder/assets/css/sppagebuilder.css" rel="stylesheet" type="text/css" />
<link href="/components/com_sppagebuilder/assets/css/sppagecontainer.css" rel="stylesheet" type="text/css" />
<link href="/components/com_sppagebuilder/assets/css/magnific-popup.css" rel="stylesheet" type="text/css" />
<style type="text/css">
.sp-page-builder .page-content #section-id-1571599459721{padding-top:50px;padding-right:0px;padding-bottom:50px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;color:#682582;background-color:#F7F7F7;}#column-id-1571599459720{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599459727 {margin:0px 0px 30px 0px;}#sppb-addon-1571599459727 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599459727 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599459727 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599459730 {margin:0px 0px 30px 0px;}#sppb-addon-1571599459730 {box-shadow:0 0 0 0 #ffffff;}#sppb-addon-1571599459730 .sppb-addon-title {font-size:20pxpx;line-height:20pxpx;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-1571599459730 .sppb-addon-title {font-size:pxpx;line-height:pxpx;}#sppb-addon-wrapper-1571599459730 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-1571599459730 .sppb-addon-title {font-size:pxpx;line-height:pxpx;}#sppb-addon-wrapper-1571599459730 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707536{padding-top:50px;padding-right:0px;padding-bottom:10px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;}#column-id-1571599707537{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707538 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707538 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707538 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707538 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707540 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707540 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707540 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707540 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707541{padding-top:0px;padding-right:0px;padding-bottom:10px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;}#column-id-1571599707542{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707543 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707543 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707543 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707543 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707545 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707545 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707545 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707545 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707546{padding-top:0px;padding-right:0px;padding-bottom:10px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;}#column-id-1571599707547{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707548 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707548 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707548 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707548 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707550 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707550 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707550 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707550 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707536{padding-top:50px;padding-right:0px;padding-bottom:50px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;background-color:#F7F7F7;}#column-id-1571599707535{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707539 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707539 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707539 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707539 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707542 {margin:4px 0px 30px 0px;}#sppb-addon-1571599707542 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707542 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707542 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}
</style>


Other Question: How can i delete CSS per Site per PHP?
i have following for turning off scripts:


$doc = JFactory::getDocument();

$dontInclude = array(
'/components/com_sppagebuilder/assets/js/jquery.magnific-popup.min.js',
'/components/com_sppagebuilder/assets/js/jquery.parallax.js',
'/components/com_sppagebuilder/assets/js/sppagebuilder.js',
'/media/jui/js/jquery.js',
'/media/jui/js/jquery.min.js',
'/media/jui/js/jquery-noconflict.js',
'/media/jui/js/jquery-migrate.js',
'/media/jui/js/jquery-migrate.min.js',
'/media/jui/js/bootstrap.js',
'/media/system/js/core-uncompressed.js',
'/media/system/js/tabs-state.js',
'/media/system/js/core.js',
'/media/system/js/core.js?',
'/media/system/js/mootools-core.js',
'/media/system/js/mootools-core-uncompressed.js',
);



foreach($doc->_scripts as $key => $script){
if(in_array($key, $dontInclude)){
unset($doc->_scripts[$key]);

}
}


that works good, but can't delete CSS with that.

3 Answers

Ofi Khan - Staff

More than a month ago #Permalink
As our support policy, we don't give PHP support.
For adding custom style, please use Custom CSS.

- Best regards

Daniel

More than a month ago #Permalink
? I just need a quick info how this line of Code is generated.


<style type="text/css">
.sp-page-builder .page-content #section-id-1571599459721{padding-top:50px;padding-right:0px;padding-bottom:50px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;color:#682582;background-color:#F7F7F7;}#column-id-1571599459720{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599459727 {margin:0px 0px 30px 0px;}#sppb-addon-1571599459727 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599459727 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599459727 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599459730 {margin:0px 0px 30px 0px;}#sppb-addon-1571599459730 {box-shadow:0 0 0 0 #ffffff;}#sppb-addon-1571599459730 .sppb-addon-title {font-size:20pxpx;line-height:20pxpx;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-1571599459730 .sppb-addon-title {font-sizexpx;line-heightxpx;}#sppb-addon-wrapper-1571599459730 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-1571599459730 .sppb-addon-title {font-sizexpx;line-heightxpx;}#sppb-addon-wrapper-1571599459730 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707536{padding-top:50px;padding-right:0px;padding-bottom:10px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;}#column-id-1571599707537{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707538 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707538 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707538 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707538 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707540 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707540 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707540 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707540 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707541{padding-top:0px;padding-right:0px;padding-bottom:10px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;}#column-id-1571599707542{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707543 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707543 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707543 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707543 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707545 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707545 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707545 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707545 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707546{padding-top:0px;padding-right:0px;padding-bottom:10px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;}#column-id-1571599707547{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707548 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707548 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707548 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707548 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707550 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707550 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707550 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707550 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}.sp-page-builder .page-content #section-id-1571599707536{padding-top:50px;padding-right:0px;padding-bottom:50px;padding-left:0px;margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0px;background-color:#F7F7F7;}#column-id-1571599707535{box-shadow:0 0 0 0 #fff;}#sppb-addon-wrapper-1571599707539 {margin:0px 0px 30px 0px;}#sppb-addon-1571599707539 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707539 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707539 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}#sppb-addon-wrapper-1571599707542 {margin:4px 0px 30px 0px;}#sppb-addon-1571599707542 {box-shadow:0 0 0 0 #ffffff;}@media (min-width:768px) and (max-width:991px) {#sppb-addon-wrapper-1571599707542 {margin-top:0px;margin-right:0px;margin-bottom:20px;margin-left:0px;}}@media (max-width:767px) {#sppb-addon-wrapper-1571599707542 {margin-top:0px;margin-right:0px;margin-bottom:10px;margin-left:0px;}}
</style>


Because i want to rearrange my component.php File.
Please?

i didn't talked about a custom.css File. Thats the easiest thing on the World.


There are no replies made for this post yet.
Be one of the first to reply to this post!

124

Templates

331450

Community Users

Newsletter

Don’t miss any updates of our new templates and extensions and all the astonishing offers we bring for you.
We never spam

Joomla! ® name is used under a limited license from Open Source Matters in the United States and other countries. JoomShaper.com is not affiliated with or endorsed by Open Source Matters or the Joomla! Project.

Connect Us