<."/> <."/> <"/>
خرید بک لینک

Vote count: 0

I really have big difficulties with Ajax, this time I'm not able to append some HTML code to a div.

I need to append to <div id="content-loader"></div> this HTML string

PHP

function getLogo(){
    $logo = '<div class="bg-logo-loading"></div>
            <div class="logo-loading-container">
                <div class="logo-loading-ier">
                    <div class="logo-loading">
                      <div></div>
                      <div></div>
                      <div></div>
                    </div>
                </div>
            </div>';
    retu $logo;
}

Using this Ajax POST:

JS

function showLoader(){
    $.ajax({
        type: "POST",
        url: baseUrl+"/requests/get_Logo.php",
        dataType : 'html',
        cache: false,
        success : function(html){
            $('#content-loader').html($(html.content).text());
        }
    });
}

get_Logo.php

<?php
include("../includes/config.php");
include("../includes/classes.php");

$feed = new feed();
echo $feed->getLogoLoading();
?>

Is there any chance to make it works?

asked 2 mins ago

برچسب: نویسنده: استخدام کار تاريخ: دوشنبه 18 مرداد 1395 ساعت: 6:17

صفحه بندی