Skip Navigation

[Resolved] When using php snippeds one does deactivated and the other needs activation

This support ticket is created 2 years, 6 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 5 replies, has 2 voices.

Last updated by ferryv-3 2 years, 6 months ago.

Assisted by: Shane.

Author
Posts
#2427281

I am trying to:

I'f added 2 custom php functions:

1: to relate a new post to another cpt.
2: shortcode to get the current date and time to use in the post title.

The first php function must be deactivated for it to work while the second php shortcode needs to be activated to function.

So if i activate the relate function it stops working.. This looks weird to me

I use the toolset custom code to add the php functions.

Is this normal? (only admin user at the moment)

Thanks

#2427389

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hello,

Thank you for getting in touch.

I can only see this happening if there are conflicts between both snippets as you should be able to activate either of them independent of each other.

The first thing I would check is for conflicts between them as well as if they are sharing the same function name.

Thanks,
Shane

#2427391
Schermafbeelding 2022-07-28 om 20.50.25.png

I can activate them independent,

Just the 1 works when beeing inactive, while the other only works when active.

If i remove the second so they dont interfeer the php code to create the relationship still needs to be inactive or it doesnt work.

Like in the image.

Ferry

#2427403

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Ferry,

Could you allow me to have admin access to the site so that I can check on this issue for you ?

Thanks,
Shane

#2427409

It aint that big of a problem as it is tested working i just think its strange and am a little worried about some future update that will change this.

But i keep an eye on it.

Thanks for your support!

#2427411

its working so dont fix something that aint broken.... Thank you!