Beispiel #1
0
        ?>
</span></a>
            <a style="display: inline-block;" class="btn">
              <strong><?php 
        echo $appInfo['downloads'];
        ?>
 Downloads</strong>
            </a>
            <a href="http://server.lobby.sim/docs/install-app" class="btn" target="_blank">Installation Help</a>
          </div>
          <?php 
        require_once $this->dir . "/src/inc/Fr.star.php";
        $this->addScript("Fr.star.js");
        $star = new \Fr\Star(array(), "app-{$appInfo['id']}");
        echo "<div class='ratings'>";
        echo $star->getRating("ableToRate");
        echo "<div id='rating'></div>";
        echo "</div>";
        ?>
          <script>
            window.addEventListener("load", function(){
              function fr_star(){
                $(".contents .ratings #rating").text($(".Fr-star").data("title"));
                $(".Fr-star").Fr_star(function(rating){
                  lobby.ajax("rate.php", {'id' : '<?php 
        echo "app-{$appInfo['id']}";
        ?>
', 'rating': rating}, function(r){
                    if(r == "error"){
                      alert("You have to log in to rate apps");
                    }else{