[ABD] Mobile Notifier

Any abandoned Extensions will be moved to this forum.

WARNING: Extensions in this forum are not currently being supported or maintained by the original Extension author. Proceed at your own risk.
Forum rules
IMPORTANT: Extension Development Forum rules

WARNING: Extensions in this forum are not currently being supported nor updated by the original Extension author. Proceed at your own risk.
sakkiotto
Registered User
Posts: 228
Joined: Mon Jun 13, 2005 9:45 pm

Re: [DEV] Whatsapp Notifier

Post by sakkiotto » Mon Jun 15, 2015 5:08 am

Volksdevil wrote:Now the user has my phone number in their profile.
me too. from acp are users have tests number but from ucp have correct number :)

User avatar
Volksdevil
Registered User
Posts: 2414
Joined: Sun Oct 03, 2010 2:03 pm
Location: Lancashire, UK
Name: Neil
Contact:

Re: [DEV] Whatsapp Notifier

Post by Volksdevil » Mon Jun 15, 2015 2:51 pm

I have had a go at translating the English language VARS, I don't know how to do pull requests so here is my effort just the language part.

PS: Would it be possible to choose a 'Default' country?

Code: Select all

	'CC_AD'	=> 'Andorra',
	'CC_AE'	=> 'Arab Emirates (UAE)',
	'CC_AF'	=> 'Afghanistan',
	'CC_AG'	=> 'Antigua',
	'CC_AI'	=> 'Anguilla',
	'CC_AL'	=> 'Albania',
	'CC_AM'	=> 'Armenia',
	'CC_AO'	=> 'Angola',
	'CC_AR'	=> 'Argentina',
	'CC_AS'	=> 'American Samoa',
	'CC_AT'	=> 'Austria',
	'CC_AU'	=> 'Australia',
	'CC_AW'	=> 'Aruba',
	'CC_AZ'	=> 'Azerbaijan',
	'CC_BA'	=> 'Bosnia and Herzegovina',
	'CC_BB'	=> 'Barbados',
	'CC_BD'	=> 'Bangladesh',
	'CC_BE'	=> 'Belgium',
	'CC_BF'	=> 'Burkina Faso',
	'CC_BG'	=> 'Bulgaria',
	'CC_BH'	=> 'Bahrain',
	'CC_BI'	=> 'Burundi',
	'CC_BJ'	=> 'Benin',
	'CC_BL'	=> 'Saint Barthélemy',
	'CC_BM'	=> 'Bermuda',
	'CC_BN'	=> 'Brunei',
	'CC_BO'	=> 'Bolivia',
	'CC_BQ'	=> 'Bonaire Island Country',
	'CC_BR'	=> 'Brazil',
	'CC_BS'	=> 'Bahamas',
	'CC_BT'	=> 'Bhutan',
	'CC_BW'	=> 'Botswana',
	'CC_BY'	=> 'Belarus',
	'CC_BZ'	=> 'Belize',
	'CC_CA'	=> 'Canada',
	'CC_CD'	=> 'Democratic Republic of Congo',
	'CC_CF'	=> 'Central African Republic',
	'CC_CG'	=> 'Congo',
	'CC_CH'	=> 'Switzerland',
	'CC_CI'	=> 'Côte d’Ivoire',
	'CC_CK'	=> 'Cook Islands',
	'CC_CL'	=> 'Chile',
	'CC_CM'	=> 'Cameroon',
	'CC_CN'	=> 'China',
	'CC_CO'	=> 'Colombia',
	'CC_CR'	=> 'Costa Rica',
	'CC_CU'	=> 'Kuba',
	'CC_CV'	=> 'Cape Verde',
	'CC_CW'	=> 'Curaçao',
	'CC_CY'	=> 'Cyprus',
	'CC_CZ'	=> 'Czech Republic',
	'CC_DE'	=> 'Germany',
	'CC_DJ'	=> 'Djibouti',
	'CC_DK'	=> 'Denmark',
	'CC_DM'	=> 'Dominica',
	'CC_DO'	=> 'Dominican Republic',
	'CC_DZ'	=> 'Algeria',
	'CC_EC'	=> 'Ecuador',
	'CC_EE'	=> 'Estonia',
	'CC_EG'	=> 'Egypt',
	'CC_EH'	=> 'Western Sahara',
	'CC_ER'	=> 'Eritrea',
	'CC_ES'	=> 'Spain',
	'CC_ET'	=> 'Ethiopia',
	'CC_FK'	=> 'Falkland Islands',
	'CC_FI'	=> 'Finland',
	'CC_FJ'	=> 'Fiji',
	'CC_FO'	=> 'Faroe Islands',
	'CC_FM'	=> 'Federated States of Micronesia',
	'CC_FR'	=> 'France',
	'CC_GA'	=> 'Gabon',
	'CC_GB'	=> 'United Kingdom',
	'CC_GD'	=> 'Grenada',
	'CC_GE'	=> 'Georgia',
	'CC_GF'	=> 'French Guiana',
	'CC_GG'	=> 'Guernsey',
	'CC_GH'	=> 'Ghana',
	'CC_GI'	=> 'Gibraltar',
	'CC_GL'	=> 'Greenland',
	'CC_GM'	=> 'Gambia',
	'CC_GN'	=> 'Guinea',
	'CC_GQ'	=> 'Equatorial Guinea',
	'CC_GP'	=> 'Guadeloupe',
	'CC_GR'	=> 'Greece',
	'CC_GT'	=> 'Guatemala',
	'CC_GU'	=> 'Guam',
	'CC_GW'	=> 'Guinea-Bissau',
	'CC_GY'	=> 'Guyana',
	'CC_HK'	=> 'Hong kong',
	'CC_HN'	=> 'Honduras',
	'CC_HR'	=> 'Croatia',
	'CC_HT'	=> 'Haiti',
	'CC_HU'	=> 'Hungary',
	'CC_ID'	=> 'Indonesia',
	'CC_IE'	=> 'Ireland',
	'CC_IL'	=> 'Israel',
	'CC_IM'	=> 'Isle of Man',
	'CC_IN'	=> 'India',
	'CC_IO'	=> 'British Indian Ocean Territory',
	'CC_IQ'	=> 'Iraq',
	'CC_IR'	=> 'Iran',
	'CC_IS'	=> 'Iceland',
	'CC_IT'	=> 'Italy',
	'CC_JE'	=> 'Jersey',
	'CC_JM'	=> 'Jamaica',
	'CC_JO'	=> 'Jordan',
	'CC_JP'	=> 'Japan',
	'CC_KE'	=> 'Kenya',
	'CC_KG'	=> 'Kyrgyzstan',
	'CC_KH'	=> 'Cambodia',
	'CC_KI'	=> 'Kiribati',
	'CC_KM'	=> 'Comoros',
	'CC_KN'	=> 'St. Kitts and Nevis',
	'CC_KP'	=> 'North Korea',
	'CC_KR'	=> 'South korea',
	'CC_KW'	=> 'Kuwait',
	'CC_KY'	=> 'Cayman Islands',
	'CC_KZ'	=> 'Kazakhstan',
	'CC_LA'	=> 'Laos',
	'CC_LB'	=> 'Lebanon',
	'CC_LC'	=> 'St. Lucia',
	'CC_LI'	=> 'Liechtenstein',
	'CC_LK'	=> 'Sri Lanka',
	'CC_LR'	=> 'Liberia',
	'CC_LS'	=> 'Lesotho',
	'CC_LT'	=> 'Lithuania',
	'CC_LU'	=> 'Luxembourg',
	'CC_LV'	=> 'Latvia',
	'CC_LY'	=> 'Libya',
	'CC_MA'	=> 'Morocco',
	'CC_MC'	=> 'Monaco',
	'CC_MD'	=> 'Moldova',
	'CC_ME'	=> 'Montenegro',
	'CC_MF'	=> 'St. Martin',
	'CC_MG'	=> 'Madagascar',
	'CC_MH'	=> 'Marshall Islands',
	'CC_MK'	=> 'Macedonia',
	'CC_ML'	=> 'Mali',
	'CC_MM'	=> 'Myanmar (Burma)',
	'CC_MN'	=> 'Mongolia',
	'CC_MO'	=> 'Macau',
	'CC_MP'	=> 'Northern Mariana Islands',
	'CC_MQ'	=> 'Martinique',
	'CC_MR'	=> 'Mauritania',
	'CC_MS'	=> 'Montserrat',
	'CC_MT'	=> 'Malta',
	'CC_MU'	=> 'Mauritius',
	'CC_MV'	=> 'Maldives',
	'CC_MW'	=> 'Malawi',
	'CC_MX'	=> 'Mexico',
	'CC_MY'	=> 'Malaysia',
	'CC_MZ'	=> 'Mozambique',
	'CC_NA'	=> 'Namibia',
	'CC_NC'	=> 'New Caledonia',
	'CC_NE'	=> 'Niger',
	'CC_NF'	=> 'Norfolk Islands',
	'CC_NG'	=> 'Nigeria',
	'CC_NI'	=> 'Nicaragua',
	'CC_NL'	=> 'Netherlands',
	'CC_NO'	=> 'Norway',
	'CC_NP'	=> 'Nepal',
	'CC_NR'	=> 'Nauru',
	'CC_NU'	=> 'Niue',
	'CC_NZ'	=> 'New Zealand',
	'CC_OM'	=> 'Oman',
	'CC_PA'	=> 'Panama',
	'CC_PE'	=> 'Peru',
	'CC_PF'	=> 'French Polynesia',
	'CC_PG'	=> 'Papua New Guinea',
	'CC_PH'	=> 'Philippines',
	'CC_PK'	=> 'Pakistan',
	'CC_PL'	=> 'Poland',
	'CC_PM'	=> 'St. Pierre and Miquelon',
	'CC_PR'	=> 'Puerto Rico',
	'CC_PS'	=> 'Palestine',
	'CC_PT'	=> 'Portugal',
	'CC_PW'	=> 'Belau',
	'CC_PY'	=> 'Paraguay',
	'CC_QA'	=> 'Katar',
	'CC_RE'	=> 'Reunion',
	'CC_RO'	=> 'Romania',
	'CC_RS'	=> 'Serbia',
	'CC_RU'	=> 'Russia',
	'CC_RW'	=> 'Rwanda',
	'CC_SA'	=> 'Saudi-Arabia',
	'CC_SB'	=> 'Solomon Islands',
	'CC_SC'	=> 'Seychelles',
	'CC_SD'	=> 'Sudan',
	'CC_SE'	=> 'Sweden',
	'CC_SG'	=> 'Singapore',
	'CC_SH'	=> 'St. Helena',
	'CC_SI'	=> 'Slovenia',
	'CC_SK'	=> 'Slovakia',
	'CC_SL'	=> 'Sierra Leone',
	'CC_SM'	=> 'San Marino',
	'CC_SN'	=> 'Senegal',
	'CC_SO'	=> 'Somalia',
	'CC_SR'	=> 'Suriname',
	'CC_SS'	=> 'South Sudan',
	'CC_ST'	=> 'Sao Tome and Principe',
	'CC_SV'	=> 'El Salvador',
	'CC_SX'	=> 'St. Maarten',
	'CC_SY'	=> 'Syria',
	'CC_SZ'	=> 'Swaziland',
	'CC_TC'	=> 'Turks and Caicos Islands',
	'CC_TD'	=> 'Chad',
	'CC_TG'	=> 'Togo',
	'CC_TH'	=> 'Thailand',
	'CC_TJ'	=> 'Tajikistan',
	'CC_TK'	=> 'Tokelau',
	'CC_TL'	=> 'Timor-Leste',
	'CC_TM'	=> 'Turkmenistan',
	'CC_TN'	=> 'Tunisia',
	'CC_TO'	=> 'Tonga',
	'CC_TR'	=> 'Turkey',
	'CC_TT'	=> 'Trinidad und Tobago',
	'CC_TV'	=> 'Tuvalu',
	'CC_TW'	=> 'Taiwan',
	'CC_TZ'	=> 'Tanzania',
	'CC_UA'	=> 'Ukraine',
	'CC_UG'	=> 'Uganda',
	'CC_US'	=> 'United States of America',
	'CC_UY'	=> 'Uruguay',
	'CC_UZ'	=> 'Uzbekistan',
	'CC_VA'	=> 'Vatican City',
	'CC_VC'	=> 'Saint Vincent and the Grenadines',
	'CC_VE'	=> 'Venezuela',
	'CC_VG'	=> 'British Virgin Islands',
	'CC_VI'	=> 'United States Virgin Islands',
	'CC_VN'	=> 'Vietnam',
	'CC_VU'	=> 'Vanuatu',
	'CC_WF'	=> 'Wallis und Futuna',
	'CC_WS'	=> 'Samoa',
	'CC_XK'	=> 'Kosovo (Republic of)',
	'CC_YE'	=> 'Yemen',
	'CC_YT'	=> 'Mayotte',
	'CC_ZA'	=> 'South Africa',
	'CC_ZM'	=> 'Zambia',
	'CC_ZW'	=> 'Zimbabwe',
