Hi, folks! Here is a brand new update for MyArcadeBlog WordPress Plugin. What happened since last update?

MyArcadeBlog has been downloaded over 750 times and got only three votes. Come on people, vote vote vote!

Special thanks this time goes to Dr. Tux for donating and bug reporting :)

If you don’t know what MyArcadeBlog is, see this post.

1.6 Changelog

Because the Mochiads has changed the page structure and now all invalid links will be resisted so that we don’t get an error message if the download fail. For that reason, I have implemented new detection to check if a download was successful or not.

Now, at MyArcadeBlog settings you will find a new option “Max. Width”. There you can define the maximum allowed width for the games. Games will be resized to the maximal width if they are wider. With this option, your theme will not be “damaged” by to wide games. This is an optional setting. Set it only if you want to resize games.

If a game has been resized, you can detect this very easy with a new function: “myarcade_check_width”. If a game has been resized this function will return TRUE, otherwise FALSE. This nice feature can be used to create gadgets like this:

fullsize_1

fullsize_2

For this example, I used Thickbox.

The function “get_game” has a new parameter: get_game($postid, $fullsize).

$fullsize is FALSE on default. That meens, if you have set a max. width all games will be resized. If you set $fullsite to TRUE a game will be shown in a full size mode.

  • Full size example: get_game($postid, TRUE);
  • Resized example: get_game($postid);

Here is a litle example with Thickbox:

This is a excerpt of single.php

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<!-- BEGIN Game Embedd *** My Arcade Blog Plugin Reqired *** -->
  <?php if (function_exists('get_game')) : ?>
<div align="center" style="margin:5px;">
    <?php include(TEMPLATEPATH."/ad_overgame.php");?>
<div id="embedgame">
    <?php echo get_game($post->ID); ?>
    </div>
<div id="playagain" style="display:none;">
     <a href="#" onclick="document.getElementById('playagain').style.display = 'none';document.getElementById('embedgame').style.display = 'inline';">Play Again!</a>
    </div>
 
    <?php // Check if the game has been resized.. ?>
    <?php if (myarcade_check_width($post->ID)) : ?>
<div style="margin: 5px auto; text-align: center;">
<div id="myOnPageContent" style="display:none;">
        <?php // Get the full size game code, but don't display it ?>
        <?php echo get_game($post->ID, true); ?>
      </div>
 
      <?php
        // Get fullsize width and height and add some space around
        $width  =  get_post_meta($post->ID, "width",  true) + 20;
        $height =  get_post_meta($post->ID, "height", true) + 20;
      ?>
      <?php // Display the Thickbox link for full size game ?>
      <a href="#TB_inline?height=<?php echo $height;  ?>&width=<?php echo $width; ?>&inlineId=myOnPageContent" class="thickbox" title="Fullsize Game" type="button" value="Show" onclick="document.getElementById('playagain').style.display = 'inline';document.getElementById('embedgame').style.display = 'none'">Click here to play this game in full size mode!</a>
      </div>
 
      <!-- document.getElementById('embedgame').style.visibility = 'hidden'; -->
    <?php endif; ?>
    <?php include(TEMPLATEPATH."/ad_undergame.php");?>
    </div>
 
  <?php endif; ?>
  <!-- END Game Embedd *** My Arcade Blog Plugin Reqired *** -->

What’s coming next?

  1. Bug fixing, if there are some bugs ;)
  2. Game import function for:
    1. IBParcade
    2. AV Arcade
    3. Arcadem Pro
    4. And other

If you have any legal game packs, please send me that I can test import functions.

Do you like MyArcadeBlog?

Where to download MyArcadeBlog?

download

Do you have any wishes? What features are you missing?