• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: global:formtitle change in code

global:formtitle change in code 10 years 4 months ago #29794

  • onetime
  • onetime's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
How would I change the {form:title} in $formLayout?

I want to reuse the form for many different menu items.

I have captured the menu item name: $pagetitle and I'd like to replace the formtitle placeholder with $pagetitle.

This doesn't work:
$replace = "{global:formtitle}";
$with = $pagetitle;
$formLayout = str_replace($replace, $with, $formLayout);

help?
The administrator has disabled public write access.

global:formtitle change in code 10 years 4 months ago #29795

  • alexp
  • alexp's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 2253
  • Thank you received: 180
If you output the $formLayout variable you will notice that by the time of Scripts called on form display area, {global:formtitle} is already replaced with the actual title. How you can see the variable content:
print_r($formLayout);die();

What you can do instead:

- set the form title to: #dynamic title#
- use the following script instead:
$formLayout = str_replace('#dynamic title#', $pagetitle, $formLayout);
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.
The following user(s) said Thank You: onetime

global:formtitle change in code 10 years 4 months ago #29797

  • onetime
  • onetime's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
wow this opens a world of opportunities. thank you!! Really great product.
The administrator has disabled public write access.

global:formtitle change in code 5 years 5 months ago #39643

  • cybert11
  • cybert11's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
Real sorry to bring up this old post.
But this doesnt seem to work anymore, merely removes the title, has the $pagetitle variable been changed ?
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!