My phpBB Extensions
Finally found great Website Hosting from Image KUALO!
Do NOT use 123-reg.co.uk - Incapable of running phpBB!
:ugeek: TekNeil - Streamer on Mixer | My Volkswagen Corrado G60

User avatar
tas2580
Registered User
Posts: 295
Joined: Wed May 30, 2007 1:56 am
Location: Stuttgart, Germany
Contact:

Re: [DEV] Whatsapp Notifier

Post by tas2580 » Mon Jun 15, 2015 3:20 pm

Thanks a lot :D

User avatar
Volksdevil
Registered User
Posts: 2414
Joined: Sun Oct 03, 2010 2:03 pm
Location: Lancashire, UK
Name: Neil
Contact:

Re: [DEV] Whatsapp Notifier

Post by Volksdevil » Mon Jun 15, 2015 3:36 pm

No problem. There may be a couple that aren't perfect, but still easily understoopd for English users.

PS: I updated to latest version 0.1.2 and:
* My own phone number still shows for other users in ACP.

* Avatar still not working. EDIT: Avatar seems to work with a .jpg! 8-)

* Oh, and as mentioned earlier, the links in the whatsapp notification don't seem to be clickable? Unless you have to add the number as a contact first? EDIT: Yes, once you add the number as a contact, then you can click the links

