Skip to content
TheChatArchiveThe Chat Archive
Qwenqwen3-235b-a22b-no-thinking· Alibaba (Qwen)Hugging Face LMArena Human Preference 140K

<?php $pagetitle = "অ্যাডমিট কার্ড"; include 'dbconnect.php'; include…

From a Chatbot Arena battleThe same person sent this prompt to two anonymous models at once. Compare it with Claudeclaude-opus-4-20250514’s answer.
  1. User
    <div class="admit-cards-container">
        <?php 
        $students = [];
        while ($student = $students_result->fetch_assoc()) {
            $students[] = $student;
        }
        
        // Group students into pairs for 2 cards per page
        for ($i = 0; $i < count($students); $i += 2): 
        ?>
            <div class="admit-card-page">
                <!-- First Card -->
                <div class="admit-card">
                    <!-- Header -->
                    <div class="admit-header text-center">
                        <h3 class="institution-name"><?php echo htmlspecialchars($institution_info['name']); ?></h3>
                        <p class="institution-address"><?php echo htmlspecialchars($institution_info['address']); ?></p>
                        <h4 class="admit-title">প্রবেশপত্র</h4>
                    </div>
    
                    <!-- Student Information -->
                    <div class="student-info">
                        <table class="info-table">
                            <tr>
                                <td><strong>ছাত্রের নাম:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i]['name_bn']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>স্টুডেন্ট আইডি:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i]['student_id']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>শ্রেণি:</strong></td>
                                <td><?php echo htmlspecialchars($class_name); ?></td>
                            </tr>
                            <tr>
                                <td><strong>পরীক্ষার নাম:</strong></td>
                                <td><?php echo htmlspecialchars($exam_details['exam_name']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>অভিভাবকের নাম:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i]['guardian_name_bn']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>মোবাইল নং:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i]['guardian_phone']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>সেশন:</strong></td>
                                <td><?php echo htmlspecialchars($exam_details['session_year']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>সিট নং:</strong></td>
                                <td></td>
                            </tr>
                        </table>
                    </div>
    
                    <!-- Signature Section -->
                    <div class="signature-section">
                        <div class="row">
                            <div class="col-4 text-center">
                                <div class="signature-line"></div>
                                <p>জামেয়া প্রধানের স্বাক্ষর</p>
                            </div>
                            <div class="col-4 text-center">
                                <div class="signature-line"></div>
                                <p>শিক্ষা পরিচালকের স্বাক্ষর</p>
                            </div>
                            <div class="col-4 text-center">
                                <div class="signature-line"></div>
                                <p>প্রধান শিক্ষকের স্বাক্ষর</p>
                            </div>
                        </div>
                    </div>
    
                    <!-- Footer Date Only -->
                    <div class="admit-footer">
                        <p class="issue-date">জারির তারিখ: 27/06/2025</p>
                    </div>
                </div>
    
                <!-- Second Card (if exists) -->
                <?php if (isset($students[$i + 1])): ?>
                <div class="admit-card">
                    <!-- Header -->
                    <div class="admit-header text-center">
                        <h3 class="institution-name"><?php echo htmlspecialchars($institution_info['name']); ?></h3>
                        <p class="institution-address"><?php echo htmlspecialchars($institution_info['address']); ?></p>
                        <h4 class="admit-title">প্রবেশপত্র</h4>
                    </div>
    
                    <!-- Student Information -->
                    <div class="student-info">
                        <table class="info-table">
                            <tr>
                                <td><strong>ছাত্রের নাম:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i + 1]['name_bn']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>স্টুডেন্ট আইডি:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i + 1]['student_id']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>শ্রেণি:</strong></td>
                                <td><?php echo htmlspecialchars($class_name); ?></td>
                            </tr>
                            <tr>
                                <td><strong>পরীক্ষার নাম:</strong></td>
                                <td><?php echo htmlspecialchars($exam_details['exam_name']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>অভিভাবকের নাম:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i + 1]['guardian_name_bn']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>মোবাইল নং:</strong></td>
                                <td><?php echo htmlspecialchars($students[$i + 1]['guardian_phone']); ?></td>
                            </tr>
                            <tr>
                                <td><strong>সেশন:</strong></td>
                                <td><?php echo htmlspecialchars($exam_details['session_year']); ?></td>
                            </tr>
                            <tr>
                            <td><strong>সিট নং:</strong></td>
                                <td></td>
                            </tr>
                        </table>
                    </div>
    
                    <!-- Signature Section -->
                    <div class="signature-section">
                        <div class="row">
                            <div class="col-4 text-center">
                                <div class="signature-line"></div>
                                <p>জামেয়া প্রধানের স্বাক্ষর</p>
                            </div>
                            <div class="col-4 text-center">
                                <div class="signature-line"></div>
                                <p>শিক্ষা পরিচালকের স্বাক্ষর</p>
                            </div>
                            <div class="col-4 text-center">
                                <div class="signature-line"></div>
                                <p>প্রধান শিক্ষকের স্বাক্ষর</p>
                            </div>
                        </div>
                    </div>
    
                    <!-- Footer Date Only -->
                    <div class="admit-footer">
                        <p class="issue-date">জারির তারিখ: 27/06/2025</p>
                    </div>
                </div>
                <?php endif; ?>
            </div>
        <?php endfor; ?>
    </div>
    
    <div class="alert alert-warning text-center">
        এই শ্রেণিতে কোনো সক্রিয় ছাত্র পাওয়া যায়নি।
    </div>
    

    When I try to print this admit card, the signature part of the first admit card on the page does not show, but the signature part of the second admit card does. So solve the problem of not showing the signature of the first admit card.

  2. Qwen Assistant

    The issue you're facing — where the signature section of the first admit card is not visible when printing, while the second one appears correctly — is likely due to how the layout and spacing are handled in print mode.

    ✅ Root Cause:

    In your @media print CSS, each .admit-card has a fixed height (height: 46vh) and uses absolute positioning for the footer. This can cause overflow or truncation if the content doesn't fit properly within the page boundaries.

    Also, the use of flex-direction: column; justify-content: flex-start; may not work as expected during printing, especially with strict height constraints.


    ✅ Solution:

    We will ensure that each card fits well on the printed page, and that all sections (including signature) are fully visible by:

    1. Using a table-based structure or non-flexbox layout for better print compatibility.
    2. Removing fixed heights.
    3. Ensuring proper margins and spacing.
    4. Avoiding overlapping elements using position: relative.

    ✅ Updated Print Styles (Replace your current @media print block):

    @media print {
        .no-print { display: none !important; }
    
        @page {
            size: A4 portrait;
            margin: 0.2in;
        }
    
        body {
            margin: 0;
            padding: 0;
            background: white;
            font-size: 11px;
        }
    
        .admit-card-page {
            page-break-after: always;
            margin: 0;
            padding: 0;
        }
    
        .admit-card {
            border: 2px solid #000;
            padding: 10px;
            margin: 5px auto;
            width: 98%;
            box-sizing: border-box;
            page-break-inside: avoid;
            position: relative;
        }
    
        .admit-header h3 {
            font-size: 16px;
            margin: 0 0 5px;
        }
    
        .admit-header p {
            font-size: 12px;
            margin: 0 0 5px;
        }
    
        .admit-title {
            font-size: 16px;
            padding: 6px 15px;
            margin-top: 10px;
        }
    
        .student-info table {
            width: 100%;
            font-size: 11px;
            margin-bottom: 10px;
        }
    
        .signature-section {
            margin-top: 10px;
            clear: both;
        }
    
        .signature-line {
            height: 20px;
            width: 80%;
            margin: 0 auto 5px;
            border-bottom: 1px solid #000;
        }
    
        .signature-section p {
            font-size: 9px;
            text-align: center;
            margin: 0;
        }
    
        .admit-footer {
            position: static;
            text-align: right;
            margin-top: 10px;
            font-size: 10px;
        }
    
        .issue-date {
            font-weight: bold;
            margin: 0;
        }
    }
    

    ✅ Optional HTML Adjustment (for better print control):

    Wrap each admit card inside a <div style="page-break-inside: avoid;"> to ensure it stays together on one printed page.

    Update this part in your PHP loop:

    <div class="admit-card" style="page-break-inside: avoid;">
    

    ✅ Summary of Fixes:

    Problematic AreaFix Applied
    Truncated signatureRemoved fixed height from .admit-card
    Layout issuesReplaced flexbox with standard layout
    Footer overlappingChanged footer to position: static
    Content overflowUsed page-break-inside: avoid per card

    After applying these changes, both cards on the same page should render completely, including the signature section of the first card.

    Let me know if you'd like to add automatic seat numbers or QR codes too!

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.