HEX
Server: Apache/2.4.59 (Debian)
System: Linux keymana 4.19.0-21-cloud-amd64 #1 SMP Debian 4.19.249-2 (2022-06-30) x86_64
User: lijunjie (1003)
PHP: 7.4.33
Disabled: 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_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/dk/wp-content/themes/food/single-影視專區.php
<?php
/**
 * The template for displaying all single posts
 *
 * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post
 *
 * @package WordPress
 * @subpackage Twenty_Twenty_One
 * @since Twenty Twenty-One 1.0
 */

echo 'single-影視專區 666 .php';


?>

<app id="app">
    <yq-header></yq-header>

    <div id="main_bg">

        <main class=" w-100 py-[0.2rem] md:w-[768px] md:mx-auto xl:w-[1280px]">

            <!--1-->
            <section class="text-gray-600 body-font">
                <div class="container  mx-auto flex flex-col">
                    <div class="md:w-[768px] md:mx-auto xl:w-[1280px]">
                        <div class="rounded-sm  overflow-hidden">

                            <video controls>
                                <source src="<?php echo get_template_directory_uri(); ?>/food-app/img/清明节测试.mp4" type="video/mp4">
                                您的浏览器不支持Video标签。
                            </video>

                        </div>

                        <div class="container px-1 py-1 mx-auto flex items-center sm:flex-row flex-col border-b-2 border-gray-200">
                            <a class="flex title-font font-medium items-center md:justify-start justify-center text-gray-900">
                                <span class="text-[0.2rem]">简介:</span>
                                <span class="ml-[0.13rem] text-[0.2rem]">香港最好吃的口味蟹就在...</span>
                            </a>

                            <span class="inline-flex sm:ml-auto sm:mt-0 mt-4 justify-center sm:justify-start">

                                <a class="ml-1 text-gray-500">
                                    <img class="w-[0.46rem] h-[0.46rem]" :src="local_url+'/img/zone_video/zan@2x.png'" alt="user" />
                                </a>
                                <a class="ml-1 text-gray-500">
                                    <img class="w-[0.46rem] h-[0.46rem]" :src="local_url+'/img/zone_video/keep@2x.png'" alt="user" />
                                </a>
                                <a class="ml-1 text-gray-500">
                                    <img class="w-[0.46rem] h-[0.46rem]" :src="local_url+'/img/zone_video/send@2x.png'" alt="user" />
                                </a>
                            </span>
                        </div>

                        <section class="text-gray-600 body-font overflow-hidden">
                            <div class="container px-1 py-1 mx-auto">

                                <div class="flex items-center flex-wrap mb-[0.51rem] mt-auto w-full">
                                    <a class="inline-flex items-center">
                                        <img alt="user" :src="local_url+'img/user.png'" class="w-[0.77rem] h-[0.77rem] rounded-full flex-shrink-0 object-cover object-center">
                                        <span class="flex-grow flex flex-col pl-[0.2rem]">
                                            <span class="title-font font-medium text-gray-900">Holden Caulfield</span>
                                            <span class="text-gray-400 text-[0.2rem] tracking-widest mt-[0.1rem]">UI DEVELOPER</span>
                                        </span>
                                    </a>
                                    <span class="text-gray-400 inline-flex items-center ml-auto leading-none py-1 ">
                                        <button class="flex mx-auto text-white bg-main-color border-0 py-1 px-1 focus:outline-none hover:bg-indigo-600 rounded-[0.05rem] text-[0.23rem]">關注</button>
                                    </span>

                                </div>


                                <div class="relative ">
                                    <label for="message" class="text-[0.31rem] text-gray-600">評論</label>

                                    <div class="flex items-center flex-wrap mb-[0.51rem] mt-[0.2rem] w-full">
                                        <a class="inline-flex w-full">
                                            <img alt="user" :src="local_url+'img/user.png'" class="w-[0.77rem] h-[0.77rem] rounded-full flex-shrink-0 object-cover object-center mr-[0.26rem]">
                                            <textarea id="message" name="message" class="w-full bg-gray-100 bg-opacity-50 rounded border border-gray-300 focus:border-indigo-500 focus:bg-white focus:ring-2 focus:ring-indigo-200 text-[0.20rem] outline-none text-gray-700 py-[0.1rem] px-[0.1rem] resize-none transition-colors duration-200 ease-in-out"></textarea>
                                        </a>


                                    </div>

                                </div>

                            </div>
                        </section>


                    </div>
                </div>
            </section>

            <!--  2-->
            <section class="text-gray-600 body-font">
                <div class="container flex flex-wrap">
                    <div class="py-[0.54rem] ml-[0.4rem] md:w-full">
                        <div class="flex border-b-2  border-gray-200 border-opacity-50 p-[0.2rem] sm:flex-row flex-col">
                            <!--                                <div class="[0.61rem] h-[0.61rem] mr-[0.26rem]  inline-flex items-center justify-center rounded-full bg-indigo-100 text-indigo-500 flex-shrink-0">-->
                            <div class="w-[0.8rem] h-[0.8rem] sm:mr-[0.26rem] sm:mb-0 mb-2  inline-flex items-center justify-center rounded-full bg-indigo-100 text-indigo-500 flex-shrink-0">
                                <svg fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" class="w-[0.45rem] h-[0.45rem] " viewBox="0 0 24 24">
                                    <path d="M20 21v-2a4 4 0 00-4-4H8a4 4 0 00-4 4v2"></path>
                                    <circle cx="12" cy="7" r="4"></circle>
                                </svg>
                            </div>
                            <div class="flex-grow">
                                <h2 class="text-gray-900 text-[0.23rem] title-font font-medium ">The Catalyzer</h2>
                                <p class="leading-relaxed text-[0.23rem]">Blue bottle crucifix vinyl post-ironic
                                    four
                                    dollar toast
                                    vegan taxidermy. Gastropub indxgo juice poutine.</p>

                                <div class="flex items-center flex-wrap mb-[0.13rem] mt-auto w-full">

                                    <span class="text-gray-400 inline-flex items-center mr-[0.2rem] leading-none text-[0.2rem] py-[0.13rem] pr-1">
                                        <svg class="w-[0.2rem] h-[0.2rem] mr-[0.1rem]" stroke="currentColor" stroke-width="2" fill="none" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24">
                                            <path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"></path>
                                            <circle cx="12" cy="12" r="3"></circle>
                                        </svg>1.2K
                                    </span>
                                    <span class="text-gray-400 inline-flex items-center leading-none text-[0.2rem]">
                                        <svg class="w-[0.2rem] h-[0.2rem] mr-[0.1rem]" stroke="currentColor" stroke-width="2" fill="none" stroke-linecap="round" stroke-linejoin="round" viewBox="0 0 24 24">
                                            <path d="M21 11.5a8.38 8.38 0 01-.9 3.8 8.5 8.5 0 01-7.6 4.7 8.38 8.38 0 01-3.8-.9L3 21l1.9-5.7a8.38 8.38 0 01-.9-3.8 8.5 8.5 0 014.7-7.6 8.38 8.38 0 013.8-.9h.5a8.48 8.48 0 018 8v.5z"></path>
                                        </svg>6
                                    </span>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </section>

        </main>
    </div>

    <yq-footer></yq-footer>
