Skip to content

Commit 9d4ff78

Browse files
committed
fix examples to work on py2 and py3
1 parent 67b0777 commit 9d4ff78

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.markdown

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ from pyzabbix import ZabbixAPI
2525

2626
zapi = ZabbixAPI("http://zabbixserver.example.com")
2727
zapi.login("zabbix user", "zabbix pass")
28-
print "Connected to Zabbix API Version %s" % zapi.api_version()
28+
print ( "Connected to Zabbix API Version %s" % zapi.api_version() )
2929

3030
for h in zapi.host.get(output="extend"):
31-
print h['hostid']
31+
print (h['hostid'])
3232
```
3333

3434
Refer to the [Zabbix API Documentation](https://www.zabbix.com/documentation/3.0/manual/api/reference) and the [PyZabbix Examples](https://github.com/lukecyca/pyzabbix/tree/master/examples) for more information.

0 commit comments

Comments
 (0)