درخواست حل یک مشکل در تبدیل قالب html به وردپرس

  • نویسنده موضوع ameen
  • تاریخ شروع

ameen

کاربر عضو
با عرض سلام و احترام

یک قالب html داشتم که به وردپرس تبدیل کردم

قالب html :



قالب تبدیل شده:



لطفا نحوه چینش مطالب در صفحه اصلی قالب html را ببینید

اما در قالب تبدیل شده به وردپرس مشکل داره

کجای کار رو اشتباه رفتم ؟

کد php بخش مطالب:

<?php while(have_posts()) : the_post(); ?>
<div class="simple-content">
<a href="<?php the_permalink(); ?>" class="simple-item">
<?php the_post_thumbnail(); ?></a>
<h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
</div>
</div>
<?php endwhile; ?>


ممنون

 
آخرین ویرایش توسط مدیر:

soltaneghalbha

کاربر عضو
سلام

این  را تست کنید:

کد:
<div class="simple-content">
		<?php while(have_posts()) : the_post(); ?>
            <a href="<?php the_permalink(); ?>" class="simple-item">
                <?php the_post_thumbnail(); ?></a>
                <h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
		<?php endwhile; ?>
        </div>
</div>
 
آخرین ویرایش توسط مدیر:

ameen

کاربر عضو
یکم تغییر کرد ولی هنوز دقیق همون نشده

 

soltaneghalbha

کاربر عضو
امکانش هست کدای index.php رو قرار بدید

 
آخرین ویرایش توسط مدیر:

ameen

کاربر عضو
کد:
<?php get_header(); ?>
    <div class="container">
        <div class="header-content">
            <h1>
                <span><?php bloginfo('description'); ?></span>
            </h1>
            <img src="<?php bloginfo('template_url'); ?>/images/payamneshan-head.jpg" />
        </div>
        <div class="more-section">
            <a class="button" href="site/categorys.html?دسته_بندی">بیشتر</a>
            <a class="title" href="#">دسته‌بندی‌ها</a>
        </div>

        <div style="text-align:center;margin-bottom:10px">
            <a class="cat-item" href="#">
                <img src="files/category/1.png">
                <h1>تولد</h1>
            </a>
            <a class="cat-item" href="#">
                <img src="files/category/14.png">
                <h1>روز و شب بخیر</h1>
            </a>
            <a class="cat-item" href="#">
                <img src="files/category/5.png">
                <h1>تبریک ازدواج</h1>
            </a>
            <a class="cat-item" href="#">
                <img src="files/category/9.png">
                <h1>جالب</h1>
            </a>
        </div>
        <div class="tabligh-content" style="text-align:center;background-color: #2ca5e0;">
            <a href="tg://resolve?domain=paasaaj" target="_blank"><img style="max-width: 100%;" src="<?php bloginfo('template_url'); ?>/images/telegram.jpg" /></a>
        </div>
<div class="more-section" style="margin-bottom:10px">
            <a class="button" href="#">بیشتر</a>
            <a class="title" href="#">دسته‌بندی‌ها</a>
        </div>
<div class="simple-content">
		<?php while(have_posts()) : the_post(); ?>
            <a href="<?php the_permalink(); ?>" class="simple-item">
                <?php the_post_thumbnail(); ?></a>
                <h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
		<?php endwhile; ?>
        </div>
</div>
        <div class="tabligh-content" style="text-align:center;background-color: #00bcd4;">
            <a href="#" target="_blank"><img style="max-width: 100%;" src="<?php bloginfo('template_url'); ?>/images/babyname.jpg" /></a>
        </div><br>
<?php get_footer(); ?>
 

soltaneghalbha

کاربر عضو
کد:
<?php get_header(); ?>
    <div class="container">
        <div class="header-content">
            <h1>
                <span><?php bloginfo('description'); ?></span>
            </h1>
            <img src="<?php bloginfo('template_url'); ?>/images/payamneshan-head.jpg" />
        </div>
        <div class="more-section">
            <a class="button" href="site/categorys.html?دسته_بندی">بیشتر</a>
            <a class="title" href="#">دسته‌بندی‌ها</a>
        </div>

        <div style="text-align:center;margin-bottom:10px">
            <a class="cat-item" href="#">
                <img src="files/category/1.png">
                <h1>تولد</h1>
            </a>
            <a class="cat-item" href="#">
                <img src="files/category/14.png">
                <h1>روز و شب بخیر</h1>
            </a>
            <a class="cat-item" href="#">
                <img src="files/category/5.png">
                <h1>تبریک ازدواج</h1>
            </a>
            <a class="cat-item" href="#">
                <img src="files/category/9.png">
                <h1>جالب</h1>
            </a>
        </div>
        <div class="tabligh-content" style="text-align:center;background-color: #2ca5e0;">
            <a href="tg://resolve?domain=paasaaj" target="_blank"><img style="max-width: 100%;" src="<?php bloginfo('template_url'); ?>/images/telegram.jpg" /></a>
        </div>
		<div class="more-section" style="margin-bottom:10px">
					<a class="button" href="#">بیشتر</a>
					<a class="title" href="#">دسته‌بندی‌ها</a>
		</div>
		<div class="simple-content">
				<?php if (have_posts() ) : ?>
					<?php while (have_posts() ) : the_post(); ?>
					<a class="simple-item" href="<?php the_permalink(); ?>" > <?php the_post_thumbnail(); ?>
						<h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
					</a>
				<?php endwhile; ?> 
				<?php endif; ?>
		</div>
</div>
        <div class="tabligh-content" style="text-align:center;background-color: #00bcd4;">
            <a href="#" target="_blank"><img style="max-width: 100%;" src="<?php bloginfo('template_url'); ?>/images/babyname.jpg" /></a>
        </div><br>
<?php get_footer(); ?>
 

soltaneghalbha

کاربر عضو
<a class="simple-item"> رو به div تبدیل کنید، ببینید درست میشه

<div class="simple-content">
<?php if (have_posts() ) : ?>
<?php while (have_posts() ) : the_post(); ?>
<div class="simple-item"><a href="<?php the_permalink(); ?>" > <?php the_post_thumbnail(); ?> </a>
<h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
</div>
<?php endwhile; ?>
<?php endif; ?>
</div>


باز هم نشد، صبر کنید اساتید بزرگوار بیان راهنمایی کنند

 
بالا