view_get_views returns null
You are missing the display name, which is the machine name of the block/page. 

You can find the machine name under Advanced settings in the right side of the view.

try:

   &lt;?php 
    $view = views_get_view(view_name);
    $view-&gt;set_display(machine_name);
    $view-&gt;preview();
    return $view-&gt;result
    ?&gt;