5
1
Fork 0
mirror of https://github.com/Anvilcraft/jensmemes synced 2024-11-25 22:02:30 +01:00

Update memecat.php

This commit is contained in:
ITbyHF 2020-09-02 23:09:39 +02:00 committed by GitHub
parent 246feef307
commit 38de26210a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -31,9 +31,8 @@ foreach ($cats as $cate){
'; ';
foreach ($cats as $catdis) { foreach ($cats as $catdis) {
if($catdis->name!=$cate->name){ if($catdis->id!=$cate->id){
$cat_dis = str_replace(" ", '_', $catdis->name); echo '$("#'.$catdis->name.'").hide();';
echo '$("#'.$cat_dis.'").hide();';
} }
} }
echo ' echo '
@ -58,7 +57,6 @@ echo '
global $cats; global $cats;
$c = 0; $c = 0;
foreach ($cats as $cate) { foreach ($cats as $cate) {
$cate->id = str_replace(' ', '_', $cate->name);
if($c==0){ if($c==0){
echo '<option value="'.$cate->id.'" selected>'.$cate->name.'</option>'; echo '<option value="'.$cate->id.'" selected>'.$cate->name.'</option>';
$c=1; $c=1;