This is an easy answer, almost too easy that it makes searching for it kinda of hard...
PHP Foreach:
<?php $position = get_post_meta(get_the_ID(), '_moon_draggable_values', false);
if ($position){
foreach ($position as $key => $value)
echo "{$key} => {$value}\n";
}
?>
This outputs 0 => 233px 1 => 435px
all Im trying to do is, select the index and echo it, I tried something like echo $value[1]
hoping to echo the 435px, that didnt work, also trying with $key
.
Conclusion: Trying to get a specific array index value 0,1 are the only two indexes (only two arrays)
Solution:
<?php $position = get_post_meta(get_the_ID(), '_moon_draggable_values', false);
$top = $position[0];
$left = $position[1];
?>
<div style="left:<?php echo $left ?>; top: <?php echo $top?>; position: absolute;">
<?php echo htmlspecialchars_decode(get_post_meta ($post->ID, '_moon_sortable_content', true));?>
</div>