Title: syntax error, unexpected T_STRING
Last modified: October 13, 2020

---

# syntax error, unexpected T_STRING

 *  Resolved [tomhala](https://wordpress.org/support/users/tomhala/)
 * (@tomhala)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/syntax-error-unexpected-t_string-9/)
 * I wanted activate Photo Gallery plugin in WordPress, but there was an error:
 * Parse error: syntax error, unexpected T_STRING in /web/htdocs2/somewhere/home/
   www/wp_gallery/wp-content/plugins/photo-gallery/framework/WDWSitemap.php on line
   34
 *     ```
       public function add_wpseo_xml_sitemap_images( $images, $post_id ) {
       $this->images = $images;
   
       $post = get_post($post_id);
   
       remove_all_shortcodes();
       if ( defined('ELEMENTOR_VERSION') ) {
         \Elementor\Plugin::instance()->frontend->get_builder_content($post->ID);
       }
       add_shortcode('Best_Wordpress_Gallery', array($this, 'shortcode'));
       do_shortcode($post->post_content);
   
       return $this->images;
       }
       ```
   
 * line 34 is: \Elementor\Plugin::instance()->frontend->get_builder_content($post-
   >ID);

Viewing 1 replies (of 1 total)

 *  [Asya Gabrilyan](https://wordpress.org/support/users/asyag/)
 * (@asyag)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/syntax-error-unexpected-t_string-9/#post-13532527)
 * Dear [@tomhala](https://wordpress.org/support/users/tomhala/),
    Thank you for
   the report.
 * We assume the problem stems from your current PHP version as we can’t reproduce
   the case on our end
 * WordPress recommends running PHP 7.3, but it also works with PHP 5.6+.
    Please
   update PHP version to have 5.6 at least.
 * If it does not help, please contact our support team using the [following form](https://help.10web.io/hc/en-us/requests/new).
 * Sincerely,

Viewing 1 replies (of 1 total)

The topic ‘syntax error, unexpected T_STRING’ is closed to new replies.

 * ![](https://ps.w.org/photo-gallery/assets/icon-256x256.png?rev=2068745)
 * [Photo Gallery by 10Web - Mobile-Friendly Image Gallery](https://wordpress.org/plugins/photo-gallery/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/photo-gallery/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/photo-gallery/)
 * [Active Topics](https://wordpress.org/support/plugin/photo-gallery/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/photo-gallery/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/photo-gallery/reviews/)

## Tags

 * [php](https://wordpress.org/support/topic-tag/php/)

 * 1 reply
 * 2 participants
 * Last reply from: [Asya Gabrilyan](https://wordpress.org/support/users/asyag/)
 * Last activity: [5 years, 7 months ago](https://wordpress.org/support/topic/syntax-error-unexpected-t_string-9/#post-13532527)
 * Status: resolved