Just so you know, I presume you are working on these anyway, keep up the good work 8-)
My phpBB Extensions
Finally found great Website Hosting from Image KUALO!
Do NOT use 123-reg.co.uk - Incapable of running phpBB!
:ugeek: TekNeil - Streamer on Mixer | My Volkswagen Corrado G60

sakkiotto
Registered User
Posts: 228
Joined: Mon Jun 13, 2005 9:45 pm

Re: [DEV] Whatsapp Notifier

Post by sakkiotto » Mon Jun 15, 2015 4:22 pm

Volksdevil wrote: PS: Would it be possible to choose a 'Default' country?
put in the first your default country :D

User avatar
tas2580
Registered User
Posts: 295
Joined: Wed May 30, 2007 1:56 am
Location: Stuttgart, Germany
Contact:

Re: [DEV] Whatsapp Notifier

Post by tas2580 » Mon Jun 15, 2015 4:49 pm

Volksdevil wrote:* My own phone number still shows for other users in ACP.
Its fixed in the Github repository, next time I repack the download it will work. You can download the files from Github and overwrite yours, but don't overwrite the vendor folder.
Volksdevil wrote:* Avatar still not working. EDIT: Avatar seems to work with a .jpg! 8-)
PNG should also work, but I will check this and maybe I make only JPG able to use.
Volksdevil wrote:* Oh, and as mentioned earlier, the links in the whatsapp notification don't seem to be clickable? Unless you have to add the number as a contact first? EDIT: Yes, once you add the number as a contact, then you can click the links
Ok this seems to be a feature of Whatsapp to protect from spam. There I can't do anything :cry:

