https://t.me/RX1948
Server : Apache/2.4.18 (Ubuntu)
System : Linux canvaswebdesign 3.13.0-71-generic #114-Ubuntu SMP Tue Dec 1 02:34:22 UTC 2015 x86_64
User : oppastar ( 1041)
PHP Version : 7.0.33-0ubuntu0.16.04.15
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
Directory :  /var/www/laciasmara.com/public_html/shop/application/views/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/laciasmara.com/public_html/shop/application/views/preview.php
<div class="figma-container">
    <div class="view-toggle">
        <button id="web-toggle" class="toggle-btn active">Web View</button>
        <button id="mobile-toggle" class="toggle-btn">Mobile View</button>
    </div>
    <!-- Loading Spinner -->
    <div class="loading-spinner" id="loading-spinner">
        <div class="spinner"></div>
        <p>Loading, please wait...</p>

    </div>

    <iframe id="figma-web" class="figma-frame active" style="border: 1px solid rgba(0, 0, 0, 0.1);" width="100%" height="100%"
        src="https://embed.figma.com/proto/QBGSAfwRoYNnLgeslODmLV/Laci-Asmara---New?page-id=3%3A5&node-id=513-594&node-type=canvas&viewport=-1194%2C185%2C0.42&scaling=min-zoom&content-scaling=fixed&starting-point-node-id=513%3A594&embed-host=share"
        allowfullscreen></iframe>

    <!-- Mobile -->
    <iframe id="figma-mobile" class="figma-frame" style="border: 1px solid rgba(0, 0, 0, 0.1);" width="450" height="850"
        src="https://embed.figma.com/proto/QBGSAfwRoYNnLgeslODmLV/Laci-Asmara---New?page-id=3%3A5&node-id=523-624&node-type=canvas&viewport=-1194%2C185%2C0.42&scaling=min-zoom&content-scaling=fixed&starting-point-node-id=523%3A624&embed-host=share"
        allowfullscreen></iframe>
</div>


<div class="comment-section">
    <h3 class="comment-title">Comments</h3>

    <div class="comments-list">
        <?php if (!empty($comments)): ?>
            <?php foreach ($comments as $comment): ?>
                <div class="comment-card">
                    <div class="comment-header">
                        <span class="comment-name"><?= htmlspecialchars($comment['name']); ?></span>
                        <span class="comment-date"><?= date('F j, Y, g:i a', strtotime($comment['created_at'])); ?></span>
                    </div>
                    <p class="comment-content"><?= nl2br(htmlspecialchars($comment['content'])); ?></p>

                    <button class="reply-btn" onclick="toggleReplyForm(<?= $comment['id']; ?>)">Reply</button>

                    <div id="reply-form-<?= $comment['id']; ?>" class="reply-form" style="display: none;">
                        <form method="POST" action="<?= site_url('preview/add_reply_comment'); ?>">
                            <input type="hidden" name="comment_id" value="<?= $comment['id']; ?>" />
                            <input type="hidden" name="<?= $this->security->get_csrf_token_name(); ?>" value="<?= $this->security->get_csrf_hash(); ?>" />
                            <textarea name="reply_comment" rows="4" class="comment-textarea" placeholder="Add a reply..." required></textarea>
                            <button type="submit" class="comment-submit">Submit</button>
                        </form>
                    </div>

                    <?php if (!empty($comment['replies'])): ?>
                        <div class="replies">
                            <?php foreach ($comment['replies'] as $reply): ?>
                                <div class="reply-card">
                                    <div class="reply-header">
                                        <span class="reply-name"><?= htmlspecialchars($reply['name']); ?></span>
                                        <span class="reply-date"><?= date('F j, Y, g:i a', strtotime($reply['created_at'])); ?></span>
                                    </div>
                                    <p class="reply-content"><?= nl2br(htmlspecialchars($reply['content'])); ?></p>
                                </div>
                            <?php endforeach; ?>
                        </div>
                    <?php endif; ?>
                </div>
            <?php endforeach; ?>
        <?php else: ?>
            <p>No comments yet.</p>
        <?php endif; ?>
    </div>

    <form method="POST" action="<?= site_url('preview/add_comment'); ?>" class="comment-form">
        <input type="hidden" name="<?= $this->security->get_csrf_token_name(); ?>" value="<?= $this->security->get_csrf_hash(); ?>" />
        <textarea name="comment" rows="4" class="comment-textarea" placeholder="Any suggestion..." required></textarea>
        <button type="submit" class="comment-submit">Submit</button>
    </form>
</div>


