XF 2.2 Pricing tables for user upgrade page

  • Thread starter Thread starter Deleted member 241496
  • Start date Start date
D

Deleted member 241496

Guest
I understand there is a pricing table add-on, but I'm pretty good with css and know how to create my own pricing tables. The problem is we want to replace the basic user upgrade page with a pricing table and don't know where to find that code. And the issue is I need the code for each of the buttons which I'm not sure how Xenforo assigns those. Any ideas? Has anyone done this yet?

1636998721946.png
 
Last edited by a moderator:
The template is account_upgrades .
But how are the purchase buttons coded for each user upgrade? I see there is a loop looking for each upgrade but how does it assign those into the buttons? We'd like to replace the
Code:
xf.formrows
with the pricing table and add the buttons at the bottom of each table. You can see how we have it coded right now below. We want to get rid of the top portion and have just the pricing tables, with those buttons at the bottom of each pricing table.

1637000915032.webp
 
You would need to manually build your own template entering the relevant values for each upgrade.

You can use {{ dump(vars()) }} to determine what the values are.
 
You would need to manually build your own template entering the relevant values for each upgrade.

You can use {{ dump(vars()) }} to determine what the values are.
Ok i did that, and im not seeing the URL's each button is pointing to. I see:

"available" => ArrayCollection {#273 ▼
#entities: array:5 [▼
9 => UserUpgrade {#323 ▼
#_getterCache: []
#_valueCache: array:1 [ …1]
#_structure: Structure {#317 …12}
#_em: Manager {#242 ▶}
-_uniqueEntityId: 10
#rootClass: "XF\Entity\UserUpgrade"
#_useReplaceInto: false
#_newValues: []
#_values: array:13 [ …13]
#_relations: array:1 [ …1]
#_previousValues: []
#_options: []
#_deleted: false
#_readOnly: false
#_writePending: false
#_writeRunning: false
#_errors: []
#_whenSaveable: []
#_cascadeSave: []
#_behaviors: null
}
 
Top Bottom