Get 2024 Templates Mega Bundle!14 Bootstrap, Vue & React Templates + 3 Vector Sets
Get for 99$

Metronic - Laravel v8.0.38 small bug in kt-swapper generator


I have a problem with the "page-title" in the layout, using laravel.<pre lang="php"></pre>

When i use this settings in config/demo1/general.php:

// Page title
"page-title" => array(
"display" => true, // Display page title
"breadcrumb" => true, // Display breadcrumb
"description" => true, // Display description
"layout" => "default", // Set layout(default|select)
"direction" => "row", // Flex direction(column|row))
"responsive" => true, // Move page title to cotnent on mobile mode
"responsive-breakpoint" => "lg", // Responsive breakpoint value(e.g: md, lg, or 300px)
"responsive-target" => "#kt_header_nav" // Responsive target selector
),


"print Html Attributes" generates an escape like this:



<div data-kt-swapper=&quot;true&quot; data-kt-swapper-mode=&quot;prepend&quot; data-kt-swapper-parent=&quot;{default: &#039;#kt_content_container&#039;, &#039;lg&#039;: &#039;#kt_header_nav&#039;}&quot; class="d-flex align-items-center me-3 flex-wrap mb-5 mb-lg-0 lh-1">



By removing the command "ob_get_clean ()" from the "print Html Attributes" function, everything works correctly.


<div data-kt-swapper="true" data-kt-swapper-mode="prepend" data-kt-swapper-parent="{default: "#kt_content_container", "lg": "#kt_header_nav"}" class="d-flex align-items-center me-3 flex-wrap mb-5 mb-lg-0 lh-1">


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(

Replies (2)


Hi happy

Please try to use it with {!! .. !!} instead of {{ .. }}. For example;


{!! theme()->printHtmlAttributes("body") !!}


Thanks



it works perfectly happy


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(