Closed (fixed)
Project:
GMap Module
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Issue tags:
Reporter:
Created:
20 Sep 2009 at 19:18 UTC
Updated:
1 Apr 2011 at 09:34 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
nirad commentedgetting this error too after moving my development site to a new computer that has PHP 5.3.
Comment #2
nirad commentedswitched to PHP 5.2.11 and the error went away. This seems like it may be a problem with Drupal core, and not with Gmap. See: http://drupal.org/node/586228
Comment #3
kim.pepperThis isn't a problem with Drupal core, its an incorrect use of a reference parameter when its a value parameter. See #360605: PHP 5.3 Compatibility
Comment #4
kim.pepperAttaching patch.
Comment #5
amishra commentedSorry newbee question...how do i apply this patch?
Comment #6
joetsuihk commentedthe patch may fail on php4, see http://drupal.org/node/615058#comment-2211548
Comment #7
Nardos Tessema commentedThanks a lot! It worked for me. I removed the ampersand as stated in the description and now everything is fine.
? 5_3_compat.patch
Index: gmap.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/gmap/gmap.module,v
retrieving revision 1.101
diff -u -p -r1.101 gmap.module
--- gmap.module 17 Apr 2009 18:31:59 -0000 1.101
+++ gmap.module 5 Oct 2009 01:14:28 -0000
@@ -76,7 +76,7 @@ function gmap_theme() {
/**
* Implementation of hook_gmap().
*/
-function gmap_gmap($op, &$map) {
+function gmap_gmap($op, $map) {
switch ($op) {
case 'macro':
return array(
Comment #8
bdragon commented#629196: GMAP PHP 5.3 compatibility marked duplicate.
I'll write a custom _invoke function to fix it.
Comment #9
bdragon commentedHere's the "correct" way to do it.
I'd like this tested with both PHP 5.3 and PHP 5.2 before I commit it.
Comment #10
bdragon commented#684440: warning: Parameter 2 to gmap_gmap() expected to be a reference marked dupe.
Comment #11
pivica commentedI have rerolled patch from #9 against latest gmap dev version. Tested on both PHP 5.2 and PHP 5.3 - its seems everything is working fine and no more 'reference' warning error for PHP 5.3.
Comment #12
ari-meetai commentedSame here. Tested both in PHP 5.2 & PHP 5.3
Comment #13
ragavendra_bn commentedGetting the below warnings in /admin/settings/gmap
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: parse_ini_file() has been disabled for security reasons in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 229.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 234.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
* warning: Invalid argument supplied for foreach() in /home/fashion/public_html/bandhana/sites/all/modules/gmap/gmap_markerinfo.inc on line 246.
Using PHP5.3. Should be related to PHP5.3
How to fix this?
Comment #14
joetsuihk commentedre #13, unrelated, "parse_ini_file() has been disabled for security reasons" in your shared hosting. contact your hosting for more info.
Comment #15
marvil07 commented#11 Works fine, thanks!
Comment #16
spacereactor commentedcan this patch be added to the dev please.
Comment #17
spacereactor commentedagain can this #11 patch be added to dev, it very troublesome with each new upgrade since my hosting server is running on php 5.3
Comment #18
ansorg commentedsubscribe (waiting for this gmap fix to be able to update site to php 5.3)
thank you
Comment #19
Peng.Pif commentedSubscribe.
Comment #20
Carlos Miranda Levy commentedProblem remains, unless you apply patch...
Comment #21
miklPlease commit this…
Comment #22
hutch commentedrerolled patch on current CVS DRUPAL-6--1, the old one did apply but not all that cleanly.
Comment #23
iva2k commented#22 tested on live site with PHP5.3. works OK, warnings gone. Please commit
Comment #24
Bobuido commentedSubscribe
Comment #25
Anonymous (not verified) commentedsame problem with upgrade to PHP 5.3.
maybe rather unwisely i tried #22 on gmap 6.x-1.1-rc1 (DRUPAL-6--1-0), and it worked fine except for 1 hunk, which on inspection i couldnt see any problem with, and applied manually, and it worked.
and now the error is gone, thanks!
Comment #26
michaeldhart commentedPatch applied to 6.x-1.1-rc1 and tested on my development server running php 5.3 and issue resolved...
Comment #27
vgarvardt commentedCan not apply patch from #22 to 6.x-1.1-rc1:
Comment #28
vgarvardt commentedI applied rejected hunk from #22 manually.
Here is updated patch that applies without any problems to 6.x-1.1-rc1.
Comment #29
mikl@vgarvard its not supposed to apply against the release (6.x-1.1-rc1), its supposed to apply against the latest dev version. There, the patch from #22 applies cleanly.
Comment #30
vgarvardt commentedOk, sorry.
Comment #31
bdragon commentedFixed (I hope -- I'm a bit rusty with my tools at the moment), thanks!
http://drupal.org/cvs?commit=377296
http://drupal.org/cvs?commit=377302
http://drupal.org/cvs?commit=377304
Comment #32
spacereactor commentedsorry to open again, but i just install gmap and i having this error
warning: Parameter 2 to gmap_gmap() expected to be a reference, value given in /home/mystie/public_html/includes/module.inc on line 483.
This only happen to my server using php 5.3 and my local test server is php 5.2 is ok
I have to manually add the patch from #22 to remove the error.
Comment #33
marvil07 commentedspacereactor: fixed means commited to the dev version, not on the official release. please make sure you have the 1.x-dev version. maybe you can also want to read Status settings for an issue
Marking back to fixed.
Comment #34
spacereactor commentedi using 6.x-1.x-dev of 2010-Jun-09 and having the error, that why i manually adding the #22 patch. I not using the official release.
Comment #35
rooby commentedI have checked the cvs commits and the latest dev version and the fix is definitely in there already.
Dev releases only update every 12 hours so it is possible you didn't get the latest version if it was too soon after the commit.
If you download the dev version again now it should be working without having to manually patch.
Comment #36
mormmam commentedi used the #22 patch and i got no error warning!
Comment #37
rooby commentedYou don't need the patch if you use the latest dev version as this has already been fixed.
Comment #38
ghousemaideen commented1)I have installed the openpublish and executed well. but, i have received error given below. how to solve this error. I need brief explainations. please guide me immediatly... and,
2)How to convert the drupal database to openpublish. i need some brief explaination. pls..
3)where is Gmap folder.
warning: Parameter 2 to gmap_gmap() expected to be a reference, value given in E:\xampp\htdocs\openpublish\includes\module.inc on line 483.
Regards,
ghouse.
Comment #39
ghousemaideen commented1)I have installed the openpublish and executed well. but, i have received error given below. how to solve this error. I need brief explainations. please guide me immediatly...
warning: Parameter 2 to gmap_gmap() expected to be a reference, value given in E:\xampp\htdocs\openpublish\includes\module.inc on line 483. and,
2)How to convert the drupal database to openpublish. i need some brief explaination. pls..
3)where is Gmap folder.
warning: Parameter 2 to gmap_gmap() expected to be a reference, value given in E:\xampp\htdocs\openpublish\includes\module.inc on line 483.
Regards,
ghouse.
Comment #40
rooby commented@ghousemaideen:
1. I have not used openpublish and I know nothing about it.
What version of gmap are you using? To avoid the error reported in this issue you currently need to use the latest dev version 6.x-1.x-dev (you will also have to use location 6.x-3.x-dev).
2. This is the support queue for gmap, not openpublish. If you need help with openpublish I suggest using it's issue queues. If you check the openpublish issue queues and documentation you might find the information you want is already available.
3. The gmap folder is wherever you put it when you installed it. If you have access to your database use this sql to find out (or just look around your file system):
That will give you the installation information for the gmap module, which includes the patch to the module.
Comment #41
rooby commentedMarked #747658: Gmaps warning as a duplicate of this issue.
Comment #43
summit commentedDid it for me also, greetings, Martijn