User avatar
Volksdevil
Registered User
Posts: 2414
Joined: Sun Oct 03, 2010 2:03 pm
Location: Lancashire, UK
Name: Neil
Contact:

Re: [DEV] Whatsapp Notifier

Post by Volksdevil » Mon Jun 15, 2015 7:17 pm

Ah that's OK.

PS: I think it's good to be able to upload PNG also as the Avatar.

Oh and yep, phone number now displays OK in ACP 8-)

Is it OK that if a user does not enter their phone number, that the options to choose whatsapp notifications still appear in the UCP?
Perhaps in the country code dropdown, it could have an option at the top called 'Select' which is considered NULL/Empty?
My phpBB Extensions
Finally found great Website Hosting from Image KUALO!
Do NOT use 123-reg.co.uk - Incapable of running phpBB!
:ugeek: TekNeil - Streamer on Mixer | My Volkswagen Corrado G60

User avatar
tas2580
Registered User
Posts: 295
Joined: Wed May 30, 2007 1:56 am
Location: Stuttgart, Germany
Contact:

Re: [DEV] Whatsapp Notifier

Post by tas2580 » Mon Jun 15, 2015 7:26 pm

No tats not OK, I'll check this too.
sakkiotto wrote:PS: Would it be possible to choose a 'Default' country?
I have set the browser language as default, but I think in UK or US you have "en" as browser language but your domain is .uk or .us and so this don't work. For me in germany it works fine. I will look for a better way to get the right country code as default.