<style>
    .comment-section {
        margin-top: 40px;
        padding: 30px;
        font-family: 'Roboto', sans-serif;
        background-color: #fafafa;
        border-radius: 10px;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    }

    .comment-title {
        font-size: 1.75rem;
        font-weight: 600;
        color: #333;
        margin-bottom: 15px;
    }

    .comments-list {
        margin-top: 25px;
    }

    .comment-card {
        padding: 20px;
        margin-bottom: 20px;
        background-color: #ffffff;
        border-radius: 10px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.12);
        transition: box-shadow 0.3s ease;
    }

    .comment-card:hover {
        box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    }

    .comment-header {
        display: flex;
        justify-content: space-between;
        font-size: 0.9rem;
        color: #6c757d;
        margin-bottom: 10px;
    }

    .comment-name {
        font-weight: 600;
        color: #5a5a5a;
    }

    .comment-date {
        color: #9e9e9e;
    }

    .comment-content {
        margin-top: 10px;
        font-size: 1rem;
        color: #333;
    }

    .reply-btn {
        margin-top: 15px;
        padding: 10px 18px;
        background-color: #7A4397;
        color: white;
        border: none;
        border-radius: 8px;
        cursor: pointer;
        font-size: 1rem;
        transition: background-color 0.3s ease;
    }

    .reply-btn:hover {
        background-color: #5e2a76;
    }

    .reply-form {
        margin-top: 20px;
        padding: 15px;
        background-color: #f9f9f9;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    }

    .reply-card {
        margin-top: 15px;
        padding-top: 24px;
        padding-bottom: 24px;
        padding-left: 24px;
        background-color: #f9f9f9;
        border-radius: 8px;
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
    }

    .reply-header {
        display: flex;
        justify-content: space-between;
        font-size: 0.875rem;
        color: #6c757d;
        margin-bottom: 8px;
    }

    .reply-name {
        font-weight: bold;
        color: #5a5a5a;
    }

    .reply-date {
        color: #9e9e9e;
    }

    .reply-content {
        margin-top: 8px;
        color: #333;
        font-size: 1rem;
    }

    .comment-form {
        margin-top: 30px;
        background-color: #ffffff;
        padding: 20px;
        border-radius: 8px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    .comment-textarea {
        width: 100%;
        padding: 12px;
        border: 1px solid #ccc;
        border-radius: 8px;
        box-sizing: border-box;
        font-size: 1rem;
        resize: vertical;
        transition: border-color 0.3s ease;
    }

    .comment-textarea:focus {
        border-color: #7A4397;
        outline: none;
    }

    .comment-submit {
        margin-top: 15px;
        padding: 12px 25px;
        background-color: #7A4397;
        color: white;
        border: none;
        border-radius: 8px;
        cursor: pointer;
        font-size: 1rem;
        transition: background-color 0.3s ease;
    }

    .comment-submit:hover {
        background-color: #5e2a76;
    }

    .figma-container {
        position: relative;
        height: 100vh;
    }

    .view-toggle {
        position: fixed;
        top: 20px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 1000;
        display: flex;
        gap: 10px;
        background-color: white;
        padding: 10px;
        border-radius: 12px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }

    .toggle-btn {
        padding: 10px 20px;
        border: none;
        border-radius: 8px;
        cursor: pointer;
        font-size: 1rem;
        transition: all 0.3s ease;
        background-color: #f0f0f0;
        color: #666;
    }

    .toggle-btn.active {
        background-color: #7A4397;
        color: white;
    }

    .toggle-btn:hover:not(.active) {
        background-color: #e0e0e0;
    }

    .figma-frame {
        display: none;
    }

    .figma-frame.active {
        display: block;
    }

    /* Center mobile frame */
    #figma-mobile.active {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }

    .loading-spinner {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -60%);
        text-align: center;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        color: #7A4397;
        font-size: 1.2rem;
    }

    .spinner {
        border: 4px solid #f3f3f3;
        border-top: 4px solid #7A4397;
        border-radius: 50%;
        width: 50px;
        height: 50px;
        animation: spin 1s linear infinite;
    }

    @keyframes spin {
        0% {
            transform: rotate(0deg);
        }

        100% {
            transform: rotate(360deg);
        }
    }

    #figma-embed {
        display: none;
        width: 100%;
        height: 100%;
    }

    .loading-spinner p {
        margin-top: 12px;
        font-size: 1.2rem;
        color: #7A4397;
        font-weight: 500;
    }
</style>


<!-- JavaScript -->
<script>
    window.onload = function() {
        const webIframe = document.getElementById('figma-web');
        const mobileIframe = document.getElementById('figma-mobile');
        const loadingSpinner = document.getElementById('loading-spinner');
        const webToggle = document.getElementById('web-toggle');
        const mobileToggle = document.getElementById('mobile-toggle');

        function switchView(view) {
            if (view === 'web') {
                webIframe.classList.add('active');
                mobileIframe.classList.remove('active');
                webToggle.classList.add('active');
                mobileToggle.classList.remove('active');
            } else {
                webIframe.classList.remove('active');
                mobileIframe.classList.add('active');
                webToggle.classList.remove('active');
                mobileToggle.classList.add('active');
            }
        }

        // Initial view based on screen size
        function setInitialView() {
            if (window.innerWidth <= 768) {
                switchView('mobile');
            } else {
                switchView('web');
            }
        }

        setInitialView();

        // Event listeners for toggle buttons
        webToggle.addEventListener('click', () => switchView('web'));
        mobileToggle.addEventListener('click', () => switchView('mobile'));

        // Hide loading spinner when either frame loads
        webIframe.onload = mobileIframe.onload = function() {
            loadingSpinner.style.display = 'none';
        };

        // Optional: Update view on resize
        window.addEventListener('resize', setInitialView);
    };

    function toggleReplyForm(commentId) {
        var form = document.getElementById("reply-form-" + commentId);
        form.style.display = form.style.display === "none" || form.style.display === "" ? "block" : "none";
    }
</script>

https://t.me/RX1948 - 2025