Jump to content

DrMath

Clients
  • Posts

    11
  • Joined

  • Last visited

 Content Type 

Downloads

Release Notes

IPS4 Guides

IPS4 Developer Documentation

Invision Community Blog

Development Blog

Deprecation Tracker

Providers Directory

Forums

Events

Store

Gallery

Everything posted by DrMath

  1. I have validated that this is working.
  2. I will check this and see if it works.
  3. Since it appears in the auto-welcome, it'd be difficult to show. Our site is http://www.zealotgaming.com and you can see the auto-thread in the Application section.
  4. In your IPS root, go into "applications/autowelcome/sources/Alerts/". In it is a file called "Alerts.php" Edit this file. Find protected static function returnTagValues( $member=NULL, $topic=NULL ) In this, you will see the current values you can used defined. Before the "Topic tag" section, add your own values. This requires some knowledge of the $member functionality which you can find here: https://invisionpower.com/4docs/advanced-usage/development/working-with-members-r179/ If you have custom profile fields, you will need to use the $member->profileFields() getter. This creates an array of all of your custom profile fields. An easy way to get see how yours is structured is to create a page and display this for yourself. Create a page using as an HTML page then use the following code to see the array: {{ $member = \IPS\Member::loggedIn(); }} {{ var_dump($member->profileFields()); exit; }} Each "section" you have defined with have its own array, so to get these you will have to define variables as a multidimensional array. An example of mine are below: /* Get Profile Fields for Custom Tags */ $profile_fields = $member->profileFields(); /* Custom Tags */ $tags['%region%'] = $profile_fields['core_pfieldgroups_1']['core_pfield_11']; $tags['%discord_un%'] = $profile_fields['core_pfieldgroups_1']['core_pfield_38']; $tags['%main_game%'] = $profile_fields['core_pfieldgroups_3']['core_pfield_12']; $tags['%battle_tag%'] = $profile_fields['core_pfieldgroups_4']['core_pfield_4']; These will not show up in the list in the ACP, but you will be able to then use them in your welcome messages and code. If the author does not want this posted, I will remove it upon request. Hope this helps some people! Side question, @Mike John, is it possible to change when the messages are sent? For example, we have two-step registration, email confirmation then admin approval. We'd like to send the message/post the thread before the admin approves if possible. Thanks!
  5. I figured out how to do it manually editing the code a bit. Not too difficult once I found where it was hiding.
  6. I was wondering if there is an easy way to include additional fields in the messages? There are already built-in variables for member name, ID, etc. but for example, we're planning on using this to post auto-intro threads and want to include specific contact information they enter in custom profile fields. Is there an easy way to pass this information into new variables?
×
×
  • Create New...