Holger
Registered User
Posts: 1752
Joined: Tue Mar 12, 2002 3:54 pm
Location: Hannover

Re: [DEV] Whatsapp Notifier

Post by Holger » Wed Jun 17, 2015 12:36 pm

PR for Swedish translation sent

User avatar
Alex Grigoras
Registered User
Posts: 25
Joined: Mon Nov 03, 2014 5:46 pm
Location: Galati
Name: Grigoras Alex
Contact:

Re: [DEV] Whatsapp Notifier

Post by Alex Grigoras » Thu Jun 18, 2015 7:46 am

With new version I have this problem:

Code: Select all

[phpBB Debug] PHP Warning: in file [ROOT]/ext/tas2580/whatsapp/helper.php on line 151: require_once(./../ext/tas2580/whatsapp/vendor/mgp25/whatsapi/src/whatsprot.class.php) [function.require-once]: failed to open stream: No such file or directory

Fatal error: require_once() [function.require]: Failed opening required './../ext/tas2580/whatsapp/vendor/mgp25/whatsapi/src/whatsprot.class.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/mecantur/public_html/rotar/ext/tas2580/whatsapp/helper.php on line 151

User avatar
tas2580
Registered User
Posts: 295
Joined: Wed May 30, 2007 1:56 am
Location: Stuttgart, Germany
Contact:

Re: [DEV] Whatsapp Notifier

Post by tas2580 » Thu Jun 18, 2015 12:08 pm

You need the Chat API. If you take the download from Github you must also download Chat-API from here and copy the files to /ext/tas2580/whatsapp/vendor/mgp25/whatsapi/

User avatar
tas2580
Registered User
Posts: 295
Joined: Wed May 30, 2007 1:56 am
Location: Stuttgart, Germany
Contact:

Re: [DEV] Mobile Notifier

Post by tas2580 » Thu Jun 18, 2015 9:22 pm

I have talked to my lawyer and he set I have to rename this extension because of naming rights.

So now I have done that and uploaded a new Version. In the new Version Chat-API is no longer needed because I have added it directly to the extension.


Important step before Update!!!

Before you can update to the new Version you need to edit your /ext/tas2580/whatsapp/ext.php an put the following content into it.

Code: Select all

<?php
/**
*
* @package phpBB Extension - tas2580 Whatsapp Notifier
* @copyright (c) 2015 tas2580 (https://tas2580.net)
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
*
*/
namespace tas2580\whatsapp;

/**
* @ignore
*/
class ext extends \phpbb\extension\base
{
    function disable_step($old_state)
    {
        global $db;
        $sql = 'DELETE FROM ' . USER_NOTIFICATIONS_TABLE . "
            WHERE method = 'notification.method.whatsapp'";
        $db->sql_query($sql);
        return parent::enable_step($old_state);
    }
}
 
After that you can disable the old Extension. Its important that you make the edit on the /ext/tas2580/whatsapp/ext.php before you disable it. After you have disabled the old Extension you can delete it an activate the new Extension.

KnownSyntax
Registered User
Posts: 37
Joined: Mon Sep 22, 2014 8:47 pm
Location: Arizona, United States

Re: [DEV] Mobile Notifier

Post by KnownSyntax » Fri Jun 19, 2015 3:32 am

This idea sounds really cool and neat, including the fact that members can signup to get notified via text message on their favorite topics, forums, etc.

The biggest issue that I can see would have to be the getting the WhatsApp password in order to make sure that users can use it. Otherwise, great job!

MaFeSa
Registered User
Posts: 174
Joined: Wed Feb 11, 2009 7:48 am

Re: [DEV] Mobile Notifier

Post by MaFeSa » Thu Jun 25, 2015 6:42 am

Great job tas2580, thanks!

sakkiotto
Registered User
Posts: 228
Joined: Mon Jun 13, 2005 9:45 pm

Re: [DEV] Mobile Notifier

Post by sakkiotto » Thu Jun 25, 2015 3:16 pm

italian translation UPDATED 0.2 version
https://www.dropbox.com/s/m693qtipzkglqip/it.zip?dl=0

Locked

Return to “Abandoned Extensions”