Gauge Interactive Blog Read to understand
Find out what is on our minds and what corners of the industry we explore. Read about the latest news at Gauge Interactive and feel free to comment on our posts.
Find out what is on our minds and what corners of the industry we explore. Read about the latest news at Gauge Interactive and feel free to comment on our posts.
Syntax highlighting is one strategy to improve the readability and context of the text; especially for code that spans several pages. The reader can easily ignore large sections of comments or code, depending on what one desires. Syntax highlighting also helps programmers find errors in their program. For example, most editors highlight string literals in a different color. Consequently, spotting a missing delimiter is much easier because of the contrasting color of the text. Brace matching is another important feature with many popular editors. This makes it simple to see if a brace has been left out or locate the match of the brace the cursor is on by highlighting the pair in a different color.
This is a small snippet from our gallery, just for testing purposes. We are using a new Syntax Highlighter for the web so people can view our code and utilize easier. We want to include more samples from our work in our blog.
<?php if ( $imagesi = get_children(array(
'post_parent' => get_the_ID(),
'post_type' => 'attachment',
'numberposts' => -1,
'post_mime_type' => 'image',
))) : ?>
<?php $images = array_reverse($imagesi);?>
<?php foreach( $images as $image ) : ?>
<?php $att_image = wp_get_attachment_image_src( $image->ID, "full"); $tester = $att_image[1];?>
<?php if ($tester > 300){?>
<?php $numero++;?>
<div class="control_img_box"><div class="control_img"><img onmouseover="document.getElementById('rolloverimage').src='<?php echo $att_image[0];?>'" alt="Gallery Rollover" src="<?php bloginfo('stylesheet_directory');?>/images/<?php echo $numero;?>_button.png" /><img src="<?php echo $att_image[0];?>" alt="Projects" class="preload"/></div></div>
<?php } ?>
<?php endforeach; ?>
<?php endif; ?>
Cool!