Title: Problem with PHP 7.1
Last modified: October 25, 2017

---

# Problem with PHP 7.1

 *  [sedros](https://wordpress.org/support/users/sedros/)
 * (@sedros)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/)
 * When PHP 7.1 is enabled I get this message on my site:
 * Warning: Parameter 2 to qtranxf_postsFilter() expected to be a reference, value
   given in /var/www/DOMAIN/htdocs/wordpress/wp-includes/class-wp-hook.php on line
   298
 * If I use PHP 7.0 problem does not appear.

Viewing 11 replies - 1 through 11 (of 11 total)

 *  [schmatej](https://wordpress.org/support/users/schmatej/)
 * (@schmatej)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-8858360)
 * Hello, I had the same problem. For your needs just remove character ‘&’ before
   $query parameters in functions:
 * qtranslate_frontend.php:qtranxf_excludeUntranslatedPosts()
    qtranslate_frontend.
   php:qtranxf_postsFilter()
 * Tested on qTranslate X plugin version 3.4.6.8
 *  [extremecarver](https://wordpress.org/support/users/extremecarver/)
 * (@extremecarver)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-8907257)
 * in which file do I need to remove the & character?
 *  [webrockers](https://wordpress.org/support/users/webrockers/)
 * (@webrockers)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-8908632)
 * Hi
 * You will find it in qtranslate-x/qtranslate_frontend.php
 * In line 523 change
 * `function qtranxf_postsFilter($posts,&$query) {//WP_Query`
 * to
 * `function qtranxf_postsFilter($posts,$query) {//WP_Query`
 * and in line 597 change
 * `function qtranxf_excludeUntranslatedPosts($where,&$query) {//WP_Query`
 * to
 * `function qtranxf_excludeUntranslatedPosts($where,$query) {//WP_Query`
 * Cheers
 * Marco
    -  This reply was modified 9 years, 3 months ago by [webrockers](https://wordpress.org/support/users/webrockers/).
 *  [Vishal Prajapati](https://wordpress.org/support/users/vishal13m/)
 * (@vishal13m)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9004598)
 * Thanks a lot [@webrockers](https://wordpress.org/support/users/webrockers/), 
   worked perfectly for me.
 *  [chipbr](https://wordpress.org/support/users/chipbr/)
 * (@chipbr)
 * [9 years, 1 month ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9116951)
 * thank so much [@webrockers](https://wordpress.org/support/users/webrockers/) ,
   it also worked for me after moving my site from a PHP 5 hosting to a PHP 7.1
 * I´ve just made a registration on WP to thank you.
 *  [webrockers](https://wordpress.org/support/users/webrockers/)
 * (@webrockers)
 * [9 years, 1 month ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9117808)
 * It is nice to learn that some of my output is of help.
 * So thanks for telling me!
 * Aloha and Mahalo
 * Marco
 *  [18TommyBoy](https://wordpress.org/support/users/18tommyboy/)
 * (@18tommyboy)
 * [9 years ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9143054)
 * I have today this problem too when transfer page to other webhosting… All 37 
   plugins work perfectly, but this qTranslate… OMG… Why can´t repair this problem
   with update???
 * (and thanx the guy for solve “&”)
    -  This reply was modified 9 years ago by [18TommyBoy](https://wordpress.org/support/users/18tommyboy/).
 *  [mzaher](https://wordpress.org/support/users/mzaher/)
 * (@mzaher)
 * [9 years ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9174841)
 * thank you very much
 *  [Blackbam](https://wordpress.org/support/users/blackbam/)
 * (@blackbam)
 * [8 years, 12 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9231848)
 * Same here. Waiting for update …
 *  [kefi](https://wordpress.org/support/users/kefi/)
 * (@kefi)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9356241)
 * I’ve got this warning today on XAMPP local server with PHP Version 7.1.7.
 * The [@schmatej](https://wordpress.org/support/users/schmatej/) answer resolved
   the problem.
 * > remove character ‘&’ before $query parameters in functions:
   > qtranslate_frontend.php:qtranxf_excludeUntranslatedPosts()
   >  qtranslate_frontend.
   > php:qtranxf_postsFilter()
 *  [wannaprasart](https://wordpress.org/support/users/wannaprasart/)
 * (@wannaprasart)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9526090)
 * .
    Warning : class-wp-hook.php on line 298 . plugins All Meta Tags By Arthur 
   Gareginyan . Warning: call_user_func_array() expects parameter 1 to be a valid
   callback, no array or string given in /home/www/web411/html/bjoern/wp/wp-includes/
   class-wp-hook.php on line 298 . plugins **All Meta Tags** By Arthur Gareginyan.
   Warning: call_user_func_array() expects parameter 1 to be a valid callback, no
   array or string given in /home/www/web411/html/bjoern/wp/wp-includes/class-wp-
   hook.php on line 298 . All Meta Tags, class-wp-hook .

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘Problem with PHP 7.1’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/qtranslate-x_f9f9f9.svg)
 * [qTranslate X](https://wordpress.org/plugins/qtranslate-x/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/qtranslate-x/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/qtranslate-x/)
 * [Active Topics](https://wordpress.org/support/plugin/qtranslate-x/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/qtranslate-x/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/qtranslate-x/reviews/)

## Tags

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

 * 11 replies
 * 11 participants
 * Last reply from: [wannaprasart](https://wordpress.org/support/users/wannaprasart/)
 * Last activity: [8 years, 8 months ago](https://wordpress.org/support/topic/problem-with-php-7-1-2/#post-9526090)
 * Status: not resolved