</app>

<script>
    const local_url = '<?php echo $local_url ?>'
    const home_info = JSON.parse('<?php echo json_encode($home_info) ?>')
    new Vue({
        el: "#app",
        components: {
            'yq-title': httpVueLoader('<?php showFoodAppPath('components/yq-title.vue?v=1') ?>'),
            'yq-food-list-one': httpVueLoader('<?php showFoodAppPath('components/yq-food-list-one.vue?v=1') ?>'),
            'yq-food-list-two': httpVueLoader('<?php showFoodAppPath('components/yq-food-list-two.vue?v=1') ?>'),
            'yq-header': httpVueLoader('<?php showFoodAppPath('components/yq-header.vue?v=5') ?>'),
            'yq-footer': httpVueLoader('<?php showFoodAppPath('components/yq-footer.vue?v=2') ?>'),
        },
        created() {
            // this.get_banner()
            // this.get_product_list_one()
            // this.get_product_list_two()
            // this.get_cate()
            //
            // this.linkBanner()
        },
        data: {
            banner_show: true,
            product_list_one: [],
            product_list_two: [],
            a_banner: [],
            banner_current: 0,
            a_cate: [],
            a_cate_product: [],
            current_cate: 0,
            scrollFlag: true,
            bannerObj: null
        },
        methods: {
            linkBanner() {
                this.bannerObj = setInterval(() => {
                    this.nextBanner()
                }, 8000);
            },
            toBannerLink() {
                if (this.a_banner[this.banner_current].banner_url) {
                    window.open(this.a_banner[this.banner_current].banner_url, '_blank')
                }
            },
            preBanner() {
                clearInterval(this.bannerObj)
                this.bannerObj = null

                this.banner_show = false

                setTimeout(() => {
                    let temp = this.banner_current - 1
                    this.banner_current = temp < 0 ? this.a_banner.length - 1 : temp

                    this.banner_show = true

                    this.linkBanner()
                }, 700);

            },
            nextBanner() {
                clearInterval(this.bannerObj)
                this.bannerObj = null

                this.banner_show = false

                setTimeout(() => {
                    let temp = this.banner_current + 1
                    this.banner_current = temp > this.a_banner.length - 1 ? 0 : temp

                    this.banner_show = true

                    this.linkBanner()
                }, 700);
            },
            async get_cate() {
                let res = await axios({
                    method: 'post',
                    url: '/api/',
                    data: Qs.stringify({
                        module: 'cate',
                        action: 'r_cate'
                    })
                });

                if (res.status == 200) {
                    let data = res.data;
                    if (data.rc == 0) {
                        this.a_cate = data.res.cate_list
                        this.a_cate_product = data.res.product_list
                    }
                }

                if (this.scrollFlag) {
                    this.scrollFlag = false
                    setTimeout(() => {
                        this.$nextTick(() => {
                            if (window.location.href.indexOf('#') > -1) {
                                window.scrollTo({
                                    top: document.getElementById(window.location.href.split('#')[1]).offsetTop,
                                    behavior: 'smooth'
                                })
                            }
                        })
                    }, 0);
                }
            },
            async get_cate_product(key) {
                this.current_cate = key
                let res = await axios({
                    method: 'post',
                    url: '/api/',
                    data: Qs.stringify({
                        module: 'product',
                        action: 'get_product_by_cate',
                        cate: [this.a_cate[this.current_cate]],
                        limit: 6
                    })
                });

                if (res.status == 200) {
                    let data = res.data;
                    if (data.rc == 0) {
                        this.a_cate_product = data.res
                    }
                }
            },
            async get_banner() {
                let res = await axios({
                    method: 'post',
                    url: '/api/',
                    data: Qs.stringify({
                        module: 'banner',
                        action: 'get_banner',
                        banner_type: 1
                    })
                });

                if (res.status == 200) {
                    let data = res.data;
                    if (data.rc == 0) {
                        this.a_banner = data.res
                    }
                }
            },
            async get_product_list_one() {
                let res = await axios({
                    method: 'post',
                    url: '/api/',
                    data: Qs.stringify({
                        module: 'product',
                        action: 'get_product_by_cate',
                        cate: [home_info.cate1],
                        limit: 6
                    })
                });

                if (res.status == 200) {
                    let data = res.data;
                    if (data.rc == 0) {
                        this.product_list_one = data.res
                    }
                }

            },
            async get_product_list_two() {
                let res = await axios({
                    method: 'post',
                    url: '/api/',
                    data: Qs.stringify({
                        module: 'product',
                        action: 'get_product_by_date',
                        limit: 4
                    })
                });

                if (res.status == 200) {
                    let data = res.data;
                    if (data.rc == 0) {
                        this.product_list_two = data.res
                    }
                }
            }
        }
    })
</script>