Gelen veriyi php tarafından oturtamıyorum. Yardım edermisiniz?
<div data-kt-menu-trigger="{default: 'click', lg: 'hover'}" data-kt-menu-placement="bottom-start" class="menu-item menu-lg-down-accordion menu-sub-lg-down-indention me-0 me-lg-2">
<span class="menu-link py-3"><span class="menu-title">Ayarlar</span><span class="menu-arrow d-lg-none"></span></span>
<div class="menu-sub menu-sub-lg-down-accordion menu-sub-lg-dropdown px-lg-2 py-lg-4 w-lg-200px">
<div data-kt-menu-trigger="{default:'click', lg: 'hover'}" data-kt-menu-placement="right-start" class="menu-item menu-lg-down-accordion">
<span class="menu-link py-3"><span class="menu-icon"><i class="ki-duotone ki-rocket fs-2"><span class="path1"></span>
<span class="path2"></span></i></span><span class="menu-title">Site Ayarları</span><span class="menu-arrow"></span></span>
<div class="menu-sub menu-sub-lg-down-accordion menu-sub-lg-dropdown menu-active-bg px-lg-2 py-lg-4 w-lg-225px">
<div class="menu-item">
<a class="menu-link py-3" href=""><span class="menu-bullet"><span class="bullet bullet-dot"></span></span>
<span class="menu-title">ayar 2</span></a>
</div>
<div class="menu-item">
<a class="menu-link py-3" href=""><span class="menu-bullet"><span class="bullet bullet-dot"></span></span>
<span class="menu-title">ayar 3</span></a>
</div>
</div>
</div>
<div class="menu-item">
<a class="menu-link py-3" href="" target="_blank" title="test" data-bs-toggle="tooltip" data-bs-trigger="hover" data-bs-dismiss="click" data-bs-placement="right"><span class="menu-icon"><i class="ki-duotone ki-rocket fs-2"><span class="path1"></span><span class="path2"></span></i></span><span class="menu-title">test</span></a>
</div>
<div class="menu-item">
<a class="menu-link py-3" href="" target="_blank" title="test" data-bs-toggle="tooltip" data-bs-trigger="hover" data-bs-dismiss="click" data-bs-placement="right"><span class="menu-icon"><i class="ki-duotone ki-abstract-26 fs-2"><span class="path1"></span><span class="path2"></span></i></span><span class="menu-title">test 2</span></a>
</div>
<div class="menu-item">
<a class="menu-link py-3" href="" title="test" data-bs-toggle="tooltip" data-bs-trigger="hover" data-bs-dismiss="click" data-bs-placement="right"><span class="menu-icon"><i class="ki-duotone ki-switch fs-2"><span class="path1"></span><span class="path2"></span></i></span><span class="menu-title">test 3</span></a>
</div>
<div class="menu-item">
<a class="menu-link py-3" href="" target="_blank"><span class="menu-icon"><i class="ki-duotone ki-code fs-2"><span class="path1"></span><span class="path2"></span><span class="path3"></span><span class="path4"></span></i></span><span class="menu-title">test 5</span></a>
</div>
</div>
</div>
sql tablo
id | adi | kategori | parent_id |
---|---|---|---|
1 | Değer 1 | 0 | 0 |
2 | Değer 2 | 0 | 0 |
2 | Değer 3 | 1 | 0 |
2 | Değer 4 | 1 | 0 |
2 | Değer 5 | 2 | 4 |
2 | Değer 6 | 2 | 4 |
2 | Değer 7 | 2 | 1 |
tabloda bu şekilde kafam sürekli karışmtı takıldım
acaba bunu mysql çekerken burdaki kurala uygun bir şekilde nasıl birşey yapabilirim.
teşekkürler.